Skip to content

Commit

Permalink
GROOVY-8088: For @MapConstructor and @TupleConstructor we should prov…
Browse files Browse the repository at this point in the history
…ide a default undefined value for better Java compatibility (closes groovy#498)
  • Loading branch information
paulk-asert committed Feb 16, 2017
1 parent cf8686a commit 3590d77
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions src/main/groovy/transform/MapConstructor.java
Original file line number Diff line number Diff line change
Expand Up @@ -114,12 +114,12 @@
/**
* A Closure containing statements which will be prepended to the generated constructor. The first statement within the Closure may be "super(someArgs)" in which case the no-arg super constructor won't be called.
*/
Class pre();
Class pre() default Undefined.CLASS.class;

/**
* A Closure containing statements which will be appended to the end of the generated constructor. Useful for validation steps or tweaking the populated fields/properties.
*/
Class post();
Class post() default Undefined.CLASS.class;

/**
* Whether to include all fields and/or properties within the constructor, including those with names that are considered internal.
Expand Down
4 changes: 2 additions & 2 deletions src/main/groovy/transform/TupleConstructor.java
Original file line number Diff line number Diff line change
Expand Up @@ -267,12 +267,12 @@
*
* @since 2.5.0
*/
Class pre();
Class pre() default Undefined.CLASS.class;

/**
* A Closure containing statements which will be appended to the end of the generated constructor. Useful for validation steps or tweaking the populated fields/properties.
*
* @since 2.5.0
*/
Class post();
Class post() default Undefined.CLASS.class;
}

0 comments on commit 3590d77

Please sign in to comment.