You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
$ printf "foo" | cargo run -q sed --posix -e 'a\bar'
sed: <script argument 1>:1:3: error: extra characters after \ at the end of `a' command
$ printf "foo" | sed --posix -e 'a\bar'
foo
bar
So, do we want to implement it as a GNU extension even if the POSIX flag is used? If so, the fix will probably be in the condition below to guide the execution correctly.
Activity
e-kwsm commentedon Jan 18, 2026
a\baris not specified in POSIX; it is a GNU extension. BSD rejects it:LoukasPap commentedon Apr 22, 2026
So, do we want to implement it as a GNU extension even if the POSIX flag is used? If so, the fix will probably be in the condition below to guide the execution correctly.
sed/src/sed/compiler.rs
Lines 1123 to 1127 in ebb321e