-
Why do I have non reentrant iterator warning from Android Studio even when I import |
Beta Was this translation helpful? Give feedback.
Answered by
czyzby
Jun 12, 2021
Replies: 1 comment 2 replies
-
This is because LibGDX reuses iterators internally and might return the same instance on subsequent calls. It's basically an anti-pattern, which I'm guessing they implemented to limit the garbage collection on mobiles. See this StackOverflow thread. |
Beta Was this translation helpful? Give feedback.
2 replies
Answer selected by
czyzby
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
This is because LibGDX reuses iterators internally and might return the same instance on subsequent calls. It's basically an anti-pattern, which I'm guessing they implemented to limit the garbage collection on mobiles. See this StackOverflow thread.