Skip to content
Snippets Groups Projects
Verified Commit 3562fc71 authored by mirabilos's avatar mirabilos Committed by mirabilos
Browse files

move rejected into per-package namespace

parent f62598bc
No related branches found
No related tags found
No related merge requests found
......@@ -96,6 +96,17 @@
\expandafter\UTFviii@defined\csname u8:#1\endcsname%
}%
% split an invalid byte sequence for error output
\gdef\unicodedomino@splitseq#1:#2\relax{%
\unicodedomino@hexseq#2\relax%
}%
\gdef\unicodedomino@hexseq#1#2\relax{%
% display first octet
\space "\UTFviii@hexbyte{`#1}%
% recursively handle remaining octets
\ifx\relax#2\relax\else\unicodedomino@hexseq#2\relax\fi%
}%
% main handler
\def\UTFviii@defined#1{%
\ifx#1\relax%
......@@ -112,7 +123,7 @@
\else%
% invalid multibyte character
\PackageError{inputenc}{Invalid UTF-8 byte sequence:%
\expandafter\UTFviii@splitseq\string#1\relax}%
\expandafter\unicodedomino@splitseq\string#1\relax}%
\UTFviii@invalid@help
\fi%
\else%
......
......@@ -5,6 +5,7 @@
%-
% Improved Unicode decoding using the fixed-up checkseq code.
%: entire file (plus UTFviii@checkseq) not submitted yet
% override stock function, calling safer decode below
\gdef\decode@UTFviii#1\relax{%
\the\numexpr(\UTFviii@decode0:#1\relax)%
......
......@@ -20,8 +20,7 @@
}%
\fi%
%: reverted partially, override bogus definition
% format a number as Unicode codepoint hex
% override to format a hex Unicode codepoint correctly
\gdef\UTFviii@hexcodepoint#1{%
\ifnum#1<16 U+000%
\else\ifnum#1<256 U+00%
......@@ -32,17 +31,3 @@
\fi\fi\fi\fi\fi%
\UTFviii@hexnumber{#1}%
}%
%: https://github.com/latex3/latex2e/pull/62 (rejected)
% split an invalid byte sequence for output
\ifx\UTFviii@splitseq\@undefined%
\gdef\UTFviii@splitseq#1:#2\relax{%
\UTFviii@hexseq#2\relax%
}%
\gdef\UTFviii@hexseq#1#2\relax{%
% display first octet
\space "\UTFviii@hexbyte{`#1}%
% recursively handle remaining octets
\ifx\relax#2\relax\else\UTFviii@hexseq#2\relax\fi%
}%
\fi%
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment