As an example, Item#getName shouldn't really ever modify the item's NBT tag, as that can cause very strange problems with item deduplication.
gadget™ should ideally have an option to disallow writing into the ItemStack#nbt field or the contained tag's tree.
Remaining tasks:
[ ] Fix NBT lock leaking when an exception is thrown
[ ] Add NBT locking to ItemVariants and FluidVariants
[ ] Lock item NBT during rendering (test case: GabrielOlvH/Industrial-Revolution#558)
As an example, Item#getName shouldn't really ever modify the item's NBT tag, as that can cause very strange problems with item deduplication. gadget™ should ideally have an option to disallow writing into the
ItemStack#nbt
field or the contained tag's tree.Remaining tasks:
ItemVariant
s andFluidVariant
s