Jens-G commented on PR #3666:
URL: https://github.com/apache/thrift/pull/3666#issuecomment-5670990566
### Code review
Re-reviewed at `19109264a`, against compilers built from this head and from
`d8ec9325e`.
The issue from the last round is fixed. JavaME now writes `@throws
com.inc.RealExc` for a directly included exception, for a typedef in the
including file and for a typedef in the included file. That matches the
signature's `throws` clause. The new javame test fails against `d8ec9325e` and
passes now. The first two suggestions are done too: py and javame are covered
by the test, and moving `xml_encode()` into `t_oop_generator` leaves the
`delphi:xmldoc` and netstd output byte-identical.
The third suggestion is fixed for cpp, java, javame, kotlin and haxe through
`generate_throws_doc()`. netstd builds its `<exception>` elements in its own
loop, which still writes the separator before the first one. So a method
without a doc of its own still opens with an empty line, e.g. from
`test/DebugProtoTest.thrift`:
```csharp
///
/// <exception cref="ExceptionWithAMap"></exception>
global::System.Threading.Tasks.Task<bool> declaredExceptionMethod(bool
shouldThrow, CancellationToken cancellationToken = default);
```
Cosmetic. Writing the `'\n'` only when `ps` already has content, as
`generate_throws_doc()` now does, would fix it. A netstd version of the new
java `/**\n * @throws` assertion would keep it covered.
https://github.com/apache/thrift/blob/19109264a5386de3dcd7f6d85397a5841248db24/compiler/cpp/src/thrift/generate/t_netstd_generator.cc#L3962-L3979
Nothing else changed in the generated output: for `ThriftTest.thrift` and
`DebugProtoTest.thrift` across all affected generators, the only difference is
the removed empty lines.
🤖 Generated with [Claude Code](https://claude.ai/code)
<sub>- If this code review was useful, please react with 👍. Otherwise, react
with 👎.</sub>
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]