We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Conditionals that branch on a boolean variable marked as @CIfDef may extract to code that redefines variables.
@CIfDef
[@CIfDef] assume val b : bool assume val f : unit -> St UInt8.t inline_for_extraction let g () = if b then let n = f () in () let test () = g (); g ()
extracts to
void test() { #if DEBUG uint8_t n1 = f(); #endif #if DEBUG uint8_t n1 = f(); #endif }
which redefines n1. There should be an additional pass to generate unique names, or the variables could be defined in their own block.
n1
The text was updated successfully, but these errors were encountered:
I've seen a similar bug with variables redefined in different branches of a switch statement.
switch
Sorry, something went wrong.
No branches or pull requests
Conditionals that branch on a boolean variable marked as
@CIfDef
may extract to code that redefines variables.extracts to
which redefines
n1
. There should be an additional pass to generate unique names, or the variables could be defined in their own block.The text was updated successfully, but these errors were encountered: