you are viewing a single comment's thread
view the rest of the comments
[–] 88 points 8 months ago (1 child)

The advantage of that last approach is that it has side effects and cannot therefore be optimized out by the compiler.

  • source
  • hideshow 2 child comments
  • [–] 13 points 8 months ago (1 child)

    That’s only one advantage. In theory it does not necessarily terminate, so that’s another one.

  • source
  • parent
  • hideshow 2 child comments