]> gitweb.factorcode.org Git - factor.git/blobdiff - basis/io/backend/windows/windows.factor
use structs in a few places in windows backend
[factor.git] / basis / io / backend / windows / windows.factor
index 5922e217b0ef299e9f7b536906db9a79e7fbf219..c7be2229ccefa061e2659e0a4e8c23b77fea2409 100755 (executable)
@@ -4,7 +4,8 @@ USING: alien alien.c-types arrays destructors io io.backend
 io.buffers io.files io.ports io.binary io.timeouts system
 strings kernel math namespaces sequences windows.errors
 windows.kernel32 windows.shell32 windows.types windows.winsock
-splitting continuations math.bitwise accessors init sets assocs ;
+splitting continuations math.bitwise accessors init sets assocs
+classes.struct classes ;
 IN: io.backend.windows
 
 TUPLE: win32-handle < disposable handle ;
@@ -50,6 +51,5 @@ HOOK: add-completion io-backend ( port -- )
     } flags ; foldable
 
 : default-security-attributes ( -- obj )
-    "SECURITY_ATTRIBUTES" <c-object>
-    "SECURITY_ATTRIBUTES" heap-size
-    over set-SECURITY_ATTRIBUTES-nLength ;
+    SECURITY_ATTRIBUTES <struct>
+    dup class heap-size >>nLength ;