Changelog for Groovy 3.0.0-alpha-4

Bug

  • [GROOVY-3278] - Using referenced String constant as value of Annotation causes compile error
  • [GROOVY-7330] - Incorrect dynamic proxy creation from map when there are default methods
  • [GROOVY-7362] - Can't compile Java class extending Groovy abstract class with explicit GroovyObject interface
  • [GROOVY-7647] - Incorrect line information for debug
  • [GROOVY-7778] - CLONE - Enum constructor with value throws "unexpected token" error
  • [GROOVY-7854] - Annotation value cannot be concatenated constant
  • [GROOVY-7975] - Use of static final field in an annotation element causes compile errors
  • [GROOVY-8084] - Captured types doesn't work in @CompileStatic
  • [GROOVY-8090] - Incorrectly processing method-level type generics information
  • [GROOVY-8250] - VariableScopeVisitor does not set declaring class on property nodes
  • [GROOVY-8327] - Can't access static method from same class within this constructor call
  • [GROOVY-8337] - STC: instanceof in ternary expression not propagating type info to true expression
  • [GROOVY-8342] - Static compilation error with a method returning an array in a type parameter
  • [GROOVY-8389] - Static import of a property messes with instance method
  • [GROOVY-8405] - Inherited methods with default parameters cause cause static compilation to fail
  • [GROOVY-8495] - GroovyObject method implementations are marked with ACC_SYNTHETIC
  • [GROOVY-8496] - Can't call default getProperty() implementation from Java subclass
  • [GROOVY-8497] - Can't call getProperty() from Java
  • [GROOVY-8549] - Compile Static causes getAt to fail
  • [GROOVY-8641] - Cannot qualify path expression with soft keyword (exclude "def" for now)
  • [GROOVY-8669] - Groovy class does not compile if the ValueType of an annotation is not on the classpath
  • [GROOVY-8675] - GenericsUtils.PARAMETERIZED_TYPE_CACHE is static and private
  • [GROOVY-8680] - The AST of string constant with the unary operator is different with the one generated by the old parser
  • [GROOVY-8688] - AsmDecompiler.parseClass fails against a Java 11 JEP 181 class
  • [GROOVY-8703] - Unexpected behavior with @NamedVariant on constructor *
  • [GROOVY-8727] - JDK 11 Compilation Failure: ClassVisitor.visitNestMemberExperimental throws UnsupportedOperationException
  • [GROOVY-8732] - @CompileStatic refers to private field in parent class
  • [GROOVY-8740] - groovy.util.CliBuilder doesn't handle parse errors correctly
  • [GROOVY-8741] - Single character GString and '==' with Character or Number
  • [GROOVY-8742] - Line number information for method is confusing debugger
  • [GROOVY-8743] - Abstract method in trait should not have method body
  • [GROOVY-8747] - jar/zip file and input stream are not closed in grape
  • [GROOVY-8753] - Compiler error in STC: exception in phase 'instruction selection'
  • [GROOVY-8754] - Spaces in JAVA_HOME not handled properly for JDK10 on windows
  • [GROOVY-8757] - Incorrect bytecode produced after compiling class implementing trait with generic method
  • [GROOVY-8758] - @WithReadLock in inner class of @CompileStatic class causes java.lang.VerifyError
  • [GROOVY-8764] - Closure inside an anonymous class uses wrong outside class instance with @CS
  • [GROOVY-8766] - Groovy packages not compatible with OSGi (ServiceLoader Capability)
  • [GROOVY-8772] - Groovy debugger is on the wrong line when exiting a try/catch
  • [GROOVY-8776] - @MapConstructor with @CompileStatic: Creating static inner class instance => VerifyError: Bad type on operand stack CTE
  • [GROOVY-8777] - @MapConstructor with @CompileStatic: Creating inner class instance => IncompatibleClassChangeError ... does not implement the requested interface java.util.Map
  • [GROOVY-8778] - Cast short-hand breaks for empty map *
  • [GROOVY-8779] - Groovy 2.5.2 triggers a bug in IntelliJ IDEA
  • [GROOVY-8797] - VariableScopeVisitor.getPropertyName does not check for "isser" style method
  • [GROOVY-8800] - Wrong detection of Java 10 version in groovy-json
  • [GROOVY-8805] - GroovyScriptEngine reload fails when dependent class is deleted
  • [GROOVY-8806] - Immutable classes break in groovy 2.5.2
  • [GROOVY-8816] - NPE in inferClosureParameterTypes with CompileStatic and incorrect zero-arg closure
  • [GROOVY-8819] - java.lang.VerifyError when calling this() with static final field from a super class
  • [GROOVY-8822] - Conflict between @Generated and @Delegate
  • [GROOVY-8833] - @Canonical creates invalid hashCode
  • [GROOVY-8835] - AstNodeToScriptVisitor - no token needed for EmptyStatement initialization
  • [GROOVY-8853] - string literal can span rows
  • [GROOVY-8865] - Specifying initial heap size results in an error
  • [GROOVY-8868] - Static factory method does not compile anymore with 2.5.3 (was ok with 2.4.x)
  • [GROOVY-8871] - Long Constants Defined in Groovy 2.5.3 Under OpenJDK 11 Cause an IllegalAccessError
  • [GROOVY-8876] - groovydoc fails with "java.lang.StringIndexOutOfBoundsException: String index out of range: -1" on file with no extension
  • [GROOVY-8881] - Inner class - qualified "this" reference cast exception inside 2 closures
  • [GROOVY-8882] - CS: Loop over elements of String has different element type *
  • [GROOVY-8892] - Trait instance init blocks are called only when there are fields defined in same Trait
  • [GROOVY-8895] - Traits defining getter conflicts with generated getter
  • [GROOVY-8898] - Annotation value cannot take inline constant from enum.
  • [GROOVY-8914] - Error compiling static inner class that extends some other (static) inner class
  • [GROOVY-8917] - Failed to infer parameter type of some SAM, e.g. BinaryOperator
  • [GROOVY-8920] - Fails to infer parameter and return type of SAM on RHS
  • [GROOVY-8931] - AstNodeToScriptVisitor - wrong "extends/implements" order
  • [GROOVY-8936] - NPE occurred when `null` message passed into `MissingPropertyException`

Dependency upgrade

Documentation

  • [GROOVY-8848] - Named parameters documentation missing explanation for mixing multiple parameters use case
  • [GROOVY-8870] - Spread-dot operator on list of lists

Improvement

  • [GROOVY-3360] - Better error message for assert a = 1
  • [GROOVY-7233] - Configurable @Log AST logger field access modifiers
  • [GROOVY-7632] - Groovy named parameters static check
  • [GROOVY-8586] - [PARROT] Support Java 9 ARM blocks
  • [GROOVY-8623] - Groovy Object Browser within Groovy Console could show Groovy version in about help
  • [GROOVY-8635] - Make some groovy classes of groovy console compile static
  • [GROOVY-8679] - BigDecimalMath.MAX_DIVISION_SCALE is hard-coded
  • [GROOVY-8681] - Make non-static inner class creator span rows
  • [GROOVY-8748] - CompileUnit could implement NodeMetaDataHandler to act as a "global" node for metadata
  • [GROOVY-8755] - Forbidden using command chain expression in array initializer to avoid ambiguities
  • [GROOVY-8765] - Annotate generated methods with @Generated
  • [GROOVY-8780] - Add `sha256` DGM
  • [GROOVY-8783] - Support Java 9/10/11 bytecode
  • [GROOVY-8784] - Prepare for supporting JDK 12 bytecode
  • [GROOVY-8793] - Add a switch to clear lexer cache
  • [GROOVY-8812] - Make `Sql` and `BatchingStatementWrapper` implement `AutoCloseable`
  • [GROOVY-8827] - Close a small gap in the EMC DSL for constructors
  • [GROOVY-8851] - [PARROT] Refine safe indexing for maps/named parameters
  • [GROOVY-8858] - Refine GCL to avoid occupying Permanent Area/Metaspace repeatedly for same source code
  • [GROOVY-8861] - Simplify the switch for runtime groovydoc
  • [GROOVY-8872] - Decompiled parameter names don't reflect the names in the bytecode
  • [GROOVY-8880] - Traits - static/instance init blocks
  • [GROOVY-8887] - Support multi-assignment of tuples in STC
  • [GROOVY-8890] - Make "Inspect Tokens" of groovy console support Parrot's tokens
  • [GROOVY-8894] - Improve performance of DGM `leftShift(OutputStream, InputStream)`
  • [GROOVY-8900] - Make class `Tuple0`, `Tuple1`...`Tuple16` final
  • [GROOVY-8910] - Improve the performance of the new Parrot parser
  • [GROOVY-8915] - [PARROT] Make groovydoc configuration flexible
  • [GROOVY-8927] - String variants for take and drop
  • [GROOVY-8939] - Additional Methods in StringGroovyMethods

New Feature

  • [GROOVY-8794] - Add optional groovy-yaml subproject to support parsing and building yaml
  • [GROOVY-8808] - Add DGM `Throwable.asString`
  • [GROOVY-8842] - Implement a smart highlighter for groovy console editor
  • [GROOVY-8935] - Provide a @NullCheck AST transformation similar to Lombok's NonNull

Sub-task

  • [GROOVY-8802] - GroovyObject method implementations when supplied by Groovy compiler are now marked with @Internal
  • [GROOVY-8843] - Fix illegal reflective access within o.c.g.vmplugin.v7.Java7

Task

  • [GROOVY-8664] - switch from findbugs to spotbugs
  • [GROOVY-8691] - Remove deprecated Jaxb methods in old location
  • [GROOVY-8692] - Remove DirectFastStringServiceFactory for Groovy 3
  • [GROOVY-8864] - Backwards compatibility of traits

* potentially breaking change (read issue for details - even minor differences are sometimes flagged as potentially breaking changes)