Skip to content

GroovyParser support for multi-catch blocks #1944

@sambsnyd

Description

@sambsnyd

Currently our GroovyParser cannot interpret this form of multi-catch block:

try {

} catch (RuntimeException | Exception e) {

}

It's a bit of a headache to support as I've observed that in this case the Groovy AST only records the first of the exception types being |'d together. So we have to do some hacking to work around that.

This form of catch block is uncommon, particularly in the gradle scripts we care most about, so this isn't high priority. If you care about this issue I'm open to pull requests, or ping me on our community slack.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    Status

    Done

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions