Skip to content

parenthesis changes expression signature #349

Open
@YashasSamaga

Description

@YashasSamaga

Is this a BUG REPORT, FEATURE REQUEST or QUESTION?:

  • Bug Report
  • Feature Request
  • Question

What happened:

new x[] = "abc"; compiles as it should but new x[] = ("abc"); triggers an error (error 008: must be a constant expression; assumed zero).

What you expected to happen:

new x[] = ("abc"); is a valid and no error should be triggered.

How to reproduce it (as minimally and precisely as possible):

main () {
    new x[] = ("");
}

Environment:

  • Compiler version: 3.10.8

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions