From 3ecc00c27119bc47ba26b518b7d26c00b69599df Mon Sep 17 00:00:00 2001
From: Norbert Preining <norbert@preining.info>
Date: Fri, 18 Jun 2021 03:01:13 +0000
Subject: CTAN sync 202106180301

---
 macros/latex-dev/base/utf8ienc.dtx | 22 +++++++++++-----------
 1 file changed, 11 insertions(+), 11 deletions(-)

(limited to 'macros/latex-dev/base/utf8ienc.dtx')

diff --git a/macros/latex-dev/base/utf8ienc.dtx b/macros/latex-dev/base/utf8ienc.dtx
index 79c725915c..a517459441 100644
--- a/macros/latex-dev/base/utf8ienc.dtx
+++ b/macros/latex-dev/base/utf8ienc.dtx
@@ -216,7 +216,7 @@
 %<+ts1> \ProvidesFile{ts1enc.dfu}
 %<+x2>  \ProvidesFile{x2enc.dfu}
 %<+all> \ProvidesFile{utf8enc.dfu}
-%<-utf8-2018>   [2021/01/27 v1.2l UTF-8 support for inputenc]
+%<-utf8-2018>   [2021/06/08 v1.2m UTF-8 support]
 %    \end{macrocode}
 %
 %    \begin{macrocode}
@@ -443,14 +443,16 @@
 % \changes{v1.1g}{2005/09/27}{Real spaces do not show up so use \cs{space}}
 % \changes{v1.1o}{2015/08/28}{Show Unicode number of character in hex}
 % \changes{v1.2a}{2018/03/24}{Error message improved for non-UTF-8 sequences}%
+% \changes{v1.2m}{2021/06/08}{Normalize various error messages as kernel errors}
 %    \begin{macrocode}
       \UTFviii@undefined@err{#1}%
 %    \end{macrocode}
 %
 %    \begin{macrocode}
      \else
-      \PackageError{inputenc}{Invalid UTF-8 byte sequence}%
-                             \UTFviii@invalid@help
+       \@latex@error{Invalid UTF-8 byte sequence (\expandafter
+                     \@gobblefour\string#1)}%
+                    \UTFviii@invalid@help
      \fi
 %    \end{macrocode}
 %
@@ -468,8 +470,8 @@
 % \changes{v1.2f}{2018/10/05}{Show invalid byte in hex}%
 %    \begin{macrocode}
 \def\UTFviii@invalid@err#1{%
- \PackageError{inputenc}{Invalid UTF-8 byte "\UTFviii@hexnumber{`#1}}%
-                        \UTFviii@invalid@help}
+ \@latex@error{Invalid UTF-8 byte "\UTFviii@hexnumber{`#1}}%
+              \UTFviii@invalid@help}
 %    \end{macrocode}
 %
 %    \begin{macrocode}
@@ -487,7 +489,7 @@
 % \changes{v1.2a}{2018/03/24}{Macro added}%
 %    \begin{macrocode}
 \def\UTFviii@undefined@err#1{%
-  \PackageError{inputenc}{Unicode character \expandafter
+  \@latex@error{Unicode character \expandafter
                           \UTFviii@splitcsname\string#1\relax
                           \MessageBreak
                           not set up for use with LaTeX}%
@@ -776,8 +778,7 @@
     \ifnum\catcode\count@=13
       \uccode`\~=\count@\uppercase{\def\UTFviii@tmp{\@empty\@empty~}}%
     \else
-      \PackageError{inputenc}%
-                   {Cannot define non-active Unicode char value < 00A0}%
+      \@latex@error{Cannot define non-active Unicode char value < 00A0}%
                    \@eha
       \def\UTFviii@tmp{\UTFviii@tmp}%
     \fi
@@ -803,7 +804,7 @@
 % past this error.
 %    \begin{macrocode}
      \ifnum\count@>"10FFFF\relax
-           \PackageError{inputenc}%
+           \@latex@error
                 {\UTFviii@hexnumber\count@\space too large for Unicode}%
                 {Values between 0 and 10FFFF are permitted}%
       \fi
@@ -2083,8 +2084,7 @@
     \ifnum\catcode\count@=13
       \uccode`\~=\count@\uppercase{\def\UTFviii@tmp{\@empty\@empty~}}%
     \else
-      \PackageError{inputenc}%
-                   {Cannot define non-active Unicode char value < 00A0}%
+      \PackageError{inputenc}{Cannot define non-active Unicode char value < 00A0}%
                    \@eha
       \def\UTFviii@tmp{\UTFviii@tmp}%
     \fi
-- 
cgit v1.2.3

