White space in ccall impents

Alastair Reid alastair at reid-consulting-uk.ltd.uk
Tue Nov 5 16:53:52 EST 2002


Ian Lynagh <igloo at earth.li> writes:
> Is it just me or does the FFI spec not explain what whitespace is
> needed between the components of the ccall impent? 4.1.1 is the
> obvious place for it to be. In particular, even after reading
> between the lines, questions like "are multiple spaces between
> static and fname allowed", "is a space between & and cid allowed (or
> required)" and "are tabs allowed" seem to remain unanswered.

I remember wondering this when I implemented it in Hugs.  My
understanding of the spec is that the impents contain a sequence of
tokens separated by whitespace.  IIRC, I came to this belief not by
finding something which spells it out but by deciding that any other
interpretation made it impossible to parse the examples in the report
using the grammar in the report.  

If it isn't spelled out explicitly already, it would be good to do that.

In the meantime, I believe the story is that multiple spaces are
allowed, tabs are allowed and any two tokens may be separated by
spaces.  If you catch Hugs behaving otherwise, I'll fix it.

--
Alastair Reid                 alastair at reid-consulting-uk.ltd.uk  
Reid Consulting (UK) Limited  http://www.reid-consulting-uk.ltd.uk/alastair/





More information about the FFI mailing list