1
0
mirror of https://github.com/SquidDev-CC/CC-Tweaked synced 2025-01-24 07:56:54 +00:00
CC-Tweaked/projects
Jonathan Coates cdcd82679c
Don't share singleton collections
CC tries to preserve sharing of objects when crossing the Lua/Java
boundary. For instance, if you queue (or send over a modem)
`{ tbl, tbl }`, then the returned table will have `x[1] == x[2]`.

However, this sharing causes issues with Java singletons. If some code
uses a singleton collection (such as List.of()) in multiple places, then
the same Lua table will be used in all those locations. It's incredibly
easy to accidentally, especially when using using Stream.toList.

For now, we special case these collections and don't de-duplicate them.
I'm not wild about this (it's a bit of a hack!), but I think it's
probably the easiest solution for now.

Fixes #1940
2024-08-18 10:20:54 +01:00
..
common Fix several repeated words 2024-08-17 11:39:14 +01:00
common-api Fix several repeated words 2024-08-17 11:39:14 +01:00
core Don't share singleton collections 2024-08-18 10:20:54 +01:00
core-api Don't share singleton collections 2024-08-18 10:20:54 +01:00
fabric Allow placing printouts in lecterns 2024-08-15 21:19:13 +01:00
fabric-api Rewrite turtle upgrade modeller registration API 2024-01-16 23:00:49 +00:00
forge Allow placing printouts in lecterns 2024-08-15 21:19:13 +01:00
forge-api Rewrite turtle upgrade modeller registration API 2024-01-16 23:00:49 +00:00
lints Fix disk drives not setting/clearing removed flag 2024-08-15 09:03:33 +01:00
standalone Small bits of cleanup 2024-06-26 18:07:57 +01:00
web Publish docs via an artifact instead 2024-06-19 09:57:56 +01:00
ARCHITECTURE.md Add a standalone CC:T UI 2023-10-28 17:58:11 +01:00