Skip to content

Compile-time error and wrong message when declaring a non-initialized remote variable #27068

Open
@Guillaume-Helbecque

Description

@Guillaume-Helbecque

Summary of Problem

Description:
Remote variable declaration with noinit produces a compilation error, with a wrong message. For example,

on here.gpus[0] var A: [0..1] int = noinit;

gives

error: cannot use noinit on the variable 'thunkResult' declared without a type

I don't know if using noinit in that case is allowed or not, but I didn't find any note in https://chapel-lang.org/docs/language/spec/locales.html saying that it's not possible (or may be this is only an issue when targeting GPU locales?). The other thing is that the error message is wrong, giving a wrong variable name 'thunkResult' and saying "declared without a type".

Is this issue currently blocking your progress?
No.

Configuration Information

  • Output of chpl --version: 2.4.0

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