/* */
/* */
/* */
-/* (C) 1998-2000 Ullrich von Bassewitz */
+/* (C) 1998-2002 Ullrich von Bassewitz */
/* Wacholderweg 14 */
/* D-70597 Stuttgart */
/* EMail: uz@musoftware.de */
+static void DoCharMap (void)
+/* Allow custome character mappings */
+{
+ long Index;
+ long Code;
+
+ /* Read the index as numerical value */
+ Index = ConstExpression ();
+ if (Index < 1 || Index > 255) {
+ /* Value out of range */
+ ErrorSkip (ERR_RANGE);
+ return;
+ }
+
+ /* Comma follows */
+ ConsumeComma ();
+
+ /* Read the character code */
+ Code = ConstExpression ();
+ if (Code < 1 || Code > 255) {
+ /* Value out of range */
+ ErrorSkip (ERR_RANGE);
+ return;
+ }
+
+ /* Set the character translation */
+ TgtTranslateSet ((unsigned) Index, (unsigned char) Code);
+}
+
+
+
static void DoCode (void)
/* Switch to the code segment */
{
{ ccNone, DoBss },
{ ccNone, DoByte },
{ ccNone, DoCase },
+ { ccNone, DoCharMap },
{ ccNone, DoCode },
{ ccNone, DoUnexpected, }, /* .CONCAT */
{ ccNone, DoConDes },
{ ".BYT", TOK_BYTE },
{ ".BYTE", TOK_BYTE },
{ ".CASE", TOK_CASE },
+ { ".CHARMAP", TOK_CHARMAP },
{ ".CODE", TOK_CODE },
{ ".CONCAT", TOK_CONCAT },
{ ".CONDES", TOK_CONDES },
/* */
/* */
/* */
-/* (C) 1998-2000 Ullrich von Bassewitz */
+/* (C) 1998-2002 Ullrich von Bassewitz */
/* Wacholderweg 14 */
/* D-70597 Stuttgart */
/* EMail: uz@musoftware.de */
TOK_BLANK,
TOK_BSS,
TOK_BYTE,
- TOK_CASE,
+ TOK_CASE,
+ TOK_CHARMAP,
TOK_CODE,
- TOK_CONCAT,
+ TOK_CONCAT,
TOK_CONDES,
TOK_CONST,
TOK_CONSTRUCTOR,