[fpc-pascal] Linux Questions

Marc Santhoff M.Santhoff at t-online.de
Tue Sep 19 16:10:47 CEST 2006


Am Dienstag, den 19.09.2006, 15:11 +0200 schrieb Jonas Maebe:
> enum
> {
>    MS_RDONLY = 1,                /* Mount read-only.  */
> #define MS_RDONLY       MS_RDONLY
>    MS_NOSUID = 2,                /* Ignore suid and sgid bits.  */
> #define MS_NOSUID       MS_NOSUID
> etc.
> 
> So that becomes
> 
> const
>    MS_RDONLY = 1;
>    MS_NOSUID = 2;
> etc.
> 
> You can also try running h2pas on it, but I don't know if it can
> cope  
> with an "enum" definition like that (and if it translates it into a  
> Pascal enumeration, you won't be able to "or" the values together).


h2pas -E

does translate enum's to constants.

Marc





More information about the fpc-pascal mailing list