[ https://issues.apache.org/jira/browse/GROOVY-7603?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Jochen Theodorou updated GROOVY-7603: ------------------------------------- Labels: usertask (was: ) > Update groovy docs for Category > ------------------------------- > > Key: GROOVY-7603 > URL: https://issues.apache.org/jira/browse/GROOVY-7603 > Project: Groovy > Issue Type: Documentation > Reporter: Aseem Bansal > Labels: usertask > > Category docs refer to @Mixin but they are deprecated > http://docs.groovy-lang.org/latest/html/gapi/groovy/lang/Category.html > I found that using traits is not possible. But it would be nice to be able to > use them. > Tried a workaround but didn't work > {noformat} > trait Util { > Number getTwice() { this * 2 } > Number max(Number otherNumber) { Math.max(this, otherNumber) } > } > @groovy.lang.Category(Number) > abstract class UtilCategory implements Util { > } > {noformat} -- This message was sent by Atlassian JIRA (v6.3.4#6332)