%D \module %D [ file=core-uti, %D version=1997.03.31, %D title=\CONTEXT\ Core Macros, %D subtitle=Utility File Handling, %D author=Hans Hagen, %D date=\currentdate, %D copyright={PRAGMA / Hans Hagen \& Ton Otten}] %C %C This module is part of the \CONTEXT\ macro||package and is %C therefore copyrighted by \PRAGMA. See mreadme.pdf for %C details. \def\savecurrentvalue#1#2% {\immediatewriteutilitycommand{\initializevariable\string#1{#2}}} \let\initializevariable\gdef \appendtoks \globallet\initializevariable\gobbletwoarguments \to \everyafterutilityread \edef\testbytesequence {\rawcharacter{7}% \rawcharacter{27}% %rawcharacter{227}% invalid in xetex, which expects utf \rawcharacter{195}\rawcharacter{128}} % valid utf code \def\thisisbytesequence#1% {\ifx\testbytesequence\empty\else \convertcommand\testbytesequence\to\testbytesequence \convertargument#1\to\ascii \ifx\testbytesequence\ascii \else \writestatus\m!systems{possible problem with 8 bit output}% \fi \fi \global\let\thisisbytesequence\gobbleoneargument} \beginXETEX \let\testbytesequence\empty \endXETEX \appendtoks \immediatewriteutilitycommand{\thisisbytesequence{\testbytesequence}}% \to \everyopenutilities \endinput