Subset of C language with tree interpreter and bytecode compiler + VM.
25개 이상의 토픽을 선택하실 수 없습니다. Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 

15 lines
234 B

// memory-leak
#include <stdlib.h>
#include <stdio.h>
#include <assert.h>
int main() {
for (int i = 0; i < 10; ++i) {
int *ptr = malloc(sizeof(*ptr));
assert(ptr != 0);
printf("%p\n", ptr);
*ptr = i;
}
return 0;
}