Adriaan van Os wrote:
Adding a typecast triggers another error:
G5:gcc/p/test] adriaan% cat avo11.pas program avo11; type UInt16 = cardinal attribute( size = 16); StyleItemGPC = (bold,italic,underline,outline,shadow,condense,extend); StyleParameter = UInt16; procedure TextFace(face: StyleParameter); external name 'TextFace'; begin TextFace( StyleParameter( [bold, italic])); {internal compiler error} end.
Some thoughts, if you search for good way to express the intent. AFAICS on Mac OSX you can define: StyleParameter = set of StyleItemGPC; and that should do the right thing here. Alternatively, cast of set constructor should work: .... StyleParameterGPC = set of StyleItemGPC; ... TextFace( StyleParameter(StyleParameterGPC[bold, italic])); Double cast TextFace( StyleParameter(StyleParameterGPC([bold, italic]))); should work too, but I just noticed that it did not work (without the patch I posted). -- Waldek Hebisch hebisch@math.uni.wroc.pl