Only when receiving a message consisting of the atom codice_36 will the loop execute an external call to codeswitch/1 (codice_37 is a preprocessor macro for the current module). If there is a new version of the "counter" module in memory, then its codeswitch/1 function will be called. The practice of having a specific entry-point into a new version allows the programmer to transform state to what is needed in the newer version. In the example, the state is kept as an integer.