Currently, printf statements are not working. Running the prove for the following program:
#include <stdint.h>
struct In { int in; };
struct Out { int out; };
void compute(struct In *input, struct Out *output){
printf("%d", input->in);
output->out = input->in;
}
Outputs the following error instead of actually printing the input:
Format error in printf, Expected : X Actual: 1
PRINTF in computation_p 0:
Unrecognized token: X
Unrecognized token: I0
Reason for that is that we are looking for the token NUM_X in ComputationProver::compute_printf by checking if strcmp is true-ish. strcmp returns 0 if the strings are equal, thus we have to check for a false-ish value.
After this change proving the program above returns:
Currently, printf statements are not working. Running the prove for the following program:
Outputs the following error instead of actually printing the input:
Reason for that is that we are looking for the token
NUM_X
inComputationProver::compute_printf
by checking ifstrcmp
is true-ish.strcmp
returns 0 if the strings are equal, thus we have to check for a false-ish value.After this change proving the program above returns: