{: test that constant expression error causes a compilation error }

program e1050( output );

type
   colour = ( black, brown, red, orange, yellow, green, blue, violet, grey, white);

const
   c1 = pred(gold); {!!! gold is undefined}
   c2 = succ(gold); {!!! gold is undefined}
   c3 =  odd(gold); {!!! gold is undefined}
   c4 =  abs(gold); {!!! gold is undefined}
   c5 =  sqr(gold); {!!! gold is undefined}
   c6 =  ord(gold); {!!! gold is undefined}
   c7 =  sqr(gold); {!!! gold is undefined}
   c8 =  chr(gold); {!!! gold is undefined}
   c9 =  -(gold);   {!!! gold is undefined}
   c0 =  +(gold);   {!!! gold is undefined}
   ca =  -gold;     {!!! gold is undefined}
   cb =  +gold;     {!!! gold is undefined}

   b1 = not(gold);
   b2 = not gold;
   b3 = true and gold;
   b4 = false or gold;
   b5 = gold or true;
   b6 = gold and false;

var
   e : colour;
   n : integer;
   s : packed array[1..20] of char;

begin { e1050 }

   e := black;
   n := 2;

   writeln( 'constant expression type error not detected' );
end. { e1050 }

