On 21 Jul 2006 at 17:00, I wrote:
Is this correct?
OK, never mind, I see from:
http://www.gnu-pascal.de/crystal/gpc/en/mail12883.html
that this appears to be correct behavior.
My second question then is, would it be reasonable to change the routine declarations in gpc units so that an EP program can call them? Currently, routine declarations with multiple string parameters are usually constructed as in these examples:
function Pos (const SubString, s: String): Integer; function LastPos (const SubString, s: String): Integer; function PosCase (const SubString, s: String): Integer;
The EP rule requires the string parameter lengths to be identical, so, e.g.,
LastPos ('/', SomeVar)
...fails unless SomeVar is exactly one character in length. The above would be allowed if the declaration was:
function LastPos (const SubString: String const s: String): Integer;
...I believe.
-- Dave