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

Error constructor should not accept additional fields (rest) for the detail if there are fields with individual field descriptors #28446

Closed
MaryamZi opened this issue Feb 5, 2021 · 0 comments · Fixed by #28631
Assignees
Labels
Planning/SwanLakeDump All issues planned for Swan Lake GA release Priority/Blocker Team/CompilerFE All issues related to Language implementation and Compiler, this exclude run times. Type/SpecDeviation

Comments

@MaryamZi
Copy link
Member

MaryamZi commented Feb 5, 2021

Description:
$title.

See ballerina-platform/ballerina-spec#740, ballerina-platform/ballerina-spec#393

Steps to reproduce:

type Error error<record { int code; }>;

Error e = error Error("One", code = 1000); // OK

Error e2 = error Error("Two", code = 2000, additional = "additional field"); // Should be an error

Affected Versions:
slalpha1

@MaryamZi MaryamZi added Type/SpecDeviation Priority/Blocker Team/CompilerFE All issues related to Language implementation and Compiler, this exclude run times. Planning/SwanLakeDump All issues planned for Swan Lake GA release CompilerSLDump labels Feb 5, 2021
@MaryamZi MaryamZi added this to the Ballerina Swan Lake - Alpha3 milestone Feb 22, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Planning/SwanLakeDump All issues planned for Swan Lake GA release Priority/Blocker Team/CompilerFE All issues related to Language implementation and Compiler, this exclude run times. Type/SpecDeviation
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants