[svn:parrot] r46942 - in trunk: include/parrot src/runcore

petdance at svn.parrot.org petdance at svn.parrot.org
Mon May 24 04:12:37 UTC 2010


Author: petdance
Date: Mon May 24 04:12:37 2010
New Revision: 46942
URL: https://trac.parrot.org/parrot/changeset/46942

Log:
make debugger_or_interp static and fixed annotations

Modified:
   trunk/include/parrot/runcore_trace.h
   trunk/src/runcore/trace.c

Modified: trunk/include/parrot/runcore_trace.h
==============================================================================
--- trunk/include/parrot/runcore_trace.h	Mon May 24 04:09:57 2010	(r46941)
+++ trunk/include/parrot/runcore_trace.h	Mon May 24 04:12:37 2010	(r46942)
@@ -18,10 +18,6 @@
 /* HEADERIZER BEGIN: src/runcore/trace.c */
 /* Don't modify between HEADERIZER BEGIN / HEADERIZER END.  Your changes will be lost. */
 
-PARROT_CANNOT_RETURN_NULL
-Interp * debugger_or_interp(PARROT_INTERP)
-        __attribute__nonnull__(1);
-
 int trace_key_dump(PARROT_INTERP, ARGIN(PMC *key))
         __attribute__nonnull__(1)
         __attribute__nonnull__(2);
@@ -44,8 +40,6 @@
 void trace_pmc_dump(PARROT_INTERP, ARGIN_NULLOK(PMC *pmc))
         __attribute__nonnull__(1);
 
-#define ASSERT_ARGS_debugger_or_interp __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
-       PARROT_ASSERT_ARG(interp))
 #define ASSERT_ARGS_trace_key_dump __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
        PARROT_ASSERT_ARG(interp) \
     , PARROT_ASSERT_ARG(key))

Modified: trunk/src/runcore/trace.c
==============================================================================
--- trunk/src/runcore/trace.c	Mon May 24 04:09:57 2010	(r46941)
+++ trunk/src/runcore/trace.c	Mon May 24 04:12:37 2010	(r46942)
@@ -34,12 +34,18 @@
 /* HEADERIZER BEGIN: static */
 /* Don't modify between HEADERIZER BEGIN / HEADERIZER END.  Your changes will be lost. */
 
+PARROT_CANNOT_RETURN_NULL
+static Interp * debugger_or_interp(PARROT_INTERP)
+        __attribute__nonnull__(1);
+
 PARROT_WARN_UNUSED_RESULT
 PARROT_CANNOT_RETURN_NULL
 static STRING* trace_class_name(PARROT_INTERP, ARGIN(const PMC* pmc))
         __attribute__nonnull__(1)
         __attribute__nonnull__(2);
 
+#define ASSERT_ARGS_debugger_or_interp __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
+       PARROT_ASSERT_ARG(interp))
 #define ASSERT_ARGS_trace_class_name __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
        PARROT_ASSERT_ARG(interp) \
     , PARROT_ASSERT_ARG(pmc))
@@ -48,15 +54,17 @@
 
 /*
 
-=item C<Interp * debugger_or_interp(PARROT_INTERP)>
+=item C<static Interp * debugger_or_interp(PARROT_INTERP)>
 
 Get debugger if available
 
 =cut
 */
+
 PARROT_CANNOT_RETURN_NULL
-Interp *
-debugger_or_interp(PARROT_INTERP) {
+static Interp *
+debugger_or_interp(PARROT_INTERP)
+{
     ASSERT_ARGS(debugger_or_interp)
 
     return interp->pdb && interp->pdb->debugger


More information about the parrot-commits mailing list