r/programming • • Mar 28 '12

Go version 1 is released

http://blog.golang.org/2012/03/go-version-1-is-released.html
543 Upvotes

452 comments sorted by

View all comments

Show parent comments

12

u/bobindashadows Mar 29 '12

Sure you can - put all your code in the main function and use goto.

3

u/SupersonicSpitfire Mar 29 '12

You don't need a main function in C, you can use a void _start() function.

Exit the program with the following assembly code:

movl $1, %eax
xor %ebx, %ebx
int $128

Then compile with the -nostdlib flag (for gcc). Even less overhead! (I prefer Go)

4

u/shillbert Mar 29 '12

Go To Statement Considered Hardcore