Integrated: 8306901: Macro offset_of confuses Eclipse CDT
Richard Reingruber
rrich at openjdk.org
Fri Apr 28 06:25:59 UTC 2023
On Wed, 26 Apr 2023 09:42:52 GMT, Richard Reingruber <rrich at openjdk.org> wrote:
> With this pr I would like to wrap the body of the macro `offset_of` as defined for gcc in parentheses to fix the described issues with Eclipse CDT.
> As an alternative the [`(int)` cast in `byte_offset_of`](https://github.com/openjdk/jdk/blob/44d9f55d0b3c469988be6f1c47f0cfbc433c4490/src/hotspot/share/utilities/sizes.hpp#L59) could be removed. I preferred adding the parentheses to the gcc version of `offset_of` because the impact is smaller.
>
> Of course I'd rather have a local solution for the issue but I couldn't find one that didn't require changes in the source code.
>
> Testing: GHA
This pull request has now been integrated.
Changeset: eb3af8ab
Author: Richard Reingruber <rrich at openjdk.org>
URL: https://git.openjdk.org/jdk/commit/eb3af8abe9743669887445f8fc5ff647187f983a
Stats: 2 lines in 1 file changed: 0 ins; 0 del; 2 mod
8306901: Macro offset_of confuses Eclipse CDT
Reviewed-by: stuefe, kbarrett
-------------
PR: https://git.openjdk.org/jdk/pull/13668
More information about the hotspot-dev
mailing list