Skip to content

Incorrect prototype when using constexpr #170

Closed
@Chris--A

Description

@Chris--A

Using 1.6.10 IDE compiled a few days ago.

This code requires a manual prototype, otherwise the IDE combines the constexpr and int causing an undeclared type error.

constexpr int test();
constexpr int test() { return 5; }

void setup() {
  Serial.begin(9600);
  Serial.println(test());
}

void loop() {
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions