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

Pascal Schumacher resolved GROOVY-7625.
---------------------------------------
       Resolution: Fixed
    Fix Version/s: 2.4.6

Pull request merged. Thanks!

> document why slashy strings allow brackets but double quoted strings do not
> ---------------------------------------------------------------------------
>
>                 Key: GROOVY-7625
>                 URL: https://issues.apache.org/jira/browse/GROOVY-7625
>             Project: Groovy
>          Issue Type: Documentation
>          Components: Documentation
>    Affects Versions: 2.4.5
>            Reporter: Aseem Bansal
>            Assignee: Pascal Schumacher
>            Priority: Minor
>             Fix For: 2.4.6
>
>
> This
>     println("$()")
> gives me a compiler error "Either escape a dollar sign or bracket the value 
> expression"
> But this 
>     println(/$()/)
> prints `$()` fine. No errors
> Why is there a difference? The only documented difference is that slashy 
> strings make working with backslashes easier. I understand that a variable 
> name cannot start with a bracket so it should be possible to make that 
> special case. Is that the case for the slashy strings?
> Just came across this when doing something with regex.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to