aboutsummaryrefslogtreecommitdiffstats
path: root/doc
diff options
context:
space:
mode:
authorEli Zaretskii2019-06-08 11:14:31 +0300
committerEli Zaretskii2019-06-08 11:14:31 +0300
commit1cc90d21d6e1aa21ab99d163796b41920b413ac7 (patch)
tree21cdaa9bd77ab857b45c6a8c8bb149a64edaa3b0 /doc
parent468e7fb5d44af1cf7b2e16de398cf9dd73e6dc93 (diff)
downloademacs-1cc90d21d6e1aa21ab99d163796b41920b413ac7.tar.gz
emacs-1cc90d21d6e1aa21ab99d163796b41920b413ac7.zip
Minor fixes for the last commits
* src/fns.c (Fbase64url_encode_region) (Fbase64url_encode_string, Fbase64_decode_region) (Fbase64_decode_string): Fix doc strings. (base64_decode_1): Minor stylistic code changes. * doc/lispref/text.texi (Base 64): Fix typos and improve wording of the last committed text.
Diffstat (limited to 'doc')
-rw-r--r--doc/lispref/text.texi44
1 files changed, 17 insertions, 27 deletions
diff --git a/doc/lispref/text.texi b/doc/lispref/text.texi
index 3e0cf4c06f6..55f52698498 100644
--- a/doc/lispref/text.texi
+++ b/doc/lispref/text.texi
@@ -4541,7 +4541,7 @@ Internet informational document describing a standard. RFCs are
4541usually written by technical experts acting on their own initiative, 4541usually written by technical experts acting on their own initiative,
4542and are traditionally written in a pragmatic, experience-driven 4542and are traditionally written in a pragmatic, experience-driven
4543manner. 4543manner.
4544}2045 and also in RFC4648. This section describes the functions for 4544}2045 and also in RFC 4648. This section describes the functions for
4545converting to and from this code. 4545converting to and from this code.
4546 4546
4547@deffn Command base64-encode-region beg end &optional no-line-break 4547@deffn Command base64-encode-region beg end &optional no-line-break
@@ -4559,19 +4559,13 @@ the output is just one long line.
4559@end deffn 4559@end deffn
4560 4560
4561@deffn Command base64url-encode-region beg end &optional no-pad 4561@deffn Command base64url-encode-region beg end &optional no-pad
4562This function converts the region from @var{beg} to @var{end} into base 4562This function is like @code{base64-encode-region}, but it implements
456364 code. It returns the length of the encoded text. An error is 4563the URL variant if base 64 encoding, per RFC 4648, and it doesn't
4564signaled if a character in the region is multibyte, i.e., in a 4564inserts newline characters into the encoded text, so the output is
4565multibyte buffer the region must contain only characters from the 4565just one long line.
4566charsets @code{ascii}, @code{eight-bit-control} and
4567@code{eight-bit-graphic}.
4568
4569Contrary to the function @code{base64-encode-region}, this function
4570doesnt inserts newline characters into the encoded text, so the output
4571is just one long line.
4572 4566
4573If the optional argument @var{no-pad} is non-@code{nil} then padding 4567If the optional argument @var{no-pad} is non-@code{nil} then this
4574(@code{=}) isn't generated. 4568function doesn't generate the padding (@code{=}).
4575@end deffn 4569@end deffn
4576 4570
4577@defun base64-encode-string string &optional no-line-break 4571@defun base64-encode-string string &optional no-line-break
@@ -4587,17 +4581,12 @@ the result string is just one long line.
4587@end defun 4581@end defun
4588 4582
4589@defun base64url-encode-string string &optional no-pad 4583@defun base64url-encode-string string &optional no-pad
4590This function converts the string @var{string} into base 64 url code 4584Like @code{base64-encode-string}, but generates the URL variant of
4591(see RFC4648). It returns a string containing the encoded text. As 4585base 64, and doesn't insert newline characters into the encoded text,
4592for @code{base64url-encode-region}, an error is signaled if a 4586so the result is just one long line.
4593character in the string is multibyte.
4594 4587
4595Contrary to @code{base64-encode-string}, this function doesnt inserts 4588If the optional argument @var{no-pad} is non-@code{nil} then this
4596newline characters into the encoded text, so the result string is just 4589function doesn't generate the padding.
4597one long line.
4598
4599If the optional argument @var{no-pad} is non-@code{nil} then padding
4600(@code{=}) isn't generated.
4601@end defun 4590@end defun
4602 4591
4603@deffn Command base64-decode-region beg end &optional base64url 4592@deffn Command base64-decode-region beg end &optional base64url
@@ -4607,8 +4596,8 @@ the decoded text.
4607 4596
4608The decoding functions ignore newline characters in the encoded text. 4597The decoding functions ignore newline characters in the encoded text.
4609 4598
4610If optional argument @var{base64url} is is non-@code{nil} then padding 4599If optional argument @var{base64url} is is non-@code{nil}, then padding
4611become optionnal and url variant is used (see RFC4648). 4600is optional, and the URL variant of base 64 encoding is used.
4612@end deffn 4601@end deffn
4613 4602
4614@defun base64-decode-string string &optional base64url 4603@defun base64-decode-string string &optional base64url
@@ -4618,8 +4607,9 @@ decoded text.
4618 4607
4619The decoding functions ignore newline characters in the encoded text. 4608The decoding functions ignore newline characters in the encoded text.
4620 4609
4621If optional argument @var{base64url} is is non-@code{nil} then padding 4610
4622become optionnal and url variant is used (see RFC4648). 4611If optional argument @var{base64url} is is non-@code{nil}, then padding
4612is optional, and the URL variant of base 64 encoding is used.
4623@end defun 4613@end defun
4624 4614
4625@node Checksum/Hash 4615@node Checksum/Hash