SkriptLang / skript-reflect

Powerful reflection utilities for Skript.
MIT License
56 stars 19 forks source link

ConcurrentModificationException #21

Closed TPGamesNL closed 3 years ago

TPGamesNL commented 3 years ago

https://pastebin.com/RMkCavTU

Only occurs on > Java 8 (see J8 computeIfAbsent vs J9 computeIfAbsent)

do something with synchronized keyword (+ find out what it even is)

or replace HashMap with something thread-safe: getCallSite() can be called on init()

LRUCache#computeIfAbsent LRUCache extends LinkedHashMap LinkedHashMap extends HashMap

LRUCache only used in ExprJavaCall

alternatives: HashTable?

TPGamesNL commented 3 years ago

making getCallSite synchronized worked, but new issue: https://pastebin.com/ZSLMXLah

TPGamesNL commented 3 years ago

Fixed in next commit