releasing Factor 0.67
parent
b48cde2d60
commit
cf6706c910
|
@ -15,7 +15,7 @@ compilation behavior. This means it can only be used in compiled words.
|
||||||
Here is an example from sdl-video.factor:
|
Here is an example from sdl-video.factor:
|
||||||
|
|
||||||
: SDL_LockSurface ( surface -- )
|
: SDL_LockSurface ( surface -- )
|
||||||
"int" "sdl" "SDL_LockSurface" [ "surface*" ] alien-call ; compiled
|
"int" "sdl" "SDL_LockSurface" [ "surface*" ] alien-call ;
|
||||||
|
|
||||||
The parameters are:
|
The parameters are:
|
||||||
|
|
||||||
|
@ -24,9 +24,6 @@ The parameters are:
|
||||||
"SDL_LockSurface" - function
|
"SDL_LockSurface" - function
|
||||||
[ "surface*" ] - parameters
|
[ "surface*" ] - parameters
|
||||||
|
|
||||||
Note the word ends with 'compiled'. This is a hack and won't be needed
|
|
||||||
later.
|
|
||||||
|
|
||||||
Parameters and return values are C type names. C types include the
|
Parameters and return values are C type names. C types include the
|
||||||
following:
|
following:
|
||||||
|
|
||||||
|
@ -42,8 +39,7 @@ BEGIN-STRUCT: point
|
||||||
FIELD: int y
|
FIELD: int y
|
||||||
END-STRUCT
|
END-STRUCT
|
||||||
|
|
||||||
And then referred to in parameter type specifiers as "point*". Struct
|
And then referred to in parameter type specifiers as "point*".
|
||||||
return values are not yet supported.
|
|
||||||
|
|
||||||
Enumerations can be defined; they simply become words that push
|
Enumerations can be defined; they simply become words that push
|
||||||
integers:
|
integers:
|
||||||
|
|
Loading…
Reference in New Issue