Author: petdance
Date: Sat Jun 16 23:45:14 2007
New Revision: 19058

Modified:
   trunk/include/parrot/library.h
   trunk/src/library.c

Log:
fixed up headerizer flags

Modified: trunk/include/parrot/library.h
==============================================================================
--- trunk/include/parrot/library.h      (original)
+++ trunk/include/parrot/library.h      Sat Jun 16 23:45:14 2007
@@ -50,7 +50,8 @@
     STRING *file /*NN*/,
     enum_runtime_ft type )
         __attribute__nonnull__(1)
-        __attribute__nonnull__(2);
+        __attribute__nonnull__(2)
+        __attribute__warn_unused_result__;
 
 void parrot_init_library_paths( Interp *interp /*NN*/ )
         __attribute__nonnull__(1);

Modified: trunk/src/library.c
==============================================================================
--- trunk/src/library.c (original)
+++ trunk/src/library.c Sat Jun 16 23:45:14 2007
@@ -124,6 +124,7 @@
 
 static PMC*
 get_search_paths(Interp *interp /*NN*/, enum_lib_paths which)
+    /* WARN_UNUSED */
 {
     PMC * const iglobals = interp->iglobals;
     PMC * const lib_paths = VTABLE_get_pmc_keyed_int(interp, iglobals,
@@ -133,6 +134,7 @@
 
 static int
 is_abs_path(const STRING *file /*NN*/)
+    /* WARN_UNUSED */
 {
     const char * const file_name = file->strstart;
     if (file->strlen <= 1)
@@ -264,7 +266,8 @@
 };
 
 static STRING*
-try_load_path(Interp *interp, STRING* path /*NN*/)
+try_load_path(Interp *interp /*NN*/, STRING* path /*NN*/)
+    /* WARN_UNUSED */
 {
     STRING *final;
 
@@ -275,9 +278,9 @@
            string_to_cstring(interp, final ));
 #endif
 
-    final = path_finalize(interp, final );
+    final = path_finalize(interp, final);
 
-    if (Parrot_stat_info_intval(interp, final , STAT_EXISTS)) {
+    if (Parrot_stat_info_intval(interp, final, STAT_EXISTS)) {
         return final;
     }
 
@@ -291,7 +294,8 @@
  */
 
 static STRING*
-try_bytecode_extensions(Interp *interp, STRING* path /*NN*/)
+try_bytecode_extensions(Interp *interp /*NN*/, STRING* path /*NN*/)
+    /* WARN_UNUSED */
 {
     STRING *with_ext, *result;
 
@@ -349,6 +353,7 @@
 STRING*
 Parrot_locate_runtime_file_str(Interp *interp /*NN*/, STRING *file /*NN*/,
         enum_runtime_ft type)
+    /* WARN_UNUSED */
 {
     STRING *prefix;
     STRING *full_name;
@@ -422,6 +427,7 @@
      */
     return string_to_cstring(interp, result);
 }
+
 /*
 
 FUNCDOC: Parrot_get_runtime_prefix
@@ -430,6 +436,9 @@
 c-string for the runtime prefix.  Remember to free the string with
 C<string_cstring_free()>.
 
+XXX This is suboptimal.  We should have two funcs, so it's explicit
+whether we're searching for a STRING or a cstring.
+
 */
 
 PARROT_API
@@ -536,6 +545,7 @@
     }
     return stem;
 }
+
 /*
 
 =head1 SEE ALSO

Reply via email to