[svn:parrot] r45190 - in trunk: config/gen include/parrot src src/gc src/interp
petdance at svn.parrot.org
petdance at svn.parrot.org
Fri Mar 26 05:52:52 UTC 2010
Author: petdance
Date: Fri Mar 26 05:52:50 2010
New Revision: 45190
URL: https://trac.parrot.org/parrot/changeset/45190
Log:
converted some NOTNULLs to the more accurate ARGIN
Modified:
trunk/config/gen/core_pmcs.pm
trunk/include/parrot/exit.h
trunk/include/parrot/interpreter.h
trunk/include/parrot/thread.h
trunk/src/embed.c
trunk/src/exit.c
trunk/src/gc/gc_private.h
trunk/src/gc/mark_sweep.c
trunk/src/interp/inter_misc.c
trunk/src/thread.c
Modified: trunk/config/gen/core_pmcs.pm
==============================================================================
--- trunk/config/gen/core_pmcs.pm Thu Mar 25 22:23:10 2010 (r45189)
+++ trunk/config/gen/core_pmcs.pm Fri Mar 26 05:52:50 2010 (r45190)
@@ -112,7 +112,7 @@
/* This isn't strictly true, but the headerizer should not bother */
-void Parrot_register_core_pmcs(PARROT_INTERP, NOTNULL(PMC *registry))
+void Parrot_register_core_pmcs(PARROT_INTERP, ARGIN(PMC *registry))
__attribute__nonnull__(1)
__attribute__nonnull__(2);
@@ -132,14 +132,14 @@
print {$OUT} <<'END_C';
}
-static void register_pmc(PARROT_INTERP, NOTNULL(PMC *registry), int pmc_id)
+static void register_pmc(PARROT_INTERP, ARGIN(PMC *registry), int pmc_id)
{
STRING * const key = interp->vtables[pmc_id]->whoami;
VTABLE_set_integer_keyed_str(interp, registry, key, pmc_id);
}
void
-Parrot_register_core_pmcs(PARROT_INTERP, NOTNULL(PMC *registry))
+Parrot_register_core_pmcs(PARROT_INTERP, ARGIN(PMC *registry))
{
END_C
Modified: trunk/include/parrot/exit.h
==============================================================================
--- trunk/include/parrot/exit.h Thu Mar 25 22:23:10 2010 (r45189)
+++ trunk/include/parrot/exit.h Fri Mar 26 05:52:50 2010 (r45190)
@@ -1,5 +1,5 @@
/* exit.h
- * Copyright (C) 2001-2007, Parrot Foundation.
+ * Copyright (C) 2001-2010, Parrot Foundation.
* SVN Info
* $Id$
* Overview:
@@ -34,7 +34,7 @@
PARROT_EXPORT
void Parrot_on_exit(PARROT_INTERP,
- NOTNULL(exit_handler_f function),
+ ARGIN(exit_handler_f function),
ARGIN_NULLOK(void *arg))
__attribute__nonnull__(1)
__attribute__nonnull__(2);
Modified: trunk/include/parrot/interpreter.h
==============================================================================
--- trunk/include/parrot/interpreter.h Thu Mar 25 22:23:10 2010 (r45189)
+++ trunk/include/parrot/interpreter.h Fri Mar 26 05:52:50 2010 (r45190)
@@ -508,7 +508,7 @@
PARROT_EXPORT
void Parrot_compreg(PARROT_INTERP,
ARGIN(STRING *type),
- NOTNULL(Parrot_compiler_func_t func))
+ ARGIN(Parrot_compiler_func_t func))
__attribute__nonnull__(1)
__attribute__nonnull__(2)
__attribute__nonnull__(3);
Modified: trunk/include/parrot/thread.h
==============================================================================
--- trunk/include/parrot/thread.h Thu Mar 25 22:23:10 2010 (r45189)
+++ trunk/include/parrot/thread.h Fri Mar 26 05:52:50 2010 (r45190)
@@ -196,7 +196,7 @@
void pt_thread_detach(UINTVAL tid);
PARROT_CAN_RETURN_NULL
-PMC* pt_thread_join(NOTNULL(Parrot_Interp parent), UINTVAL tid)
+PMC* pt_thread_join(ARGIN(Parrot_Interp parent), UINTVAL tid)
__attribute__nonnull__(1);
void pt_thread_kill(UINTVAL tid);
Modified: trunk/src/embed.c
==============================================================================
--- trunk/src/embed.c Thu Mar 25 22:23:10 2010 (r45189)
+++ trunk/src/embed.c Fri Mar 26 05:52:50 2010 (r45190)
@@ -586,7 +586,7 @@
PARROT_EXPORT
void
-Parrot_pbc_load(PARROT_INTERP, NOTNULL(PackFile *pf))
+Parrot_pbc_load(PARROT_INTERP, ARGIN(PackFile *pf))
{
if (!pf) {
Parrot_io_eprintf(interp, "Invalid packfile\n");
@@ -803,7 +803,7 @@
/*
=item C<opcode_t * Parrot_debug(PARROT_INTERP, Parrot_Interp debugger, opcode_t
-* pc)>
+*pc)>
Runs the interpreter's bytecode in debugging mode.
@@ -814,7 +814,7 @@
PARROT_EXPORT
PARROT_CAN_RETURN_NULL
opcode_t *
-Parrot_debug(PARROT_INTERP, NOTNULL(Parrot_Interp debugger), opcode_t * pc)
+Parrot_debug(PARROT_INTERP, ARGIN(Parrot_Interp debugger), ARGIN(opcode_t *pc))
{
PDB_t * const pdb = debugger->pdb;
Modified: trunk/src/exit.c
==============================================================================
--- trunk/src/exit.c Thu Mar 25 22:23:10 2010 (r45189)
+++ trunk/src/exit.c Fri Mar 26 05:52:50 2010 (r45190)
@@ -1,5 +1,5 @@
/*
-Copyright (C) 2001-2009, Parrot Foundation.
+Copyright (C) 2001-2010, Parrot Foundation.
$Id$
=head1 NAME
@@ -38,7 +38,7 @@
PARROT_EXPORT
void
-Parrot_on_exit(PARROT_INTERP, NOTNULL(exit_handler_f function), ARGIN_NULLOK(void *arg))
+Parrot_on_exit(PARROT_INTERP, ARGIN(exit_handler_f function), ARGIN_NULLOK(void *arg))
{
ASSERT_ARGS(Parrot_on_exit)
Modified: trunk/src/gc/gc_private.h
==============================================================================
--- trunk/src/gc/gc_private.h Thu Mar 25 22:23:10 2010 (r45189)
+++ trunk/src/gc/gc_private.h Fri Mar 26 05:52:50 2010 (r45190)
@@ -349,7 +349,7 @@
ARGMOD(Memory_Pools *mem_pools),
int flag,
ARGIN_NULLOK(void *arg),
- NOTNULL(pool_iter_fn func))
+ ARGIN(pool_iter_fn func))
__attribute__nonnull__(1)
__attribute__nonnull__(2)
__attribute__nonnull__(5)
Modified: trunk/src/gc/mark_sweep.c
==============================================================================
--- trunk/src/gc/mark_sweep.c Thu Mar 25 22:23:10 2010 (r45189)
+++ trunk/src/gc/mark_sweep.c Fri Mar 26 05:52:50 2010 (r45190)
@@ -857,7 +857,7 @@
header_pools_iterate_callback(PARROT_INTERP,
ARGMOD(Memory_Pools *mem_pools),
int flag, ARGIN_NULLOK(void *arg),
- NOTNULL(pool_iter_fn func))
+ ARGIN(pool_iter_fn func))
{
ASSERT_ARGS(header_pools_iterate_callback)
Modified: trunk/src/interp/inter_misc.c
==============================================================================
--- trunk/src/interp/inter_misc.c Thu Mar 25 22:23:10 2010 (r45189)
+++ trunk/src/interp/inter_misc.c Fri Mar 26 05:52:50 2010 (r45190)
@@ -131,14 +131,13 @@
PARROT_EXPORT
void
-Parrot_compreg(PARROT_INTERP, ARGIN(STRING *type),
- NOTNULL(Parrot_compiler_func_t func))
+Parrot_compreg(PARROT_INTERP, ARGIN(STRING *type), ARGIN(Parrot_compiler_func_t func))
{
ASSERT_ARGS(Parrot_compreg)
- PMC* const iglobals = interp->iglobals;
- PMC *nci = Parrot_pmc_new(interp, enum_class_NCI);
- STRING *sc = CONST_STRING(interp, "PJt");
- PMC *hash = VTABLE_get_pmc_keyed_int(interp, interp->iglobals,
+ PMC * const iglobals = interp->iglobals;
+ PMC * const nci = Parrot_pmc_new(interp, enum_class_NCI);
+ STRING * const sc = CONST_STRING(interp, "PJt");
+ PMC * hash = VTABLE_get_pmc_keyed_int(interp, interp->iglobals,
IGLOBALS_COMPREG_HASH);
if (!hash) {
@@ -323,15 +322,14 @@
ASSERT_ARGS(interpinfo_s)
switch (what) {
case EXECUTABLE_FULLNAME: {
- PMC *exe_name = VTABLE_get_pmc_keyed_int(interp, interp->iglobals,
+ PMC * const exe_name = VTABLE_get_pmc_keyed_int(interp, interp->iglobals,
IGLOBALS_EXECUTABLE);
if (PMC_IS_NULL(exe_name))
return string_from_literal(interp, "");
return VTABLE_get_string(interp, exe_name);
}
case EXECUTABLE_BASENAME: {
- STRING *basename;
- PMC *exe_name = VTABLE_get_pmc_keyed_int(interp,
+ PMC * const exe_name = VTABLE_get_pmc_keyed_int(interp,
interp->iglobals, IGLOBALS_EXECUTABLE);
if (PMC_IS_NULL(exe_name))
@@ -339,9 +337,10 @@
else {
/* Need to strip back to what follows the final / or \. */
- STRING * fullname = VTABLE_get_string(interp, exe_name);
+ STRING * const fullname = VTABLE_get_string(interp, exe_name);
char * const fullname_c = Parrot_str_to_cstring(interp, fullname);
int pos = strlen(fullname_c) - 1;
+ STRING *basename;
while (pos > 0
&& fullname_c[pos] != '/'
Modified: trunk/src/thread.c
==============================================================================
--- trunk/src/thread.c Thu Mar 25 22:23:10 2010 (r45189)
+++ trunk/src/thread.c Fri Mar 26 05:52:50 2010 (r45190)
@@ -1,5 +1,5 @@
/*
-Copyright (C) 2001-2009, Parrot Foundation.
+Copyright (C) 2001-2010, Parrot Foundation.
$Id$
=head1 NAME
@@ -89,7 +89,7 @@
static void pt_suspend_one_for_gc(PARROT_INTERP)
__attribute__nonnull__(1);
-static void pt_thread_signal(NOTNULL(Parrot_Interp self), PARROT_INTERP)
+static void pt_thread_signal(ARGIN(Parrot_Interp self), PARROT_INTERP)
__attribute__nonnull__(1)
__attribute__nonnull__(2);
@@ -368,7 +368,7 @@
*/
static void
-pt_thread_signal(NOTNULL(Parrot_Interp self), PARROT_INTERP)
+pt_thread_signal(ARGIN(Parrot_Interp self), PARROT_INTERP)
{
ASSERT_ARGS(pt_thread_signal)
COND_SIGNAL(interp->thread_data->interp_cond);
@@ -1236,7 +1236,7 @@
PARROT_CAN_RETURN_NULL
PMC*
-pt_thread_join(NOTNULL(Parrot_Interp parent), UINTVAL tid)
+pt_thread_join(ARGIN(Parrot_Interp parent), UINTVAL tid)
{
ASSERT_ARGS(pt_thread_join)
int state;
More information about the parrot-commits
mailing list