]> gitweb.factorcode.org Git - factor.git/commitdiff
vm: change -nosignals to -no-signals.
authorJohn Benediktsson <mrjbq7@gmail.com>
Sat, 21 Jan 2017 06:36:22 +0000 (22:36 -0800)
committerJohn Benediktsson <mrjbq7@gmail.com>
Sat, 21 Jan 2017 06:36:22 +0000 (22:36 -0800)
basis/command-line/startup/startup.factor
vm/image.cpp

index 39f868713a90b9289db5c857413be05ac33096f7..3a9b8cd89422fdb50620c5eefbeab505cede7f13 100644 (file)
@@ -25,7 +25,7 @@ Factor arguments:
     -codeheap=<int>     codeheap size in MiB
     -pic=<int>          max pic size
     -fep                enter fep mode immediately
-    -nosignals          turn off OS signal handling
+    -no-signals         turn off OS signal handling
     -console            open console if possible
     -roots=<paths>      a list of \"" write os windows? ";" ":" ? write "\"-delimited extra vocab roots
 
index 36f8ee9cbdd905726bfcf06354c40343a3d308c4..55bac23afac7f1559a514a071951c9e712cd8a7e 100644 (file)
@@ -65,17 +65,23 @@ void vm_parameters::init_from_args(int argc, vm_char** argv) {
     else if (factor_arg(arg, STRING_LITERAL("-callstack=%d"),
                         &callstack_size))
       ;
-    else if (factor_arg(arg, STRING_LITERAL("-young=%d"), &young_size))
+    else if (factor_arg(arg, STRING_LITERAL("-young=%d"),
+                        &young_size))
       ;
-    else if (factor_arg(arg, STRING_LITERAL("-aging=%d"), &aging_size))
+    else if (factor_arg(arg, STRING_LITERAL("-aging=%d"),
+                        &aging_size))
       ;
-    else if (factor_arg(arg, STRING_LITERAL("-tenured=%d"), &tenured_size))
+    else if (factor_arg(arg, STRING_LITERAL("-tenured=%d"),
+                        &tenured_size))
       ;
-    else if (factor_arg(arg, STRING_LITERAL("-codeheap=%d"), &code_size))
+    else if (factor_arg(arg, STRING_LITERAL("-codeheap=%d"),
+                        &code_size))
       ;
-    else if (factor_arg(arg, STRING_LITERAL("-pic=%d"), &max_pic_size))
+    else if (factor_arg(arg, STRING_LITERAL("-pic=%d"),
+                        &max_pic_size))
       ;
-    else if (factor_arg(arg, STRING_LITERAL("-callbacks=%d"), &callback_size))
+    else if (factor_arg(arg, STRING_LITERAL("-callbacks=%d"),
+                        &callback_size))
       ;
     else if (STRNCMP(arg, STRING_LITERAL("-i="), 3) == 0) {
       // In case you specify -i more than once.
@@ -86,7 +92,7 @@ void vm_parameters::init_from_args(int argc, vm_char** argv) {
     }
     else if (STRCMP(arg, STRING_LITERAL("-fep")) == 0)
       fep = true;
-    else if (STRCMP(arg, STRING_LITERAL("-nosignals")) == 0)
+    else if (STRCMP(arg, STRING_LITERAL("-no-signals")) == 0)
       signals = false;
     else if (STRCMP(arg, STRING_LITERAL("-console")) == 0)
       console = true;
@@ -148,15 +154,21 @@ struct startup_fixup {
     return (code_block*)((cell)obj + code_offset);
   }
 
-  object* translate_data(const object* obj) { return fixup_data((object*)obj); }
+  object* translate_data(const object* obj) {
+    return fixup_data((object*)obj);
+  }
 
   code_block* translate_code(const code_block* compiled) {
     return fixup_code((code_block*)compiled);
   }
 
-  cell size(const object* obj) { return obj->size(*this); }
+  cell size(const object* obj) {
+    return obj->size(*this);
+  }
 
-  cell size(code_block* compiled) { return compiled->size(*this); }
+  cell size(code_block* compiled) {
+    return compiled->size(*this);
+  }
 };
 
 void factor_vm::fixup_heaps(cell data_offset, cell code_offset) {
@@ -205,7 +217,7 @@ bool factor_vm::read_embedded_image_footer(FILE* file,
 
 char *threadsafe_strerror(int errnum) {
   char *buf = (char *) malloc(STRERROR_BUFFER_SIZE);
-  if(!buf) {
+  if (!buf) {
     fatal_error("Out of memory in threadsafe_strerror, errno", errnum);
   }
   THREADSAFE_STRERROR(errnum, buf, STRERROR_BUFFER_SIZE);