The code gives undefined behaviour on two counts.
Firstly, redefining a language keyword in itself yields undefined behaviour.
Second, as others have said, a pointer with value `0' is the NULL pointer, and dereferencing it gives undefined behaviour.
The actual result of the construct is therefore undefined behaviour. A common symptom of undefined behaviour is a program crash. However, a crash is not actually guaranteed. It is not even required.
As the the "why?" of writing the macro, the author of that code is obviously a subscriber to the "goto is evil" camp, and sees fit to arbitrarily inflict his/her uninformed prejudices on others. In reality, goto
has its uses even if alternatives are often preferable. Even Dijkstra (the author of the original paper that people often cite to justify not using goto
) only described problems of unbridled use, and did not claim it should be simply avoided. Donald Knuth later wrote a paper on the topic in the mid 70s, including examples where use of goto
is beneficial.