]> gitweb.factorcode.org Git - factor.git/commitdiff
classes.struct unit tests to check union heap-size and that structs can be passed...
authorJoe Groff <arcata@gmail.com>
Tue, 18 Aug 2009 18:10:52 +0000 (13:10 -0500)
committerJoe Groff <arcata@gmail.com>
Tue, 18 Aug 2009 18:10:52 +0000 (13:10 -0500)
extra/classes/struct/struct-tests.factor

index 9a2d3a80743e23c1656cba060e1ee38ed4a0aa39..3ab6593070f6ca6f0ed3bdcbe89a698104f23b72 100644 (file)
@@ -1,6 +1,6 @@
 ! (c)Joe Groff bsd license
 USING: accessors alien.c-types classes.c-types classes.struct
-combinators kernel math tools.test ;
+combinators kernel libc math tools.test ;
 IN: classes.struct.tests
 
 STRUCT: foo
@@ -35,4 +35,6 @@ UNION-STRUCT: float-and-bits
     { bits uint } ;
 
 [ 1.0 ] [ float-and-bits <struct> 1.0 float>bits >>bits f>> ] unit-test
+[ 4 ] [ float-and-bits heap-size ] unit-test
 
+[ ] [ foo malloc-struct free ] unit-test