4 ms·
It's a good question. Originally, there were two reasons why I didn't do this. First, the contract is slightly different, as I am also asserting purity. Thi
by bobm_kite9 11y ago
It's a good question. Originally, there were two reasons why I didn't do this.
First, the contract is slightly different, as I am also asserting purity. This means that one @ImmutableValue knows that another @ImmutableValue (perhaps from a library package) is pure. Whereas, a class annotated with @Immutable might not be.
Second, I developed this with the bank I work in in mind. They are still on flavours of Java 6 + 7.
However, I am currently in mind to port this to Checker Framework, http://types.cs.washington.edu/checker-framework/ http://types.cs.washington.edu/checker-framework/ which is fully supported by the JDK8 compiler.
I expect I'll still keep the separate annotation, but there are a lot of benefits from a tooling point of view to doing this (IDE support, gradle etc)
- pron 11y ago> I am currently in mind to port this to Checker Framework, http://types.cs.washington.edu/checker-framework/ http://types.cs.washington.edu/checker-framework/ which is fully supported by the JDK8 compiler. Awesome! Checker is very promising. Unfortunately, its developers have not yet (I think) turned their efforts into making it as easy to use as possible (it could be made very easy to use, but that would take some effort).
- deleted 11y ago[deleted]