You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently the issue can be worked around by using run-time assertions and collecting all of them at the top of main().
Additionally, a separate binary could be built with only the assertions collected from the program.
Additional Context
No response
Would you like to submit a PR for this Issue?
None
Support Needs
No response
The text was updated successfully, but these errors were encountered:
# Description
## Problem\*
Resolves#5182
## Summary\*
1. New builtin that behaves almost exactly like `assert_constant`, but
also checks that the input is `true`
2. Add recursion to `assert_constant` so that `[dynamic_var]` is no
longer treated as constant
## Additional Context
## Documentation\*
Check one:
- [ ] No documentation needed.
- [ ] Documentation included in this PR.
- [ ] **[For Experimental Features]** Documentation to be submitted in a
separate PR.
# PR Checklist\*
- [x] I have tested the changes locally.
- [x] I have formatted the changes with [Prettier](https://prettier.io/)
and/or `cargo fmt` on default settings.
---------
Co-authored-by: Maxim Vezenov <mvezenov@gmail.com>
Problem
Add a builtin function
static_assert
, that behaves likeassert
, but runs at compile time when encountered in monomorphization.Happy Case
It should:
true
Project Impact
Nice-to-have
Impact Context
This will allow working around our lack of arithmetic generics:
Workaround
None
Workaround Description
Currently the issue can be worked around by using run-time assertions and collecting all of them at the top of
main()
.Additionally, a separate binary could be built with only the assertions collected from the program.
Additional Context
No response
Would you like to submit a PR for this Issue?
None
Support Needs
No response
The text was updated successfully, but these errors were encountered: