Sorry if this isn't the correct forum for KAnnotator questions, I couldn't find a more appropriate one.
Could KAnnotator infer a @Pure annotation on methods? Eligable static methods would guarantee that for a given set of @Immutable parameters, it will produce the same result with no side effects?
It could also infer @Immutable on classes, which would indicate that all of the classes fields are themselves immutable (ie. vals and either primitive types, or immutable classes)?
Instance methods on @Pure classes are @Immutable if they guarantee that for a given instance of the class, and a given set of @Immutable parameters, they are guaranteed to return the same result without side-effects.
Applications for this would include a compiler code-transformation that automatically makes @Pure methods cache their results.