Hi Folks!
Porting a library to a GNU Pascal Unit sometimes means putting a variable instead of a constant.
Like this:
foo.c: --------- int _c_konstant = DEFINED_CONSTANT_IN_C; ---------
foo.pas: ----------- unit Foo;
interface
{!! Treat them as constant !!} var Konstant: Integer; asmname '_c_konstant'; external;
implementation
{$L foo.c}
end. -----------
Doing it this way means a lack of using these "constants" in a "case" statement. It would be nice to have a feature like:
const Konstant = _c_konstant;
or similar.