codeconsole commented on PR #3279:
URL: https://github.com/apache/groovy/pull/3279#issuecomment-7074102954

   @daniellansun Thanks, you're right. In list mode, `clear()`, 
`iterator().remove()` and `Entry.setValue` on the views changed only the 
throwaway `HashMap` copy and threw nothing, and the live `size()`/`contains` 
then disagreed with the view. Fixed in b16dfb3c3d: `currentMap()` now always 
wraps the result in `Collections.unmodifiableMap`, so those calls throw in both 
storage modes. I added list-mode versions of the `testCannotModify*` tests 
(`clear()`, `iterator().remove()`, and `setValue` on the entry view, then a 
check that the map is unchanged), and extended the `synchronizedMap` test 
across the switch to the inner map and a removal back to the arrays. The full 
core `:test` suite and `NodeMetaDataHandlerStressTest` pass.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to