[squeak-dev] valid pragma syntax

Nicolai Hess nicolaihess at gmail.com
Sun Jan 10 12:44:06 UTC 2016


2016-01-10 13:14 GMT+01:00 Levente Uzonyi <leves at caesar.elte.hu>:

>
> On Sun, 10 Jan 2016, Nicolai Hess wrote:
>
> pharo fogbugz issue: 17359 MessageNotUnderstood: receiver of "keywords" is
>> nil
>>
>>
>> is this valid pragma syntax:
>>
>>     <apicall: bool 'SetCursorPos' (long long) module: 'user32.dll'>
>>
>
> This is not a pragma, but the special syntax used by FFI. AFAIK it
> predates pragmas.
>

Ah, ok.


>
>
>> our (pharo) parser can not parse this (does not recognizes the
>> "selector parts" (apicall:module:) right)
>>
>> Any recommendations how to fix this
>> - fix RBParser or
>> - change this pragma, for example, like this
>>   <apicall: #(bool SetCursorPos (long long)) module: 'user32.dll'>
>>
>
> There's nothing to fix here. Either you change your parser, compiler and
> decompiler to support this syntax, but knowing how things work in Pharo,
> this is not an option


Why is this not an option?



> , or change the methods with these callouts, introducing another
> incompatibility between Pharo and the rest, to use pragmas and create a
> custom parser, compiler and decompiler to be able to compile FFI callouts
> into methods when such pragmas are present.
>

As we now included this FFI-Examples, where this is used, I would like to
find a way that works in both, pharo and squeak.

@esteban
is this already supported by "our" FFI and just not by the parser used for
syntax highlighting or wasn't this package supposed to be in Pharo ?



>
> Levente
>
>
>>
>> nicolai
>>
>>
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20160110/f3a0060e/attachment.htm


More information about the Squeak-dev mailing list