[svn:parrot] r41983 - in trunk: include/parrot lib/Parrot/OpTrans src/call
bacek at svn.parrot.org
bacek at svn.parrot.org
Wed Oct 21 19:54:49 UTC 2009
Author: bacek
Date: Wed Oct 21 19:54:48 2009
New Revision: 41983
URL: https://trac.parrot.org/parrot/changeset/41983
Log:
[cage] Rename Parrot_pcc_constants to Parrot_pcc_get_constants for consistency with other methods
Modified:
trunk/include/parrot/call.h
trunk/include/parrot/sub.h
trunk/lib/Parrot/OpTrans/C.pm
trunk/lib/Parrot/OpTrans/CGoto.pm
trunk/src/call/context.c
Modified: trunk/include/parrot/call.h
==============================================================================
--- trunk/include/parrot/call.h Wed Oct 21 18:56:22 2009 (r41982)
+++ trunk/include/parrot/call.h Wed Oct 21 19:54:48 2009 (r41983)
@@ -346,13 +346,6 @@
__attribute__nonnull__(1);
PARROT_EXPORT
-PARROT_CANNOT_RETURN_NULL
-struct PackFile_Constant ** Parrot_pcc_constants(PARROT_INTERP,
- ARGIN(PMC *ctx))
- __attribute__nonnull__(1)
- __attribute__nonnull__(2);
-
-PARROT_EXPORT
UINTVAL Parrot_pcc_dec_recursion_depth(PARROT_INTERP, ARGIN(PMC *ctx))
__attribute__nonnull__(1)
__attribute__nonnull__(2);
@@ -381,6 +374,13 @@
__attribute__nonnull__(2);
PARROT_EXPORT
+PARROT_CANNOT_RETURN_NULL
+struct PackFile_Constant ** Parrot_pcc_get_constants(PARROT_INTERP,
+ ARGIN(PMC *ctx))
+ __attribute__nonnull__(1)
+ __attribute__nonnull__(2);
+
+PARROT_EXPORT
PARROT_CAN_RETURN_NULL
Parrot_Context* Parrot_pcc_get_context_struct(PARROT_INTERP,
ARGIN_NULLOK(PMC *ctx))
@@ -764,9 +764,6 @@
PARROT_ASSERT_ARG(interp))
#define ASSERT_ARGS_Parrot_clear_s __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
PARROT_ASSERT_ARG(interp))
-#define ASSERT_ARGS_Parrot_pcc_constants __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
- PARROT_ASSERT_ARG(interp) \
- , PARROT_ASSERT_ARG(ctx))
#define ASSERT_ARGS_Parrot_pcc_dec_recursion_depth \
__attribute__unused__ int _ASSERT_ARGS_CHECK = (\
PARROT_ASSERT_ARG(interp) \
@@ -783,6 +780,9 @@
#define ASSERT_ARGS_Parrot_pcc_get_caller_ctx __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
PARROT_ASSERT_ARG(interp) \
, PARROT_ASSERT_ARG(ctx))
+#define ASSERT_ARGS_Parrot_pcc_get_constants __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
+ PARROT_ASSERT_ARG(interp) \
+ , PARROT_ASSERT_ARG(ctx))
#define ASSERT_ARGS_Parrot_pcc_get_context_struct __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
PARROT_ASSERT_ARG(interp))
#define ASSERT_ARGS_Parrot_pcc_get_continuation __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
Modified: trunk/include/parrot/sub.h
==============================================================================
--- trunk/include/parrot/sub.h Wed Oct 21 18:56:22 2009 (r41982)
+++ trunk/include/parrot/sub.h Wed Oct 21 19:54:48 2009 (r41983)
@@ -177,6 +177,12 @@
__attribute__nonnull__(1);
PARROT_EXPORT
+void Parrot_capture_lex(PARROT_INTERP, ARGMOD(PMC *sub_pmc))
+ __attribute__nonnull__(1)
+ __attribute__nonnull__(2)
+ FUNC_MODIFIES(*sub_pmc);
+
+PARROT_EXPORT
int Parrot_Context_get_info(PARROT_INTERP,
ARGIN(PMC *ctx),
ARGOUT(Parrot_Context_info *info))
@@ -217,12 +223,6 @@
FUNC_MODIFIES(*cont);
void mark_context_start(void);
-PARROT_EXPORT
-void Parrot_capture_lex(PARROT_INTERP, ARGMOD(PMC *sub_pmc))
- __attribute__nonnull__(1)
- __attribute__nonnull__(2)
- FUNC_MODIFIES(*sub_pmc);
-
void Parrot_continuation_check(PARROT_INTERP, ARGIN(const PMC *pmc))
__attribute__nonnull__(1)
__attribute__nonnull__(2);
@@ -262,6 +262,9 @@
#define ASSERT_ARGS_new_ret_continuation_pmc __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
PARROT_ASSERT_ARG(interp))
+#define ASSERT_ARGS_Parrot_capture_lex __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
+ PARROT_ASSERT_ARG(interp) \
+ , PARROT_ASSERT_ARG(sub_pmc))
#define ASSERT_ARGS_Parrot_Context_get_info __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
PARROT_ASSERT_ARG(interp) \
, PARROT_ASSERT_ARG(ctx) \
@@ -282,9 +285,6 @@
PARROT_ASSERT_ARG(interp) \
, PARROT_ASSERT_ARG(cont))
#define ASSERT_ARGS_mark_context_start __attribute__unused__ int _ASSERT_ARGS_CHECK = (0)
-#define ASSERT_ARGS_Parrot_capture_lex __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
- PARROT_ASSERT_ARG(interp) \
- , PARROT_ASSERT_ARG(sub_pmc))
#define ASSERT_ARGS_Parrot_continuation_check __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
PARROT_ASSERT_ARG(interp) \
, PARROT_ASSERT_ARG(pmc))
Modified: trunk/lib/Parrot/OpTrans/C.pm
==============================================================================
--- trunk/lib/Parrot/OpTrans/C.pm Wed Oct 21 18:56:22 2009 (r41982)
+++ trunk/lib/Parrot/OpTrans/C.pm Wed Oct 21 19:54:48 2009 (r41983)
@@ -60,7 +60,7 @@
#define NREG(i) (CUR_CTX->bp.regs_n[-1L - cur_opcode[i]])
#define PREG(i) (CUR_CTX->bp_ps.regs_p[-1L - cur_opcode[i]])
#define SREG(i) (CUR_CTX->bp_ps.regs_s[cur_opcode[i]])
-#define CONST(i) Parrot_pcc_constants(interp, interp->ctx)[cur_opcode[i]]
+#define CONST(i) Parrot_pcc_get_constants(interp, interp->ctx)[cur_opcode[i]]
END
}
Modified: trunk/lib/Parrot/OpTrans/CGoto.pm
==============================================================================
--- trunk/lib/Parrot/OpTrans/CGoto.pm Wed Oct 21 18:56:22 2009 (r41982)
+++ trunk/lib/Parrot/OpTrans/CGoto.pm Wed Oct 21 19:54:48 2009 (r41983)
@@ -72,7 +72,7 @@
#define NREG(i) REG_NUM(interp, cur_opcode[i])
#define PREG(i) REG_PMC(interp, cur_opcode[i])
#define SREG(i) REG_STR(interp, cur_opcode[i])
-#define CONST(i) Parrot_pcc_constants(interp, interp->ctx)[cur_opcode[i]]
+#define CONST(i) Parrot_pcc_get_constants(interp, interp->ctx)[cur_opcode[i]]
END
}
Modified: trunk/src/call/context.c
==============================================================================
--- trunk/src/call/context.c Wed Oct 21 18:56:22 2009 (r41982)
+++ trunk/src/call/context.c Wed Oct 21 19:54:48 2009 (r41983)
@@ -124,6 +124,27 @@
/*
+=item C<struct PackFile_Constant ** Parrot_pcc_get_constants(PARROT_INTERP, PMC
+*ctx)>
+
+Get reference to constants.
+
+=cut
+
+*/
+
+PARROT_EXPORT
+PARROT_CANNOT_RETURN_NULL
+struct PackFile_Constant **
+Parrot_pcc_get_constants(PARROT_INTERP, ARGIN(PMC *ctx))
+{
+ ASSERT_ARGS(Parrot_pcc_get_constants)
+ return get_context_struct_fast(interp, ctx)->constants;
+}
+
+
+/*
+
=item C<INTVAL Parrot_pcc_get_int_constant(PARROT_INTERP, PMC *ctx, INTVAL idx)>
Get FLOATVAL constant from context.
@@ -206,26 +227,6 @@
}
-/*
-
-=item C<struct PackFile_Constant ** Parrot_pcc_constants(PARROT_INTERP, PMC
-*ctx)>
-
-Get reference to constants.
-
-=cut
-
-*/
-
-PARROT_EXPORT
-PARROT_CANNOT_RETURN_NULL
-struct PackFile_Constant **
-Parrot_pcc_constants(PARROT_INTERP, ARGIN(PMC *ctx))
-{
- ASSERT_ARGS(Parrot_pcc_constants)
- return get_context_struct_fast(interp, ctx)->constants;
-}
-
/*
More information about the parrot-commits
mailing list