Paste: fix

Author: blei
Mode: factor
Date: Wed, 28 Oct 2009 15:25:20
Plain Text |
USING: alien.c-types classes.struct ;

STRUCT: device_info { id int } { name char* } ;
SPECIALIZED-ARRAY: device_info

FUNCTION: device_info* get_device_info ( int* length ) ;

0 <int> [ get_device_info ] keep *int <direct-device_info-array> .

Annotation: better example

Author: blei
Mode: factor
Date: Wed, 28 Oct 2009 15:33:33
Plain Text |
STRUCT: my_numbers_struct { numbers int* } { length int } ;
SPECIALIZED-ARRAY: int

FUNCTION: void get_numbers ( my_numbers_struct* a ) ;

my_numbers_struct <struct> [ get_numbers ] keep [ numbers>> ] [ length>> ] bi <direct-int-array> .

New Annotation

Summary:
Author:
Mode:
Body: