Author: julianalbo
Date: Wed Aug  6 16:30:05 2008
New Revision: 30074

Modified:
   trunk/include/parrot/string_funcs.h
   trunk/src/string.c

Log:
allow null argument in string_to_int signature

Modified: trunk/include/parrot/string_funcs.h
==============================================================================
--- trunk/include/parrot/string_funcs.h (original)
+++ trunk/include/parrot/string_funcs.h Wed Aug  6 16:30:05 2008
@@ -474,8 +474,7 @@
 
 PARROT_API
 PARROT_WARN_UNUSED_RESULT
-INTVAL string_to_int(SHIM_INTERP, ARGIN(const STRING *s))
-        __attribute__nonnull__(2);
+INTVAL string_to_int(SHIM_INTERP, ARGIN_NULLOK(const STRING *s));
 
 PARROT_API
 PARROT_WARN_UNUSED_RESULT

Modified: trunk/src/string.c
==============================================================================
--- trunk/src/string.c  (original)
+++ trunk/src/string.c  Wed Aug  6 16:30:05 2008
@@ -1937,9 +1937,9 @@
 PARROT_API
 PARROT_WARN_UNUSED_RESULT
 INTVAL
-string_to_int(SHIM_INTERP, ARGIN(const STRING *s))
+string_to_int(SHIM_INTERP, ARGIN_NULLOK(const STRING *s))
 {
-    if(s == NULL)
+    if (s == NULL)
         return 0;
     {
         const char         *start     = s->strstart;

Reply via email to