| OLD | NEW |
| 1 #include <stdio.h> | 1 #include <stdio.h> |
| 2 | 2 |
| 3 // Use the assembly function in linux and mac where it is built. | 3 // Use the assembly function in linux and mac where it is built. |
| 4 #if PLATFORM_LINUX || PLATFORM_MAC | 4 #if PLATFORM_LINUX || PLATFORM_MAC |
| 5 extern int asm_function(void); | 5 extern int asm_function(void); |
| 6 #else | 6 #else |
| 7 int asm_function() { | 7 int asm_function() { |
| 8 return 41; | 8 return 41; |
| 9 } | 9 } |
| 10 #endif | 10 #endif |
| 11 | 11 |
| 12 int main(int argc, char *argv[]) | 12 int main(void) |
| 13 { | 13 { |
| 14 fprintf(stdout, "Hello from program.c\n"); | 14 fprintf(stdout, "Hello from program.c\n"); |
| 15 fflush(stdout); | 15 fflush(stdout); |
| 16 fprintf(stdout, "Got %d.\n", asm_function()); | 16 fprintf(stdout, "Got %d.\n", asm_function()); |
| 17 fflush(stdout); | 17 fflush(stdout); |
| 18 return 0; | 18 return 0; |
| 19 } | 19 } |
| OLD | NEW |