-
Notifications
You must be signed in to change notification settings - Fork 237
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
noextract only impacts KreMLin function bodies #1221
Comments
|
Do you expect that it would break Hacl* if those uses were not extracted to OCaml? |
I would expect so, considering the fact that the ML backend erases very little. This is easy enough to try - I think the change to |
|
Beware: if you drop the declaration without even passing it to kremlin, then kremlin's internal checker will be confused and may have less type information at call-site, which may be break some invariants later on. This is why the declaration is kept. Example:
if you don't pass the type signature to kremlin, then kremlin's checker won't have enough information for:
and won't generate the proper monomorphization of Perhaps |
Closing after I reverted @mtzguido 's change... noextract may be poorly named but we still need the stubs to type-check the code at the kremlin level in Low* |
I wanted to create an issue to track discussion on the behavior of
noextract
. Currently this qualifier only impacts KreMLin, and even there a signature is still generated with a body that throws an error.Would it make sense to instead skip the entire extraction pipeline for this attribute, including F# and OCaml extraction? I ran into this in FStarLang/karamel#54 and as mentioned there Guido was able to change the behavior of extraction to bail out on
noextract
much earlier with a simple change.At this point changing the behavior is not too costly since this qualifier has very little usage so far.
The text was updated successfully, but these errors were encountered: