RFR: 8307160: Fix AWT/2D/A11Y to support the permissive- flag on the Microsoft Visual C compiler [v2]
Magnus Ihse Bursie
ihse at openjdk.org
Fri Mar 22 12:31:48 UTC 2024
On Sun, 3 Dec 2023 15:37:47 GMT, Julian Waters <jwaters at openjdk.org> wrote:
>> src/java.desktop/windows/native/libawt/windows/awt_Frame.cpp line 1641:
>>
>>> 1639: }
>>> 1640: }
>>> 1641:
>>
>> A possible improvement later (and for a future RFE) would be to use RAII for deletion and then get rid of the labels. awt is one of the few places that uses C++ for native code, so why not.
>
> Phil unfortunately rejected that approach, so we're on to a more manual way of deleting things here
The comment seems answered. Please resolve this discussion.
>> src/java.desktop/windows/native/libawt/windows/awt_TextComponent.cpp line 59:
>>
>>> 57: AwtTextComponent::OleCallback AwtTextComponent::sm_oleCallback;
>>> 58: WNDPROC AwtTextComponent::sm_pDefWindowProc = NULL;
>>> 59:
>>
>> Did the compiler complain here? I'm fine with the change, just wanted to know the reason.
>
> the latter two are inside an extern "C" block, meaning their initial C++ linkage (by virtue of them being static class members) conflicts with the now C linkage, also the comment there states the AwtComponent fields are supposed to be set here, and I have no idea why this was not done, so I moved them all to be under that comment
The question seem answered. Please resolve the discussion.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/15096#discussion_r1535492864
PR Review Comment: https://git.openjdk.org/jdk/pull/15096#discussion_r1535495754
More information about the build-dev
mailing list