* [PATCH v2] string_copying.7: tfix
@ 2023-07-29 13:41 Lennart Jablonka
2023-07-29 15:02 ` Alejandro Colomar
0 siblings, 1 reply; 2+ messages in thread
From: Lennart Jablonka @ 2023-07-29 13:41 UTC (permalink / raw)
To: Alejandro Colomar; +Cc: linux-man, G. Branden Robinson
On some of the commas: There are a few of instances of
Subject verb object partclause, advphrase.
For example:
This function catenates the input character sequence
| subject | verb | object |
contained in a null-padded wixed-width buffer,
| participial clause |
into a destination string.
| adverbial phrase |
Imagining the participial clause away, there shouldn't be a comma
preceding the restrictive adverbial phrase: The input character sequence
is really, always catenated into a destination string; that is
essential. For example:
This function catenates the input character sequence into
a destination string.
The participial clause, being non-restrictive---there is but one input
character sequence that could be meant---, should be enclosed by commas.
That is the existing comma's purpose and doesn't work without the added,
first comma.
Cc: "G. Branden Robinson" <g.branden.robinson@gmail.com>
Signed-off-by: Lennart Jablonka <humm@ljabl.com>
---
man7/string_copying.7 | 22 +++++++++++-----------
1 file changed, 11 insertions(+), 11 deletions(-)
diff --git a/man7/string_copying.7 b/man7/string_copying.7
index 34031ea02..78cb98940 100644
--- a/man7/string_copying.7
+++ b/man7/string_copying.7
@@ -49,7 +49,7 @@ const char *restrict " src ,
.PP
// Zero a fixed-width buffer, and
// copy a string into a character sequence with truncation.
-.BI "char *strncpy(char " dest "[restrict ." sz "], \
+.BI "char *strncpy(char " dst "[restrict ." sz "], \
const char *restrict " src ,
.BI " size_t " sz );
.PP
@@ -279,7 +279,7 @@ instead of
In programs that make considerable use of strings or character sequences,
and need the best performance,
using overlapping character sequences can make a big difference.
-It allows holding subsequences of a larger character sequence.
+It allows holding subsequences of a larger character sequence,
while not duplicating memory
nor using time to do a copy.
.PP
@@ -396,7 +396,7 @@ It returns a pointer suitable for chaining.
Truncation needs to be detected only once after the last chained call.
.IP
This function is not provided by any library;
-See EXAMPLES for a reference implementation.
+see EXAMPLES for a reference implementation.
.\" ----- DESCRIPTION :: Functions :: strlcpy(3bsd), strlcat(3bsd) ----/
.TP
.BR strlcpy (3bsd)
@@ -440,8 +440,8 @@ is a more useful alternative to this function.
.\" ----- DESCRIPTION :: Functions :: zustr2ustp(3) --------------------/
.TP
.BR zustr2ustp (3)
-This function copies the input character sequence
-contained in a null-padded wixed-width buffer,
+This function copies the input character sequence,
+contained in a null-padded fixed-width buffer,
into a destination character sequence.
The programmer is responsible for allocating a buffer large enough.
It returns a pointer suitable for chaining.
@@ -451,12 +451,12 @@ since the size of the original character sequence is always known,
so it wouldn't be very useful.
.IP
This function is not provided by any library;
-See EXAMPLES for a reference implementation.
+see EXAMPLES for a reference implementation.
.\" ----- DESCRIPTION :: Functions :: zustr2stp(3) --------------------/
.TP
.BR zustr2stp (3)
-This function copies the input character sequence
-contained in a null-padded wixed-width buffer,
+This function copies the input character sequence,
+contained in a null-padded fixed-width buffer,
into a destination string.
The programmer is responsible for allocating a buffer large enough.
It returns a pointer suitable for chaining.
@@ -466,7 +466,7 @@ since the size of the original character sequence is always known,
so it wouldn't be very useful.
.IP
This function is not provided by any library;
-See EXAMPLES for a reference implementation.
+see EXAMPLES for a reference implementation.
.\" ----- DESCRIPTION :: Functions :: strncat(3) ----------------------/
.TP
.BR strncat (3)
@@ -474,8 +474,8 @@ Do not confuse this function with
.BR strncpy (3);
they are not related at all.
.IP
-This function catenates the input character sequence
-contained in a null-padded wixed-width buffer,
+This function catenates the input character sequence,
+contained in a null-padded fixed-width buffer,
into a destination string.
The programmer is responsible for allocating a buffer large enough.
The return value is useless.
--
2.40.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH v2] string_copying.7: tfix
2023-07-29 13:41 [PATCH v2] string_copying.7: tfix Lennart Jablonka
@ 2023-07-29 15:02 ` Alejandro Colomar
0 siblings, 0 replies; 2+ messages in thread
From: Alejandro Colomar @ 2023-07-29 15:02 UTC (permalink / raw)
To: linux-man, G. Branden Robinson
[-- Attachment #1.1: Type: text/plain, Size: 4948 bytes --]
Hi Lennart,
On 2023-07-29 15:41, Lennart Jablonka wrote:
> On some of the commas: There are a few of instances of
>
> Subject verb object partclause, advphrase.
>
> For example:
>
> This function catenates the input character sequence
> | subject | verb | object |
>
> contained in a null-padded wixed-width buffer,
> | participial clause |
>
> into a destination string.
> | adverbial phrase |
>
> Imagining the participial clause away, there shouldn't be a comma
> preceding the restrictive adverbial phrase: The input character sequence
> is really, always catenated into a destination string; that is
> essential. For example:
>
> This function catenates the input character sequence into
> a destination string.
>
> The participial clause, being non-restrictive---there is but one input
> character sequence that could be meant---, should be enclosed by commas.
> That is the existing comma's purpose and doesn't work without the added,
> first comma.
>
> Cc: "G. Branden Robinson" <g.branden.robinson@gmail.com>
> Signed-off-by: Lennart Jablonka <humm@ljabl.com>
Patch applied. Thanks!
Alex
> ---
> man7/string_copying.7 | 22 +++++++++++-----------
> 1 file changed, 11 insertions(+), 11 deletions(-)
>
> diff --git a/man7/string_copying.7 b/man7/string_copying.7
> index 34031ea02..78cb98940 100644
> --- a/man7/string_copying.7
> +++ b/man7/string_copying.7
> @@ -49,7 +49,7 @@ const char *restrict " src ,
> .PP
> // Zero a fixed-width buffer, and
> // copy a string into a character sequence with truncation.
> -.BI "char *strncpy(char " dest "[restrict ." sz "], \
> +.BI "char *strncpy(char " dst "[restrict ." sz "], \
> const char *restrict " src ,
> .BI " size_t " sz );
> .PP
> @@ -279,7 +279,7 @@ instead of
> In programs that make considerable use of strings or character sequences,
> and need the best performance,
> using overlapping character sequences can make a big difference.
> -It allows holding subsequences of a larger character sequence.
> +It allows holding subsequences of a larger character sequence,
> while not duplicating memory
> nor using time to do a copy.
> .PP
> @@ -396,7 +396,7 @@ It returns a pointer suitable for chaining.
> Truncation needs to be detected only once after the last chained call.
> .IP
> This function is not provided by any library;
> -See EXAMPLES for a reference implementation.
> +see EXAMPLES for a reference implementation.
> .\" ----- DESCRIPTION :: Functions :: strlcpy(3bsd), strlcat(3bsd) ----/
> .TP
> .BR strlcpy (3bsd)
> @@ -440,8 +440,8 @@ is a more useful alternative to this function.
> .\" ----- DESCRIPTION :: Functions :: zustr2ustp(3) --------------------/
> .TP
> .BR zustr2ustp (3)
> -This function copies the input character sequence
> -contained in a null-padded wixed-width buffer,
> +This function copies the input character sequence,
> +contained in a null-padded fixed-width buffer,
> into a destination character sequence.
> The programmer is responsible for allocating a buffer large enough.
> It returns a pointer suitable for chaining.
> @@ -451,12 +451,12 @@ since the size of the original character sequence is always known,
> so it wouldn't be very useful.
> .IP
> This function is not provided by any library;
> -See EXAMPLES for a reference implementation.
> +see EXAMPLES for a reference implementation.
> .\" ----- DESCRIPTION :: Functions :: zustr2stp(3) --------------------/
> .TP
> .BR zustr2stp (3)
> -This function copies the input character sequence
> -contained in a null-padded wixed-width buffer,
> +This function copies the input character sequence,
> +contained in a null-padded fixed-width buffer,
> into a destination string.
> The programmer is responsible for allocating a buffer large enough.
> It returns a pointer suitable for chaining.
> @@ -466,7 +466,7 @@ since the size of the original character sequence is always known,
> so it wouldn't be very useful.
> .IP
> This function is not provided by any library;
> -See EXAMPLES for a reference implementation.
> +see EXAMPLES for a reference implementation.
> .\" ----- DESCRIPTION :: Functions :: strncat(3) ----------------------/
> .TP
> .BR strncat (3)
> @@ -474,8 +474,8 @@ Do not confuse this function with
> .BR strncpy (3);
> they are not related at all.
> .IP
> -This function catenates the input character sequence
> -contained in a null-padded wixed-width buffer,
> +This function catenates the input character sequence,
> +contained in a null-padded fixed-width buffer,
> into a destination string.
> The programmer is responsible for allocating a buffer large enough.
> The return value is useless.
--
<http://www.alejandro-colomar.es/>
GPG key fingerprint: A9348594CE31283A826FBDD8D57633D441E25BB5
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2023-07-29 15:02 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-07-29 13:41 [PATCH v2] string_copying.7: tfix Lennart Jablonka
2023-07-29 15:02 ` Alejandro Colomar
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox