backreference gawk broken

Bug #2000741 reported by Eduard Drenth
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
gawk (Ubuntu)
New
Undecided
Unassigned

Bug Description

eduard@eduard-N150CU:~$ echo "ab"|gawk '{gsub(/(a)(b)/,"\2\1"); print}'

eduard@eduard-N150CU:~$

This should print ba

Revision history for this message
Eduard Drenth (eduarddrenth) wrote :

Or actually this should print ba according to the awk manual:

eduard@eduard-N150CU:~$ echo "ab"|gawk '{gsub(/(a)(b)/,"\\2\\1"); print}'
\2\1

Tobias Frost (coldtobi)
affects: gnome-shell-pomodoro (Ubuntu) → gawk (Ubuntu)
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.