metaborg / mb-rep

Apache License 2.0
2 stars 4 forks source link

Add failing SAF test that shows problem with bigger tbl file #17

Closed Apanatshka closed 4 years ago

Apanatshka commented 4 years ago

@mpsijm Here's the problem in the form of a JUnit test.

Apanatshka commented 4 years ago

I think I found and fixed the problem. StrategoArrayList was being used and skipped the first element in a list during doSlowMatch (a bug). But this usually isn't triggered because the hashCode is checked first. Therefore only two lists in the SAFWriter with hashcollisions were replaced with the wrong other list that was already in the cache (used for maximal sharing in the binary format).