develooper Front page | perl.cvs.parrot | Postings from December 2008

[svn:parrot] r34496 - in trunk: include/parrot src/gc

From:
pmichaud
Date:
December 28, 2008 07:49
Subject:
[svn:parrot] r34496 - in trunk: include/parrot src/gc
Message ID:
20081228154857.CCC74CB9F9@x12.develooper.com
Author: pmichaud
Date: Sun Dec 28 07:48:57 2008
New Revision: 34496

Modified:
   trunk/include/parrot/register.h
   trunk/src/gc/register.c

Log:
[core]: eliminate "Parrot_push_context discards qualifiers" warning (kid51++)


Modified: trunk/include/parrot/register.h
==============================================================================
--- trunk/include/parrot/register.h	(original)
+++ trunk/include/parrot/register.h	Sun Dec 28 07:48:57 2008
@@ -110,10 +110,9 @@
 PARROT_WARN_UNUSED_RESULT
 PARROT_CANNOT_RETURN_NULL
 Parrot_Context * Parrot_push_context(PARROT_INTERP,
-    ARGMOD(INTVAL *n_regs_used))
+    ARGIN(const INTVAL *n_regs_used))
         __attribute__nonnull__(1)
-        __attribute__nonnull__(2)
-        FUNC_MODIFIES(*n_regs_used);
+        __attribute__nonnull__(2);
 
 PARROT_EXPORT
 void Parrot_set_context_threshold(SHIM_INTERP, SHIM(Parrot_Context *ctx));
@@ -127,19 +126,17 @@
 PARROT_CANNOT_RETURN_NULL
 PARROT_WARN_UNUSED_RESULT
 Parrot_Context * Parrot_alloc_context(PARROT_INTERP,
-    ARGMOD(INTVAL *number_regs_used),
+    ARGIN(const INTVAL *number_regs_used),
     ARGIN_NULLOK(Parrot_Context *old))
         __attribute__nonnull__(1)
-        __attribute__nonnull__(2)
-        FUNC_MODIFIES(*number_regs_used);
+        __attribute__nonnull__(2);
 
 PARROT_CANNOT_RETURN_NULL
 PARROT_WARN_UNUSED_RESULT
 Parrot_Context * Parrot_set_new_context(PARROT_INTERP,
-    ARGMOD(INTVAL *number_regs_used))
+    ARGIN(const INTVAL *number_regs_used))
         __attribute__nonnull__(1)
-        __attribute__nonnull__(2)
-        FUNC_MODIFIES(*number_regs_used);
+        __attribute__nonnull__(2);
 
 /* Don't modify between HEADERIZER BEGIN / HEADERIZER END.  Your changes will be lost. */
 /* HEADERIZER END: src/gc/register.c */

Modified: trunk/src/gc/register.c
==============================================================================
--- trunk/src/gc/register.c	(original)
+++ trunk/src/gc/register.c	Sun Dec 28 07:48:57 2008
@@ -342,7 +342,7 @@
 PARROT_WARN_UNUSED_RESULT
 PARROT_CANNOT_RETURN_NULL
 Parrot_Context *
-Parrot_push_context(PARROT_INTERP, ARGMOD(INTVAL *n_regs_used))
+Parrot_push_context(PARROT_INTERP, ARGIN(const INTVAL *n_regs_used))
 {
     Parrot_Context * const old = CONTEXT(interp);
     Parrot_Context * const ctx = Parrot_set_new_context(interp, n_regs_used);
@@ -408,7 +408,7 @@
 PARROT_CANNOT_RETURN_NULL
 PARROT_WARN_UNUSED_RESULT
 Parrot_Context *
-Parrot_alloc_context(PARROT_INTERP, ARGMOD(INTVAL *number_regs_used),
+Parrot_alloc_context(PARROT_INTERP, ARGIN(const INTVAL *number_regs_used),
     ARGIN_NULLOK(Parrot_Context *old))
 {
     Parrot_Context *ctx;
@@ -505,7 +505,7 @@
 PARROT_CANNOT_RETURN_NULL
 PARROT_WARN_UNUSED_RESULT
 Parrot_Context *
-Parrot_set_new_context(PARROT_INTERP, ARGMOD(INTVAL *number_regs_used))
+Parrot_set_new_context(PARROT_INTERP, ARGIN(const INTVAL *number_regs_used))
 {
     Parrot_Context *old = CONTEXT(interp);
     Parrot_Context *ctx = Parrot_alloc_context(interp, number_regs_used, old);



nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About