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
Considering the following code:
#include <stdlib.h> #include <string.h> char a[100]; typedef struct { char *raw; } data_t; void init_data(data_t *data, char *raw) { data->raw = raw; } int main() { strcpy(a, "DATA"); data_t *data = malloc(sizeof(data_t)); init_data(data, a); char *raw = data->raw; printf("%c\n", a[0]); printf("%c\n", raw[0]); printf("%c\n", data->raw[0]); free(data); return 0; }
Using gcc to compile the program and run it, it would output:
D D D
But using shecc, it would output:
D D �
This happens because of the incorrect deference assembly code.
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Considering the following code:
Using gcc to compile the program and run it, it would output:
But using shecc, it would output:
This happens because of the incorrect deference assembly code.
The text was updated successfully, but these errors were encountered: