Path: utzoo!mnetor!uunet!husc6!bbn!rochester!cornell!uw-beaver!tektronix!zeus!tekla!dant From: dant@tekla.TEK.COM (Dan Tilque;1893;92-789;LP=A;60aC) Newsgroups: comp.lang.c Subject: Hex escapes in strings Message-ID: <2938@zeus.TEK.COM> Date: 9 Jan 88 12:45:52 GMT Sender: news@zeus.TEK.COM Reply-To: dant@tekla (Dan Tilque) Organization: Church of Christ, Secular Humanist Lines: 15 A question occured to me about hex escapes. Where does the padding nybble go when an odd number of hex digits are in the escaped string? For example: "\x1A2B3 example" The escaped constant has 5 hex digits which fit into 2.5 bytes. Some byte has to be padded with (I assume) null bits. Which byte is it: the initial or the trailing? Does the proposed standard say? This is something that was not needed with octal escapes since they always fit into one byte. Perhaps the standard should be changed to require an even number of hex digits in an escaped string. --- Dan Tilque