[ 
https://issues.apache.org/jira/browse/GROOVY-11296?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Eric Milles resolved GROOVY-11296.
----------------------------------
    Fix Version/s: 5.0.0-alpha-6
       Resolution: Fixed

https://github.com/apache/groovy/commit/b39bef39b5a22bd53769298d43a8192cbedecb63

> shuffled modifies input array
> -----------------------------
>
>                 Key: GROOVY-11296
>                 URL: https://issues.apache.org/jira/browse/GROOVY-11296
>             Project: Groovy
>          Issue Type: Bug
>          Components: groovy-jdk
>    Affects Versions: 3.0.0, 4.0.0, 5.x
>            Reporter: Eric Milles
>            Assignee: Eric Milles
>            Priority: Major
>             Fix For: 5.0.0-alpha-6
>
>
> {code:groovy}
> Integer[] array = [10, 5, 20]
> def result = array.shuffled()
> assert array !== result
> assert array.size() == result.size()
> assert array.every{ result.contains(it) }
> assert array == new Integer[] {10, 5, 20} // fails!
> {code}



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to