summaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorPaolo Bonzini <bonzini@gnu.org>2010-08-17 01:55:12 +0200
committerPaolo Bonzini <bonzini@gnu.org>2010-08-17 01:56:36 +0200
commite1c76b034407016c7b837a466d14e4f983f3866a (patch)
tree84ee9f75c2d1d4ddee38e43191a8f163017b8f1d /doc
parentfbf10902f7b68c8cd79e95a313be5dc674281c4a (diff)
downloadsed-e1c76b034407016c7b837a466d14e4f983f3866a.tar.gz
fix imprecision in the documentation of `D'
2010-08-17 Paolo Bonzini <bonzini@gnu.org> Fix imprecision in the documentation of `D'. * doc/sed-in.texi (D command): Fix documentation of behavior for pattern space ending with \n and with no other newline. Reported by Randall Cotton. * doc/sed.x (D command): Fix documentation of behavior for pattern space ending with \n and with no other newline. * doc/sed.texi: Regenerate. * doc/sed.1: Regenerate. 2010-07-19 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
Diffstat (limited to 'doc')
-rw-r--r--doc/sed-in.texi10
-rw-r--r--doc/sed.19
-rw-r--r--doc/sed.texi8
-rw-r--r--doc/sed.x7
4 files changed, 18 insertions, 16 deletions
diff --git a/doc/sed-in.texi b/doc/sed-in.texi
index 61b7f56..dd808ec 100644
--- a/doc/sed-in.texi
+++ b/doc/sed-in.texi
@@ -846,7 +846,7 @@ string), while the second matches only strings containing
at least one character.
@item ^main.*(.*)
-his matches a string starting with @samp{main},
+This matches a string starting with @samp{main},
followed by an opening and closing
parenthesis. The @samp{n}, @samp{(} and @samp{)} need not
be adjacent.
@@ -1278,10 +1278,10 @@ are output without closing and reopening the file.
@item D
@findex D (delete first line) command
@cindex Delete first line from pattern space
-Delete text in the pattern space up to the first newline.
-If any text is left, restart cycle with the resultant
-pattern space (without reading a new line of input),
-otherwise start a normal new cycle.
+If pattern space contains no newline, start a normal new cycle as if
+the @code{d} command was issued. Otherwise, delete text in the pattern
+space up to the first newline, and restart cycle with the resultant
+pattern space, without reading a new line of input.
@item N
@findex N (append Next line) command
diff --git a/doc/sed.1 b/doc/sed.1
index 42a0a28..49c267d 100644
--- a/doc/sed.1
+++ b/doc/sed.1
@@ -1,5 +1,5 @@
.\" DO NOT MODIFY THIS FILE! It was generated by help2man 1.28.
-.TH SED "1" "December 2009" "sed version 4.2.1" "User Commands"
+.TH SED "1" "August 2010" "sed version 4.2.1" "User Commands"
.SH NAME
sed \- stream editor for filtering and transforming text
.SH SYNOPSIS
@@ -182,9 +182,10 @@ Delete pattern space.
Start next cycle.
.TP
D
-Delete up to the first embedded newline in the pattern space.
-Start next cycle, but skip reading from the input
-if there is still data in the pattern space.
+If pattern space contains no newline, start a normal new cycle as if
+the d command was issued. Otherwise, delete text in the pattern
+space up to the first newline, and restart cycle with the resultant
+pattern space, without reading a new line of input.
.TP
h H
Copy/append pattern space to hold space.
diff --git a/doc/sed.texi b/doc/sed.texi
index 9aaa7e1..c170d6d 100644
--- a/doc/sed.texi
+++ b/doc/sed.texi
@@ -1279,10 +1279,10 @@ are output without closing and reopening the file.
@item D
@findex D (delete first line) command
@cindex Delete first line from pattern space
-Delete text in the pattern space up to the first newline.
-If any text is left, restart cycle with the resultant
-pattern space (without reading a new line of input),
-otherwise start a normal new cycle.
+If pattern space contains no newline, start a normal new cycle as if
+the @code{d} command was issued. Otherwise, delete text in the pattern
+space up to the first newline, and restart cycle with the resultant
+pattern space, without reading a new line of input.
@item N
@findex N (append Next line) command
diff --git a/doc/sed.x b/doc/sed.x
index 2d764df..aabb2c9 100644
--- a/doc/sed.x
+++ b/doc/sed.x
@@ -130,9 +130,10 @@ Delete pattern space.
Start next cycle.
.TP
D
-Delete up to the first embedded newline in the pattern space.
-Start next cycle, but skip reading from the input
-if there is still data in the pattern space.
+If pattern space contains no newline, start a normal new cycle as if
+the d command was issued. Otherwise, delete text in the pattern
+space up to the first newline, and restart cycle with the resultant
+pattern space, without reading a new line of input.
.TP
h H
Copy/append pattern space to hold space.