1 2 3 4 5 6 7 8 9
BEGIN { foo = 0; } /Z.*\(/ { if (foo != 2) foo = 1; } /{/ { foo = 2; } { if (foo == 1) print; }