Skip to content

[Error Message Improvement] improve error on badly indented choice #22354

@jaspervdj-da

Description

@jaspervdj-da

Describe the error message

daml/Rent.daml:20:3: error: parse error on input 'choice'

To reproduce

Forget to indent choice, e.g.:

template RentProposal
  with
    landlord : Party
    tenant : Party
    ...
  where
    signatory landlord
    observer tenant

  choice RentProposal_Accept : ContractId Rent
    controller tenant
    do
      create Rent with
        landlord
        tenant

What do you think is bad about the error message?

It's insufficient, it should point me to the fact that I got the indentation wrong if possible.

Metadata

Metadata

Assignees

Labels

developer-experienceImprovements to the developer experience for the Daml language and its toolinglanguage/error-message-improvementImprovement to error messages (from issue template)

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions