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

Support builtin fail in nockma/anoma backends via Nockma evaluator #2665

Open
paulcadman opened this issue Feb 21, 2024 · 1 comment
Open
Assignees

Comments

@paulcadman
Copy link
Collaborator

paulcadman commented Feb 21, 2024

It's convenient to use builtin fail in Anoma/Nockma programs for debugging purposes.

The signature of builtin fail is {A : Type} → String → A; and String is not supported in the Anoma/Nockma backend.

We can support builtin fail by compiling it to a cell which crashes in the Anoma / Nockma backend and using the CellInfo annotation mechanism that we're already using to intercept stdlib calls in the Juvix/Nockma evaluator to store the String message. These messages would then be printed if the crash was encountered during evaluation in the Juvix/Nockma evaluator.

@paulcadman
Copy link
Collaborator Author

Is this done?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant