Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix how Dyno prints param booleans #25156

Merged
merged 1 commit into from
Jun 3, 2024

Conversation

jabraham17
Copy link
Member

@jabraham17 jabraham17 commented Jun 3, 2024

Fix how Dyno prints booleans, prior to this PR they were printed as 0 and 1 for false and true, respectively.

This effects how chpl-language-server prints param values.

record R {
  param P: bool;
}
// prior to this PR
var a /*: R(1)*/ = new R(true);
// after this PR
var b /*: R(true)*/ = new R(true);

Note that this makes dyno printing match the production compiler.

compilerWarning(b.type:string); // prints 'R(true)'

param p = false;
compilerWarning(p:string); // prints 'false'

Testing

  • make test-cls

[Reviewed by @DanilaFe]

@jabraham17 jabraham17 requested a review from DanilaFe June 3, 2024 15:06
@jabraham17 jabraham17 merged commit 10c9daa into chapel-lang:main Jun 3, 2024
8 checks passed
@jabraham17 jabraham17 deleted the fix-dyno-bool-print branch June 3, 2024 17:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants