Dup Goto 📝

Debugging_01

PT2/lang/awk 03-29 09:10:57
To Pop
14 lines, 72 words, 390 chars Friday 2024-03-29 09:10:57

Breaking Each Line

It is not at first obvious how to break at each line, rather than at a function invocation. The trick is to watch $0:

gawk> watch $0

which will pause provided two successive lines are not identical. The alternative is to introduce a trivial function:

function stophere(x) {
  x = 0
}

and then include stophere() in an action where you want to break.