Details

    • Type: New Feature New Feature
    • Status: Open
    • Priority: Major Major
    • Resolution: Unresolved
    • Affects Version/s: 1.5.1
    • Fix Version/s: None
    • Component/s: groovy-jdk
    • Labels:
      None

      Description

      assert 'abc'.contains('a') //1
      assert 'a' in ('abc'as List) //2
      assert 'a' in 'abc' //3 this breaks

      You ask a string if a substring is contained in it (//1). You can do that with the in-Keyword with Lists (//2), too. But you can't do this with the in-Keyword with Strings. It would be a consistent behaviour from Groovy if you could do //3.

        Activity

        Bernd Schiffer created issue -
        Mark Thomas made changes -
        Field Original Value New Value
        Project Import Sun Apr 05 13:32:57 UTC 2015 [ 1428240777691 ]
        Mark Thomas made changes -
        Workflow jira [ 12731512 ] Default workflow, editable Closed status [ 12743456 ]
        Mark Thomas made changes -
        Project Import Mon Apr 06 02:11:23 UTC 2015 [ 1428286283443 ]
        Mark Thomas made changes -
        Workflow jira [ 12969633 ] Default workflow, editable Closed status [ 12977388 ]

          People

          • Assignee:
            Unassigned
            Reporter:
            Bernd Schiffer
          • Votes:
            1 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

            • Created:
              Updated:

              Development