Blame test/gsubasgn.awk

Packit Service f629e6
# tests for assigning to a function within that function
Packit Service f629e6
Packit Service f629e6
#1 - should be bad
Packit Service f629e6
function test1 (r) { gsub(r, "x", test1) }
Packit Service f629e6
BEGIN { test1("") }
Packit Service f629e6
Packit Service f629e6
#2 - should be bad
Packit Service f629e6
function test2 () { gsub(/a/, "x", test2) }
Packit Service f629e6
BEGIN { test2() }
Packit Service f629e6
Packit Service f629e6
#3 - should be ok
Packit Service f629e6
function test3 (r) { gsub(/a/, "x", r) }
Packit Service f629e6
BEGIN { test3("") }