[MLton-commit] r4478

Stephen Weeks MLton@mlton.org
Sun, 7 May 2006 12:06:47 -0700


Fixed __atribute__ ((noreturn)), which goes at the very front of a
function definition.

----------------------------------------------------------------------

U   mlton/branches/on-20050822-x86_64-branch/runtime/basis/MLton/Process/spawne.c
U   mlton/branches/on-20050822-x86_64-branch/runtime/basis/MLton/Process/spawnp.c

----------------------------------------------------------------------

Modified: mlton/branches/on-20050822-x86_64-branch/runtime/basis/MLton/Process/spawne.c
===================================================================
--- mlton/branches/on-20050822-x86_64-branch/runtime/basis/MLton/Process/spawne.c	2006-05-07 18:48:45 UTC (rev 4477)
+++ mlton/branches/on-20050822-x86_64-branch/runtime/basis/MLton/Process/spawne.c	2006-05-07 19:06:46 UTC (rev 4478)
@@ -1,6 +1,7 @@
 #include "platform.h"
 
 #if HAS_SPAWN
+
 C_Errno_t(C_Int_t) MLton_Process_spawne (NullString8_t p, NullString8Array_t a, NullString8Array_t e) {
   const char      *path;
   const char      *asaved;
@@ -27,14 +28,12 @@
   env[en] = esaved;
   return res;
 }
+
 #else
 
+__attribute__ ((noreturn))
 C_Errno_t(C_Int_t) MLton_Process_spawne (__attribute__ ((unused)) NullString8_t p, 
                                          __attribute__ ((unused)) NullString8Array_t a, 
-                                         __attribute__ ((unused)) NullString8Array_t e) __attribute__ ((noreturn));
-
-C_Errno_t(C_Int_t) MLton_Process_spawne (__attribute__ ((unused)) NullString8_t p, 
-                                         __attribute__ ((unused)) NullString8Array_t a, 
                                          __attribute__ ((unused)) NullString8Array_t e) {
   die ("MLton_Process_spawne not implemented");
 }

Modified: mlton/branches/on-20050822-x86_64-branch/runtime/basis/MLton/Process/spawnp.c
===================================================================
--- mlton/branches/on-20050822-x86_64-branch/runtime/basis/MLton/Process/spawnp.c	2006-05-07 18:48:45 UTC (rev 4477)
+++ mlton/branches/on-20050822-x86_64-branch/runtime/basis/MLton/Process/spawnp.c	2006-05-07 19:06:46 UTC (rev 4478)
@@ -1,6 +1,7 @@
 #include "platform.h"
 
 #if HAS_SPAWN
+
 C_Errno_t(C_Int_t) MLton_Process_spawnp (NullString8_t p, NullString8Array_t a) {
   const char      *file;
   const char      *asaved;
@@ -18,12 +19,13 @@
   args[an] = asaved;
   return res;
 }
+
 #else
-C_Errno_t(C_Int_t) MLton_Process_spawnp (__attribute__ ((unused)) NullString8_t p, 
-                                         __attribute__ ((unused)) NullString8Array_t a) __attribute__ ((noreturn));
 
+__attribute__ ((noreturn))
 C_Errno_t(C_Int_t) MLton_Process_spawnp (__attribute__ ((unused)) NullString8_t p, 
                                          __attribute__ ((unused)) NullString8Array_t a) {
   die ("MLton_Process_spawnp not implemented");
 }
+
 #endif