bug-sed
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#21250: sed: empty label for :/b/t commands


From: Stephane Chazelas
Subject: bug#21250: sed: empty label for :/b/t commands
Date: Sun, 23 Aug 2015 13:08:30 +0100
User-agent: Mutt/1.5.21 (2010-09-15)

2015-08-22 22:02:42 -0700, Jim Meyering:
[...]
> I am preparing a patch to remove that functionality, making sed do
> this, instead:
> 
>   $ sed :
>   sed: -e expression #1, char 1: ":" lacks a label
> 
> Does anyone feel differently?
> However, note that I have not surveyed other sed implementations.
[...]

Thanks.

Solaris 11 (/bin/sed or /usr/xpg4/bin/sed):

$ echo aa | sed -e : -e s/a/b/ -e t
ba

(it doesn't complain on :, but t branches to the end, not to
that empty label).

Same with busybox sed.

With FreeBSD sed:

$ echo aa | sed -e : -e s/a/b/ -e t
sed: 1: ":
": empty label

(exit status: 1)

-- 
Stephane





reply via email to

[Prev in Thread] Current Thread [Next in Thread]