On Thu, 16 Mar 2023 17:24:13 GMT, Sergey Bylokhov <s...@openjdk.org> wrote:
>> Abhishek Kumar has updated the pull request incrementally with one >> additional commit since the last revision: >> >> Review comment update > > test/jdk/javax/accessibility/JEditorPane/TestEditorPaneAccessibleChildCount.java > line 109: > >> 107: }); >> 108: addDelay(500); >> 109: int childCount2 = ac.getAccessibleChildrenCount(); > > note: "ac" initialized on EDT, and accessed here w/o synchronization. I am facing an error `local variables referenced from a lambda expression must be final or effectively final` when I tried to get the ChildrenCount and assign it to local variable `childCount2` on EDT. My piece of code looks like this in `main` method int childCount2 = 0; SwingUtilities.invokeAndWait(() -> { childCount2 = ac.getAccessibleChildrenCount(); }); ------------- PR: https://git.openjdk.org/jdk/pull/12707