What is standard, and what isn't?
Hello, perhaps somebody can help to clarify the following two questions: 1) Is the comparision with `=' or `<>' of structured variables okay in ISO Pascal? ISO 10206 6.8.3.5 only says that the types to be compared must be compatible. If not, this might be a reasonable extension (already offered by some compilers, *not* including Borland Pascal;). 2) In GPC strings, the schema discriminant "Capacity" is accessible as a "record field" of the string. Is this okay by ISO 10206, and should it be done for other schemata this way, too? And how to tread the "length" field of a string? ISO 10206 6.4.3.3 does not say anything about that. I could imagine the string schema type to be something similar to Type String ( Capacity: Integer ) = record length: Integer; String: packed array [ 1..Capacity ] of Char; end (* String *); except that the "String" field is automatically dereferenced. Thanks for your help, Peter Dipl.-Phys. Peter Gerwinski, Essen, Germany, free physicist and programmer peter.gerwinski@uni-essen.de - http://home.pages.de/~peter.gerwinski/ [970201] maintainer GNU Pascal [970420] - http://home.pages.de/~gnu-pascal/ [970125]
participants (2)
-
Nils Bokermann -
Peter Gerwinski