]> gitweb.factorcode.org Git - factor.git/commitdiff
Move size-of to unmaintained until help-lint is fixed
authorSlava Pestov <slava@slava-pestovs-macbook-pro.local>
Fri, 23 Jan 2009 02:07:22 +0000 (20:07 -0600)
committerSlava Pestov <slava@slava-pestovs-macbook-pro.local>
Fri, 23 Jan 2009 02:07:22 +0000 (20:07 -0600)
extra/size-of/size-of.factor [deleted file]
unmaintained/size-of/size-of.factor [new file with mode: 0644]

diff --git a/extra/size-of/size-of.factor b/extra/size-of/size-of.factor
deleted file mode 100644 (file)
index c5fae3c..0000000
+++ /dev/null
@@ -1,61 +0,0 @@
-
-USING: io io.encodings.ascii io.files io.files.temp io.launcher
-       locals math.parser sequences sequences.deep
-       help.syntax
-       easy-help ;
-
-IN: size-of
-
-! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-
-Word: size-of
-
-Values:
-
-    HEADERS sequence : List of header files
-    TYPE    string : A C type
-    n       integer : Size in number of bytes ..
-
-Description:
-
-    Use 'size-of' to find out the size in bytes of a C type. 
-
-    The 'headers' argument is a list of header files to use. You may 
-    pass 'f' to only use 'stdio.h'. ..
-
-Example:
-
-    ! Find the size of 'int'
-
-    f "int" size-of .    ..
-
-Example:
-
-    ! Find the size of the 'XAnyEvent' struct from Xlib.h
-
-    { "X11/Xlib.h" } "XAnyEvent" size-of .    ..
-
-;
-
-! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-
-:: size-of ( HEADERS TYPE -- n )
-
-  [let | C-FILE   [ "size-of.c" temp-file ]
-         EXE-FILE [ "size-of"   temp-file ]
-         INCLUDES [ HEADERS [| FILE | { "#include <" FILE ">" } concat ] map ] |
-
-    {
-      "#include <stdio.h>"
-      INCLUDES
-      "main() { printf( \"%i\" , sizeof( " TYPE " ) ) ; }"
-    }
-
-    flatten C-FILE  ascii  set-file-lines
-
-    { "gcc" C-FILE "-o" EXE-FILE } try-process
-
-    EXE-FILE ascii <process-reader> contents string>number ] ;
-
-! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-
diff --git a/unmaintained/size-of/size-of.factor b/unmaintained/size-of/size-of.factor
new file mode 100644 (file)
index 0000000..c5fae3c
--- /dev/null
@@ -0,0 +1,61 @@
+
+USING: io io.encodings.ascii io.files io.files.temp io.launcher
+       locals math.parser sequences sequences.deep
+       help.syntax
+       easy-help ;
+
+IN: size-of
+
+! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+
+Word: size-of
+
+Values:
+
+    HEADERS sequence : List of header files
+    TYPE    string : A C type
+    n       integer : Size in number of bytes ..
+
+Description:
+
+    Use 'size-of' to find out the size in bytes of a C type. 
+
+    The 'headers' argument is a list of header files to use. You may 
+    pass 'f' to only use 'stdio.h'. ..
+
+Example:
+
+    ! Find the size of 'int'
+
+    f "int" size-of .    ..
+
+Example:
+
+    ! Find the size of the 'XAnyEvent' struct from Xlib.h
+
+    { "X11/Xlib.h" } "XAnyEvent" size-of .    ..
+
+;
+
+! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+
+:: size-of ( HEADERS TYPE -- n )
+
+  [let | C-FILE   [ "size-of.c" temp-file ]
+         EXE-FILE [ "size-of"   temp-file ]
+         INCLUDES [ HEADERS [| FILE | { "#include <" FILE ">" } concat ] map ] |
+
+    {
+      "#include <stdio.h>"
+      INCLUDES
+      "main() { printf( \"%i\" , sizeof( " TYPE " ) ) ; }"
+    }
+
+    flatten C-FILE  ascii  set-file-lines
+
+    { "gcc" C-FILE "-o" EXE-FILE } try-process
+
+    EXE-FILE ascii <process-reader> contents string>number ] ;
+
+! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+