[svn:parrot] r43994 - trunk/compilers/pirc/src

bacek at svn.parrot.org bacek at svn.parrot.org
Tue Feb 16 09:10:31 UTC 2010


Author: bacek
Date: Tue Feb 16 09:10:30 2010
New Revision: 43994
URL: https://trac.parrot.org/parrot/changeset/43994

Log:
Headerizer happiness work

Modified:
   trunk/compilers/pirc/src/pircompunit.c

Modified: trunk/compilers/pirc/src/pircompunit.c
==============================================================================
--- trunk/compilers/pirc/src/pircompunit.c	Tue Feb 16 08:45:30 2010	(r43993)
+++ trunk/compilers/pirc/src/pircompunit.c	Tue Feb 16 09:10:30 2010	(r43994)
@@ -49,8 +49,86 @@
 /* HEADERIZER BEGIN: static */
 /* Don't modify between HEADERIZER BEGIN / HEADERIZER END.  Your changes will be lost. */
 
-static void add_self_parameter(lexer_state * const lexer);
-#define ASSERT_ARGS_add_self_parameter __attribute__unused__ int _ASSERT_ARGS_CHECK = (0)
+static void add_self_parameter(ARGIN(lexer_state * const lexer))
+        __attribute__nonnull__(1);
+
+PARROT_WARN_UNUSED_RESULT
+PARROT_CANNOT_RETURN_NULL
+static constant * create_const(
+    ARGIN(lexer_state * const lexer),
+    value_type type,
+    va_list arg_ptr)
+        __attribute__nonnull__(1);
+
+static void fixup_local_labels(ARGIN(lexer_state * const lexer))
+        __attribute__nonnull__(1);
+
+PARROT_WARN_UNUSED_RESULT
+PARROT_CANNOT_RETURN_NULL
+static expression * new_expr(
+    ARGIN(lexer_state * const lexer),
+    expr_type type)
+        __attribute__nonnull__(1);
+
+PARROT_CANNOT_RETURN_NULL
+PARROT_WARN_UNUSED_RESULT
+static instruction * new_instruction(
+    ARGIN(lexer_state * const lexer),
+    ARGIN(char const * const opname))
+        __attribute__nonnull__(1)
+        __attribute__nonnull__(2);
+
+PARROT_WARN_UNUSED_RESULT
+PARROT_CANNOT_RETURN_NULL
+static invocation * new_invocation(ARGIN(lexer_state * const lexer))
+        __attribute__nonnull__(1);
+
+PARROT_CANNOT_RETURN_NULL
+PARROT_WARN_UNUSED_RESULT
+static key_entry * new_key_entry(
+    ARGIN(lexer_state * const lexer),
+    ARGIN(expression * const expr))
+        __attribute__nonnull__(1)
+        __attribute__nonnull__(2);
+
+PARROT_MALLOC
+PARROT_CANNOT_RETURN_NULL
+PARROT_WARN_UNUSED_RESULT
+static label * new_label(
+    ARGIN(lexer_state * const lexer),
+    ARGIN(char const * const labelid),
+    int offset)
+        __attribute__nonnull__(1)
+        __attribute__nonnull__(2);
+
+static void new_statement(
+    ARGIN(lexer_state * const lexer),
+    ARGIN(char const * const opname))
+        __attribute__nonnull__(1)
+        __attribute__nonnull__(2);
+
+#define ASSERT_ARGS_add_self_parameter __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
+       PARROT_ASSERT_ARG(lexer))
+#define ASSERT_ARGS_create_const __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
+       PARROT_ASSERT_ARG(lexer))
+#define ASSERT_ARGS_fixup_local_labels __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
+       PARROT_ASSERT_ARG(lexer))
+#define ASSERT_ARGS_new_expr __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
+       PARROT_ASSERT_ARG(lexer))
+#define ASSERT_ARGS_new_instruction __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
+       PARROT_ASSERT_ARG(lexer) \
+    , PARROT_ASSERT_ARG(opname))
+#define ASSERT_ARGS_new_invocation __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
+       PARROT_ASSERT_ARG(lexer))
+#define ASSERT_ARGS_new_key_entry __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
+       PARROT_ASSERT_ARG(lexer) \
+    , PARROT_ASSERT_ARG(expr))
+#define ASSERT_ARGS_new_label __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
+       PARROT_ASSERT_ARG(lexer) \
+    , PARROT_ASSERT_ARG(labelid))
+#define ASSERT_ARGS_new_statement __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
+       PARROT_ASSERT_ARG(lexer) \
+    , PARROT_ASSERT_ARG(opname))
 /* Don't modify between HEADERIZER BEGIN / HEADERIZER END.  Your changes will be lost. */
 /* HEADERIZER END: static */
 
@@ -62,8 +140,7 @@
 
 =over 4
 
-=item C<void
-reset_register_allocator(lexer_state * const lexer)>
+=item C<void reset_register_allocator(lexer_state * const lexer)>
 
 Reset the register numbers for all types. After this
 function has been invoked, the next request for a new
@@ -74,7 +151,8 @@
 
 */
 void
-reset_register_allocator(lexer_state * const lexer) {
+reset_register_allocator(ARGIN(lexer_state * const lexer))
+{
     /* set register allocator to 0 for all register types. */
     int i;
     for (i = 0; i < NUM_PARROT_TYPES; ++i)
@@ -84,8 +162,7 @@
 
 /*
 
-=item C<void
-set_namespace(lexer_state * const lexer, key * const ns)>
+=item C<void set_namespace(lexer_state * const lexer, key * const ns)>
 
 Set the current namespace in the lexer state, so that it is
 available when needed, i.e. when a new subroutine node is
@@ -95,14 +172,15 @@
 
 */
 void
-set_namespace(lexer_state * const lexer, key * const ns) {
+set_namespace(ARGIN(lexer_state * const lexer), key * const ns)
+{
     lexer->current_ns = ns;
 }
 
 /*
 
-=item C<void
-set_sub_outer(lexer_state * const lexer, char const * const outersub)>
+=item C<void set_sub_outer(lexer_state * const lexer, char const * const
+outersub)>
 
 Set the lexically enclosing sub for the current sub.
 Thus, set the :outer() argument to the current subroutine.
@@ -111,7 +189,8 @@
 
 */
 void
-set_sub_outer(lexer_state * const lexer, char const * const outersub) {
+set_sub_outer(ARGIN(lexer_state * const lexer), char const * const outersub)
+{
     CURRENT_SUB(lexer)->info.outersub = outersub;
     SET_FLAG(lexer->subs->flags, PIRC_SUB_FLAG_HAS_OUTER);
 }
@@ -121,7 +200,7 @@
 /*
 
 =item C<void
-set_sub_multi_type(lexer_state * const lexer, expression * const multitype)>
+set_sub_multi_type(ARGIN(lexer_state * const lexer), expression * const multitype)>
 
 Add the multi-method signature type in C<multitype> to the current subroutine.
 
@@ -129,7 +208,8 @@
 
 */
 void
-set_sub_multi_types(lexer_state * const lexer, expression * const multitype) {
+set_sub_multi_types(ARGIN(lexer_state * const lexer), expression * const multitype)
+{
     /* info.num_types is 1 higher than the actual number of types;
      * n=1 means :multi() without any types; therefore, subtract 1 for actual number.
      */
@@ -178,7 +258,8 @@
 
 */
 static void
-add_self_parameter(lexer_state * const lexer) {
+add_self_parameter(ARGIN(lexer_state * const lexer))
+{
     /* only add "self" parameter if :vtable and :method flags have not been set yet */
     if (!TEST_FLAG(CURRENT_SUB(lexer)->flags, (PIRC_SUB_FLAG_VTABLE | PIRC_SUB_FLAG_METHOD))) {
 
@@ -199,7 +280,8 @@
 
 */
 void
-set_sub_vtable(lexer_state * const lexer, char const * vtablename) {
+set_sub_vtable(ARGIN(lexer_state * const lexer), char const * vtablename)
+{
     int vtable_index;
 
     if (vtablename == NULL)  /* the sub's name I<is> the vtablename */
@@ -233,8 +315,7 @@
 
 /*
 
-=item C<void
-set_sub_subid(lexer_state * const lexer, char const * const subid)>
+=item C<void set_sub_subid(lexer_state * const lexer, char const * const subid)>
 
 Set the name specified in the :subid flag on the sub.
 
@@ -242,15 +323,16 @@
 
 */
 void
-set_sub_subid(lexer_state * const lexer, char const * const subid) {
+set_sub_subid(ARGIN(lexer_state * const lexer), char const * const subid)
+{
     CURRENT_SUB(lexer)->info.subid = subid;
     SET_FLAG(lexer->subs->flags, PIRC_SUB_FLAG_SUBID);
 }
 
 /*
 
-=item C<void
-set_sub_methodname(lexer_state * const lexer, char const * const methodname)>
+=item C<void set_sub_methodname(lexer_state * const lexer, char const * const
+methodname)>
 
 Set the :method flag on a sub; if C<methodname> is not NULL, then it contains
 the name by which the sub is stored as a method.
@@ -259,7 +341,8 @@
 
 */
 void
-set_sub_methodname(lexer_state * const lexer, char const * const methodname) {
+set_sub_methodname(ARGIN(lexer_state * const lexer), char const * const methodname)
+{
     if (methodname) /* :method("foo") */
         CURRENT_SUB(lexer)->methodname = methodname;
     else /* :method without a value defaults to the subname. */
@@ -275,8 +358,8 @@
 
 /*
 
-=item C<void
-set_sub_instanceof(lexer_state * const lexer, char const * const classname)>
+=item C<void set_sub_instanceof(lexer_state * const lexer, char const * const
+classname)>
 
 Set the value of the C<:instanceof> flag on a sub. Note that this flag
 is experimental, and not actually used at this point.
@@ -285,14 +368,15 @@
 
 */
 void
-set_sub_instanceof(lexer_state * const lexer, char const * const classname) {
+set_sub_instanceof(ARGIN(lexer_state * const lexer), char const * const classname)
+{
     CURRENT_SUB(lexer)->info.instanceof = classname;
 }
 
 /*
 
-=item C<void
-set_sub_nsentry(lexer_state * const lexer, char const * const nsentry)>
+=item C<void set_sub_nsentry(lexer_state * const lexer, char const * const
+nsentry)>
 
 Set the value of the C<:nsentry> flag on a sub. The value of C<nsentry> is the name
 by which the sub is stored in the namespace.
@@ -301,7 +385,8 @@
 
 */
 void
-set_sub_nsentry(lexer_state * const lexer, char const * const nsentry) {
+set_sub_nsentry(ARGIN(lexer_state * const lexer), char const * const nsentry)
+{
     CURRENT_SUB(lexer)->info.nsentry = nsentry;
 }
 
@@ -316,7 +401,8 @@
 
 */
 void
-set_sub_flag(lexer_state * const lexer, sub_flag flag) {
+set_sub_flag(ARGIN(lexer_state * const lexer), sub_flag flag)
+{
     /* set the specified flag in the current subroutine */
     SET_FLAG(CURRENT_SUB(lexer)->flags, flag);
 
@@ -324,8 +410,7 @@
 
 /*
 
-=item C<void
-new_subr(lexer_state * const lexer, char const * const subname)>
+=item C<void new_subr(lexer_state * const lexer, STRING *subname)>
 
 Create a new subroutine node, and set it as the "current"
 subroutine, on which all other sub-related operations do
@@ -335,7 +420,8 @@
 
 */
 void
-new_subr(lexer_state * const lexer, STRING *subname) {
+new_subr(ARGIN(lexer_state * const lexer), STRING *subname)
+{
     subroutine *newsub       = pir_mem_allocate_zeroed_typed(lexer, subroutine);
     int         index;
 
@@ -386,8 +472,8 @@
 
 /*
 
-=item C<void
-set_sub_name(lexer_state * const lexer, char const * const subname)>
+=item C<void set_sub_name(lexer_state * const lexer, char const * const
+subname)>
 
 Set the current subroutine's name to C<subname>.
 
@@ -395,23 +481,28 @@
 
 */
 void
-set_sub_name(lexer_state * const lexer, char const * const subname) {
+set_sub_name(ARGIN(lexer_state * const lexer), char const * const subname)
+{
     CURRENT_SUB(lexer)->info.subname = subname;
 }
 
 
 /*
 
-=item C<static instruction *
-new_instruction(lexer_state * const lexer, char const * const opname)>
+=item C<static instruction * new_instruction(lexer_state * const lexer, char
+const * const opname)>
 
 Create a new instruction node and set C<opname> as the instruction.
 
 =cut
 
 */
+PARROT_CANNOT_RETURN_NULL
+PARROT_WARN_UNUSED_RESULT
 static instruction *
-new_instruction(lexer_state * const lexer, char const * const opname) {
+new_instruction(ARGIN(lexer_state * const lexer),
+        ARGIN(char const * const opname))
+{
     instruction *ins = pir_mem_allocate_zeroed_typed(lexer, instruction);
     ins->opname      = opname;
     ins->opcode      = -1; /* make sure this field is properly initialized;
@@ -422,8 +513,8 @@
 
 /*
 
-=item C<static void
-new_statement(lexer_state * const lexer, char const * const opname)>
+=item C<static void new_statement(lexer_state * const lexer, char const * const
+opname)>
 
 Constructor for a statement. The newly allocated statement will be inserted
 into the current subroutine's statements list.
@@ -432,7 +523,9 @@
 
 */
 static void
-new_statement(lexer_state * const lexer, char const * const opname) {
+new_statement(ARGIN(lexer_state * const lexer),
+        ARGIN(char const * const opname))
+{
     instruction *instr = new_instruction(lexer, opname);
 
     /* Each instruction has a sequence number to be able to
@@ -464,8 +557,7 @@
 
 /*
 
-=item C<void
-set_curtarget(lexer_state * const lexer, target * const t)>
+=item C<target * set_curtarget(lexer_state * const lexer, target * const t)>
 
 Sets the target C<t> as the current target in C<lexer> to
 make it accessible to other parse actions. C<t> is returned.
@@ -476,15 +568,15 @@
 PARROT_IGNORABLE_RESULT
 PARROT_CANNOT_RETURN_NULL
 target *
-set_curtarget(lexer_state * const lexer, target * const t) {
+set_curtarget(ARGIN(lexer_state * const lexer), target * const t)
+{
     lexer->curtarget = t;
     return t;
 }
 
 /*
 
-=item C<argument *
-set_curarg(lexer_state * const lexer, argument * const arg)>
+=item C<argument * set_curarg(lexer_state * const lexer, argument * const arg)>
 
 Sets the argument C<arg> as the current argument in C<lexer>
 to make it accessible to other parse actions. C<arg> is returned.
@@ -495,7 +587,8 @@
 PARROT_IGNORABLE_RESULT
 PARROT_CANNOT_RETURN_NULL
 argument *
-set_curarg(lexer_state * const lexer, argument * const arg) {
+set_curarg(ARGIN(lexer_state * const lexer), argument * const arg)
+{
     lexer->curarg = arg;
     return arg;
 }
@@ -525,7 +618,8 @@
 PARROT_PURE_FUNCTION
 PARROT_WARN_UNUSED_RESULT
 int
-targets_equal(target const * const left, target const * const right) {
+targets_equal(target const * const left, target const * const right)
+{
 
 
     if (TEST_FLAG(left->flags, TARGET_FLAG_IS_REG)) {      /* if left is a reg */
@@ -556,8 +650,7 @@
 
 /*
 
-=item C<target *
-new_target(lexer_state * const lexer)>
+=item C<target * new_target(lexer_state * const lexer)>
 
 Create a new target node. The node's next pointer is initialized to itself.
 
@@ -567,7 +660,8 @@
 PARROT_WARN_UNUSED_RESULT
 PARROT_CANNOT_RETURN_NULL
 target *
-new_target(lexer_state * const lexer) {
+new_target(ARGIN(lexer_state * const lexer))
+{
     target *t       = pir_mem_allocate_zeroed_typed(lexer, target);
     t->key          = NULL;
     t->next         = t; /* circly linked list */
@@ -575,8 +669,7 @@
 }
 
 /*
-=item C<void
-set_target_key(target * const t, key * const k)>
+=item C<void set_target_key(target * const t, key * const k)>
 
 Set the key C<k> on target C<t>. For instance:
 
@@ -588,14 +681,15 @@
 
 */
 void
-set_target_key(target * const t, key * const k) {
+set_target_key(target * const t, key * const k)
+{
     t->key = k;
 }
 
 /*
 
-=item C<target *
-target_from_symbol(lexer_state * const lexer, symbol * const sym)>
+=item C<target * target_from_symbol(lexer_state * const lexer, symbol * const
+sym)>
 
 Convert symbol C<sym> into a target node. The resulting target has
 a pointer to C<sym>.
@@ -606,7 +700,8 @@
 PARROT_WARN_UNUSED_RESULT
 PARROT_CANNOT_RETURN_NULL
 target *
-target_from_symbol(lexer_state * const lexer, symbol * const sym) {
+target_from_symbol(ARGIN(lexer_state * const lexer), symbol * const sym)
+{
     target *t  = new_target(lexer);
 
     t->flags   = sym->flags; /* copy the flags */
@@ -632,7 +727,8 @@
 PARROT_IGNORABLE_RESULT
 PARROT_CANNOT_RETURN_NULL
 target *
-add_target(lexer_state * const lexer, target *last, target * const t) {
+add_target(ARGIN(lexer_state * const lexer), target *last, target * const t)
+{
     PARROT_ASSERT(last);
     PARROT_ASSERT(t);
 
@@ -646,8 +742,8 @@
 
 /*
 
-=item C<target *
-add_param(lexer_state * const lexer, pir_type type, char const * const name)>
+=item C<target * add_param(lexer_state * const lexer, pir_type type, char const
+* const name)>
 
 Add a parameter of type C<type> and named C<name> to the current
 subroutine. The parameter will be declared as a local symbol in the
@@ -659,7 +755,8 @@
 PARROT_IGNORABLE_RESULT
 PARROT_CANNOT_RETURN_NULL
 target *
-add_param(lexer_state * const lexer, pir_type type, char const * const name) {
+add_param(ARGIN(lexer_state * const lexer), pir_type type, char const * const name)
+{
     target *targ = new_target(lexer);
     symbol *sym  = new_symbol(lexer, name, type);
 
@@ -694,8 +791,8 @@
 
 /*
 
-=item C<void
-set_param_alias(lexer_state * const lexer, char const * const alias)>
+=item C<target * set_param_alias(lexer_state * const lexer, char const * const
+alias)>
 
 Set the argument of the :named flag for the current target
 (parameter). Returns the current target (parameter). This function assumes
@@ -708,7 +805,8 @@
 PARROT_IGNORABLE_RESULT
 PARROT_CANNOT_RETURN_NULL
 target *
-set_param_alias(lexer_state * const lexer, char const * const alias) {
+set_param_alias(ARGIN(lexer_state * const lexer), char const * const alias)
+{
     PARROT_ASSERT(lexer->curtarget != NULL);
 
     /* if no alias was specified, default to the target's name, if it's not a register. */
@@ -740,7 +838,8 @@
 PARROT_IGNORABLE_RESULT
 PARROT_CANNOT_RETURN_NULL
 target *
-set_param_flag(lexer_state * const lexer, target * const param, target_flag flag) {
+set_param_flag(ARGIN(lexer_state * const lexer), target * const param, target_flag flag)
+{
     SET_FLAG(param->flags, flag);
 
     /* note that param is always an identifier; registers are not allowed as parameters.
@@ -763,8 +862,8 @@
 
 /*
 
-=item C<argument *
-new_argument(lexer_state * const lexer, expression * const expr)>
+=item C<argument * new_argument(lexer_state * const lexer, expression * const
+expr)>
 
 Create a new argument node which wraps C<expr>. The new argument node
 is circular linked, meaning its C<next> pointer points to itself.
@@ -775,7 +874,8 @@
 PARROT_WARN_UNUSED_RESULT
 PARROT_CANNOT_RETURN_NULL
 argument *
-new_argument(lexer_state * const lexer, expression * const expr) {
+new_argument(ARGIN(lexer_state * const lexer), expression * const expr)
+{
     argument *arg = pir_mem_allocate_zeroed_typed(lexer, argument);
     arg->value    = expr;
     arg->next     = arg;
@@ -801,7 +901,8 @@
 PARROT_IGNORABLE_RESULT
 PARROT_CANNOT_RETURN_NULL
 argument *
-add_arg(argument *last, argument * const newarg) {
+add_arg(argument *last, argument * const newarg)
+{
     PARROT_ASSERT(last);
     PARROT_ASSERT(newarg);
 
@@ -843,7 +944,8 @@
 PARROT_IGNORABLE_RESULT
 PARROT_CANNOT_RETURN_NULL
 argument *
-unshift_arg(invocation * const inv, argument * const newarg) {
+unshift_arg(invocation * const inv, argument * const newarg)
+{
     ++inv->num_arguments;
 
     if (inv->arguments) {
@@ -869,15 +971,16 @@
 PARROT_IGNORABLE_RESULT
 PARROT_CANNOT_RETURN_NULL
 argument *
-set_arg_flag(argument * const arg, arg_flag flag) {
+set_arg_flag(argument * const arg, arg_flag flag)
+{
     SET_FLAG(arg->flags, flag);
     return arg;
 }
 
 /*
 
-=item C<void
-set_arg_alias(lexer_state * const lexer, char const * const alias)>
+=item C<argument * set_arg_alias(lexer_state * const lexer, char const * const
+alias)>
 
 Set the alias specified in C<alias> on the current argument, accessible
 through C<lexer>. The alias is the name under which the argument is passed
@@ -890,7 +993,8 @@
 PARROT_IGNORABLE_RESULT
 PARROT_CANNOT_RETURN_NULL
 argument *
-set_arg_alias(lexer_state * const lexer, char const * const alias) {
+set_arg_alias(ARGIN(lexer_state * const lexer), char const * const alias)
+{
     PARROT_ASSERT(lexer->curarg != NULL);
     lexer->curarg->alias = alias;
     SET_FLAG(lexer->curarg->flags, ARG_FLAG_NAMED);
@@ -899,8 +1003,8 @@
 
 /*
 
-=item C<void
-load_library(lexer_state * const lexer, char const * const library)>
+=item C<void load_library(lexer_state * const lexer, char const * const
+library)>
 
 Load the library indicated by C<library>.
 
@@ -908,7 +1012,8 @@
 
 */
 void
-load_library(lexer_state * const lexer, char const * const library) {
+load_library(ARGIN(lexer_state * const lexer), char const * const library)
+{
     /* see imcc.y:600 */
     STRING *libname       = Parrot_str_new(lexer->interp, library, strlen(library));
     PMC    *ignored_value = Parrot_load_lib(lexer->interp, libname, NULL);
@@ -919,8 +1024,7 @@
 
 /*
 
-=item C<void
-set_label(lexer_state * const lexer, char const * const label)>
+=item C<void set_label(lexer_state * const lexer, char const * const labelname)>
 
 Set the label C<label> on the current instruction.
 
@@ -928,7 +1032,8 @@
 
 */
 void
-set_label(lexer_state * const lexer, char const * const labelname) {
+set_label(ARGIN(lexer_state * const lexer), char const * const labelname)
+{
     instruction *instr = CURRENT_INSTRUCTION(lexer);
 
     PARROT_ASSERT(instr);
@@ -967,14 +1072,14 @@
 
 */
 void
-set_instr(lexer_state * const lexer, char const * const opname) {
+set_instr(ARGIN(lexer_state * const lexer), char const * const opname)
+{
     set_instrf(lexer, opname, "");
 }
 
 /*
 
-=item C<void
-update_instr(lexer_state * const lexer, char * const newop)>
+=item C<void update_instr(lexer_state * const lexer, char const * const newop)>
 
 Update the current instruction; the new opname is given by C<newop>.
 
@@ -982,7 +1087,8 @@
 
 */
 void
-update_instr(lexer_state * const lexer, char const * const newop) {
+update_instr(ARGIN(lexer_state * const lexer), char const * const newop)
+{
     PARROT_ASSERT(CURRENT_INSTRUCTION(lexer));
     CURRENT_INSTRUCTION(lexer)->opname = newop;
 }
@@ -1063,7 +1169,8 @@
 
 */
 void
-set_instrf(lexer_state * const lexer, char const * const opname, char const * const format, ...) {
+set_instrf(ARGIN(lexer_state * const lexer), char const * const opname, char const * const format, ...)
+{
     va_list  arg_ptr;       /* for the var. args */
     unsigned i;             /* loop iterator */
     size_t   format_length; /* length of the format string. */
@@ -1106,7 +1213,8 @@
 
 */
 void
-add_operands(lexer_state * const lexer, char const * const format, ...) {
+add_operands(ARGIN(lexer_state * const lexer), char const * const format, ...)
+{
     va_list  arg_ptr;       /* for the var. args */
     unsigned i;             /* loop iterator */
     size_t   format_length; /* length of the format string. */
@@ -1143,7 +1251,8 @@
 
 */
 void
-set_op_labelflag(lexer_state * const lexer, int flag) {
+set_op_labelflag(ARGIN(lexer_state * const lexer), int flag)
+{
     PARROT_ASSERT(CURRENT_INSTRUCTION(lexer));
     SET_FLAG(CURRENT_INSTRUCTION(lexer)->oplabelbits, flag);
 }
@@ -1159,8 +1268,10 @@
 
 */
 PARROT_CONST_FUNCTION
+PARROT_CANNOT_RETURN_NULL
 char const *
-get_inverse(char const * const instr) {
+get_inverse(char const * const instr)
+{
          if (STREQ(instr, "if")) return "unless";
     else if (STREQ(instr, "gt")) return "le";
     else if (STREQ(instr, "ge")) return "lt";
@@ -1175,8 +1286,7 @@
 
 /*
 
-=item C<void
-invert_instr(lexer_state *lexer)>
+=item C<void invert_instr(lexer_state * const lexer)>
 
 Invert the current instruction. This function assumes there is an instruction
 already in place.
@@ -1185,7 +1295,8 @@
 
 */
 void
-invert_instr(lexer_state * const lexer) {
+invert_instr(ARGIN(lexer_state * const lexer))
+{
     instruction * const  ins   = CURRENT_INSTRUCTION(lexer);
     char          const *instr;
     PARROT_ASSERT(ins);
@@ -1199,8 +1310,7 @@
 
 /*
 
-=item C<expression *
-get_operand(lexer_state * const lexer, short n)>
+=item C<expression * get_operand(lexer_state * const lexer, short n)>
 
 Get the C<n>th operand from the current instruction. If there are no
 operands, NULL is returned. Because the operands are stored in a
@@ -1216,7 +1326,8 @@
 PARROT_WARN_UNUSED_RESULT
 PARROT_CANNOT_RETURN_NULL
 expression *
-get_operand(lexer_state * const lexer, short n) {
+get_operand(ARGIN(lexer_state * const lexer), short n)
+{
     expression *operand = CURRENT_INSTRUCTION(lexer)->operands;
 
     if (operand == NULL)
@@ -1241,8 +1352,7 @@
 
 /*
 
-=item C<void
-get_operands(lexer_state * const lexer, int bitmask, ...)>
+=item C<void get_operands(lexer_state * const lexer, int bitmask, ...)>
 
 Get operands from the current instruction. C<bitmask> indicates which operands
 are requested; if the C<i>th bit is set, the C<i>th operand is returned in a
@@ -1255,7 +1365,8 @@
 
 */
 void
-get_operands(lexer_state * const lexer, int bitmask, ...) {
+get_operands(ARGIN(lexer_state * const lexer), int bitmask, ...)
+{
     instruction *instr   = CURRENT_INSTRUCTION(lexer);
     expression  *iter    = instr->operands;
     int          numargs;
@@ -1292,8 +1403,7 @@
 
 /*
 
-=item C<int
-get_operand_count(lexer_state * const lexer)>
+=item C<unsigned get_operand_count(lexer_state * const lexer)>
 
 Returns the number of operands of the I<current> instruction.
 This function assumes there is an instruction in place
@@ -1304,7 +1414,8 @@
 */
 PARROT_WARN_UNUSED_RESULT
 unsigned
-get_operand_count(lexer_state * const lexer) {
+get_operand_count(ARGIN(lexer_state * const lexer))
+{
     unsigned count = 0;
     expression *first, *operand;
 
@@ -1329,8 +1440,8 @@
 
 /*
 
-=item C<static constant *
-create_const(lexer_state * const lexer, value_type type, char * const name, va_list arg_ptr)>
+=item C<static constant * create_const(lexer_state * const lexer, value_type
+type, va_list arg_ptr)>
 
 Constant constructor; based on C<type>, retrieve a value of the
 appropriate type from C<arg_ptr>.
@@ -1341,7 +1452,8 @@
 PARROT_WARN_UNUSED_RESULT
 PARROT_CANNOT_RETURN_NULL
 static constant *
-create_const(lexer_state * const lexer, value_type type, va_list arg_ptr) {
+create_const(ARGIN(lexer_state * const lexer), value_type type, va_list arg_ptr)
+{
     constant *c = pir_mem_allocate_zeroed_typed(lexer, constant);
     c->type     = type;
     c->next     = NULL;
@@ -1371,8 +1483,7 @@
 
 /*
 
-=item C<constant *
-new_const(lexer_state * const lexer, value_type type, ...)>
+=item C<constant * new_const(lexer_state * const lexer, value_type type, ...)>
 
 Creates a new constant node of the given type.
 Wrapper function for C<create_const>
@@ -1383,7 +1494,8 @@
 PARROT_WARN_UNUSED_RESULT
 PARROT_CANNOT_RETURN_NULL
 constant *
-new_const(lexer_state * const lexer, value_type type, ...) {
+new_const(ARGIN(lexer_state * const lexer), value_type type, ...)
+{
     constant *c;
     va_list arg_ptr;
     va_start(arg_ptr, type);
@@ -1394,8 +1506,8 @@
 
 /*
 
-=item C<constdecl *
-new_named_const(lexer_state * const lexer, value_type type, char * const name, ...)>
+=item C<constdecl * new_named_const(lexer_state * const lexer, value_type type,
+char const * const name, ...)>
 
 Creates a new constdecl node of the given type, by the given name.
 
@@ -1405,7 +1517,8 @@
 PARROT_WARN_UNUSED_RESULT
 PARROT_CANNOT_RETURN_NULL
 constdecl *
-new_named_const(lexer_state * const lexer, value_type type, char const * const name, ...) {
+new_named_const(ARGIN(lexer_state * const lexer), value_type type, char const * const name, ...)
+{
     constdecl *c = (constdecl *)pir_mem_allocate(lexer, sizeof (constdecl));
     va_list arg_ptr;
     va_start(arg_ptr, name);
@@ -1450,8 +1563,10 @@
 =cut
 
 */
+PARROT_CANNOT_RETURN_NULL
+PARROT_WARN_UNUSED_RESULT
 constdecl *
-new_pmc_const(lexer_state * const lexer, char const * const type,
+new_pmc_const(ARGIN(lexer_state * const lexer), char const * const type,
               char const * const name, constant * const value)
 {
     /* get a STRING representation of the c-string type */
@@ -1607,8 +1722,7 @@
 
 /*
 
-=item C<static invocation *
-new_invocation(lexer_state * const lexer)>
+=item C<static invocation * new_invocation(lexer_state * const lexer)>
 
 Returns a pointer to a new invocation object. In the current implementation,
 there can only be one invocation object at any time. For that reason, the
@@ -1624,7 +1738,8 @@
 PARROT_WARN_UNUSED_RESULT
 PARROT_CANNOT_RETURN_NULL
 static invocation *
-new_invocation(lexer_state * const lexer) {
+new_invocation(ARGIN(lexer_state * const lexer))
+{
     /* optimization: return the address of the cached object */
     invocation *inv = &lexer->obj_cache.inv_cache;
     /* clear all fields */
@@ -1637,8 +1752,7 @@
 
 /*
 
-=item C<static expression *
-new_expr(expr_type type)>
+=item C<static expression * new_expr(lexer_state * const lexer, expr_type type)>
 
 Create a new C<expression> node of the specified C<type>. The new
 expression node is returned.
@@ -1649,7 +1763,8 @@
 PARROT_WARN_UNUSED_RESULT
 PARROT_CANNOT_RETURN_NULL
 static expression *
-new_expr(lexer_state * const lexer, expr_type type) {
+new_expr(ARGIN(lexer_state * const lexer), expr_type type)
+{
     expression *expr = pir_mem_allocate_zeroed_typed(lexer, expression);
     expr->type       = type;
     expr->next       = expr;
@@ -1658,8 +1773,7 @@
 
 /*
 
-=item C<target *
-new_reg(lexer_state * const lexer, int type, int regno)>
+=item C<target * new_reg(lexer_state * const lexer, pir_type type, int regno)>
 
 Create a C<target> node from a register. A new C<pir_reg> object is
 created of type C<type> and PIR register number C<regno>. The target
@@ -1671,7 +1785,8 @@
 PARROT_WARN_UNUSED_RESULT
 PARROT_CANNOT_RETURN_NULL
 target *
-new_reg(lexer_state * const lexer, pir_type type, int regno) {
+new_reg(ARGIN(lexer_state * const lexer), pir_type type, int regno)
+{
     target  *t = new_target(lexer);
     pir_reg *reg;
 
@@ -1687,8 +1802,8 @@
 
 /*
 
-=item C<expression *
-expr_from_target(target *t)>
+=item C<expression * expr_from_target(lexer_state * const lexer, target * const
+t)>
 
 Wrap a target in an expression node; the expression node is
 returned.
@@ -1699,7 +1814,8 @@
 PARROT_WARN_UNUSED_RESULT
 PARROT_CANNOT_RETURN_NULL
 expression *
-expr_from_target(lexer_state * const lexer, target * const t) {
+expr_from_target(ARGIN(lexer_state * const lexer), target * const t)
+{
     expression *e = new_expr(lexer, EXPR_TARGET);
     e->expr.t     = t;
     return e;
@@ -1707,8 +1823,8 @@
 
 /*
 
-=item C<expression *
-expr_from_const(constant * const c)>
+=item C<expression * expr_from_const(lexer_state * const lexer, constant * const
+c)>
 
 Convert the constant C<c> to an expression node and returns the newly
 created expression node.
@@ -1719,7 +1835,8 @@
 PARROT_WARN_UNUSED_RESULT
 PARROT_CANNOT_RETURN_NULL
 expression *
-expr_from_const(lexer_state * const lexer, constant * const c) {
+expr_from_const(ARGIN(lexer_state * const lexer), constant * const c)
+{
     expression *e = new_expr(lexer, EXPR_CONSTANT);
     e->expr.c     = c;
     return e;
@@ -1740,7 +1857,8 @@
 PARROT_WARN_UNUSED_RESULT
 PARROT_CANNOT_RETURN_NULL
 expression *
-expr_from_int(lexer_state * const lexer, int ival) {
+expr_from_int(ARGIN(lexer_state * const lexer), int ival)
+{
     return expr_from_const(lexer, new_const(lexer, INT_VAL, ival));
 }
 
@@ -1757,7 +1875,8 @@
 PARROT_WARN_UNUSED_RESULT
 PARROT_CANNOT_RETURN_NULL
 expression *
-expr_from_num(lexer_state * const lexer, double nval) {
+expr_from_num(ARGIN(lexer_state * const lexer), double nval)
+{
     return expr_from_const(lexer, new_const(lexer, NUM_VAL, nval));
 }
 
@@ -1774,15 +1893,16 @@
 PARROT_WARN_UNUSED_RESULT
 PARROT_CANNOT_RETURN_NULL
 expression *
-expr_from_string(lexer_state * const lexer, char const * const sval) {
+expr_from_string(ARGIN(lexer_state * const lexer), char const * const sval)
+{
     return expr_from_const(lexer, new_const(lexer, STRING_VAL, sval));
 }
 
 
 /*
 
-=item C<expression *
-expr_from_ident(char * const id)>
+=item C<expression * expr_from_ident(lexer_state * const lexer, char const *
+const id)>
 
 Convert a ident to an expression node and returns it.
 
@@ -1792,7 +1912,8 @@
 PARROT_WARN_UNUSED_RESULT
 PARROT_CANNOT_RETURN_NULL
 expression *
-expr_from_ident(lexer_state * const lexer, char const * const id) {
+expr_from_ident(ARGIN(lexer_state * const lexer), char const * const id)
+{
     expression *e = new_expr(lexer, EXPR_IDENT);
     e->expr.id    = id;
     return e;
@@ -1800,8 +1921,8 @@
 
 /*
 
-=item C<void
-set_invocation_args(lexer_state * const lexer, invocation * const inv, argument * const args)>
+=item C<invocation * set_invocation_args(lexer_state * const lexer, invocation *
+const inv, argument * const args)>
 
 Set the args of an invocation onto the current invocation object.
 The number of arguments in the list is counted, and stored in the
@@ -1810,8 +1931,11 @@
 =cut
 
 */
+PARROT_CANNOT_RETURN_NULL
+PARROT_WARN_UNUSED_RESULT
 invocation *
-set_invocation_args(lexer_state * const lexer, invocation * const inv, argument * const args) {
+set_invocation_args(ARGIN(lexer_state * const lexer), invocation * const inv, argument * const args)
+{
     argument *arg_iter;
     unsigned  arg_count = 0;
 
@@ -1850,8 +1974,8 @@
 
 /*
 
-=item C<void
-set_invocation_results(lexer_state * const lexer, invocation * const inv, target * const results)>
+=item C<invocation * set_invocation_results(lexer_state * const lexer,
+invocation * const inv, target * const results)>
 
 Set the invocation results on the invocation object C<inv>.
 The number of results is stored in the invocation object.
@@ -1860,8 +1984,11 @@
 =cut
 
 */
+PARROT_CANNOT_RETURN_NULL
+PARROT_WARN_UNUSED_RESULT
 invocation *
-set_invocation_results(lexer_state * const lexer, invocation * const inv, target * const results) {
+set_invocation_results(ARGIN(lexer_state * const lexer), invocation * const inv, target * const results)
+{
     target  *result_iter;
     unsigned result_count = 0;
 
@@ -1895,16 +2022,19 @@
 
 /*
 
-=item C<void
-set_invocation_type(invocation * const inv, invoke_type type)>
+=item C<invocation * set_invocation_type(invocation * const inv, invoke_type
+type)>
 
 Set the invocation type on the invocation object C<inv>.
 
 =cut
 
 */
+PARROT_CANNOT_RETURN_NULL
+PARROT_WARN_UNUSED_RESULT
 invocation *
-set_invocation_type(invocation * const inv, invoke_type type) {
+set_invocation_type(invocation * const inv, invoke_type type)
+{
     inv->type = type;
     return inv;
 }
@@ -1926,7 +2056,8 @@
 PARROT_WARN_UNUSED_RESULT
 PARROT_CANNOT_RETURN_NULL
 invocation *
-invoke(lexer_state * const lexer, invoke_type type, ...) {
+invoke(ARGIN(lexer_state * const lexer), invoke_type type, ...)
+{
     va_list arg_ptr;
 
     invocation *inv = new_invocation(lexer);
@@ -1966,8 +2097,8 @@
 
 /*
 
-=item C<void
-set_lex_flag(lexer_state * const lexer, target * const t, char const * const name)>
+=item C<void set_lex_flag(lexer_state * const lexer, target * const t, char
+const * const name)>
 
 Store target C<t> as a lexical in the sub_info struct. The lexical node
 stores a pointer to the target's syminfo structure, so it can access
@@ -1977,7 +2108,8 @@
 
 */
 void
-set_lex_flag(lexer_state * const lexer, target * const t, char const * const name) {
+set_lex_flag(ARGIN(lexer_state * const lexer), target * const t, char const * const name)
+{
     lexical *lex = CURRENT_SUB(lexer)->info.lexicals;
 
     /* check whether there is already a target marked as .lex with the specified name */
@@ -2005,8 +2137,7 @@
 
 /*
 
-=item C<void
-set_hll(lexer_state * const lexer, char * const hll)>
+=item C<void set_hll(lexer_state * const lexer, char const * const hll)>
 
 Set the current HLL as specified in C<hll>.
 
@@ -2016,7 +2147,8 @@
 
 */
 void
-set_hll(lexer_state * const lexer, char const * const hll) {
+set_hll(ARGIN(lexer_state * const lexer), char const * const hll)
+{
     STRING * const hll_name             = Parrot_str_new(lexer->interp, hll, strlen(hll));
     CONTEXT(lexer->interp)->current_HLL = Parrot_register_HLL(lexer->interp, hll_name);
 }
@@ -2025,8 +2157,8 @@
 
 /*
 
-=item C<void
-unshift_operand(lexer_state *lexer, expression *operand)>
+=item C<void unshift_operand(lexer_state * const lexer, expression * const
+operand)>
 
 Add the specified expression as the first operand of the current
 instruction.
@@ -2035,7 +2167,8 @@
 
 */
 void
-unshift_operand(lexer_state * const lexer, expression * const operand) {
+unshift_operand(ARGIN(lexer_state * const lexer), expression * const operand)
+{
     expression *last = CURRENT_INSTRUCTION(lexer)->operands;
     if (last) {
         /* get the head of the list */
@@ -2060,7 +2193,8 @@
 
 */
 void
-push_operand(lexer_state * const lexer, NOTNULL(expression * const operand)) {
+push_operand(ARGIN(lexer_state * const lexer), NOTNULL(expression * const operand))
+{
     PARROT_ASSERT(CURRENT_INSTRUCTION(lexer));
 
     if (CURRENT_INSTRUCTION(lexer)->operands) {
@@ -2072,8 +2206,7 @@
 
 /*
 
-=item C<void
-remove_all_operands(lexer_state * const lexer)>
+=item C<void remove_all_operands(lexer_state * const lexer)>
 
 Remove all operands of the current instruction. This is done
 by simply setting the pointer to the operands to NULL; all
@@ -2084,15 +2217,15 @@
 
 */
 void
-remove_all_operands(NOTNULL(lexer_state * const lexer)) {
+remove_all_operands(ARGIN(lexer_state * const lexer))
+{
     CURRENT_INSTRUCTION(lexer)->operands = NULL;
 }
 
 
 /*
 
-=item C<expression *
-expr_from_key(lexer_state * const lexer, key * const k)>
+=item C<expression * expr_from_key(lexer_state * const lexer, key * const k)>
 
 Wraps the key C<k> in an C<expression> node and returns that.
 The returned expression node has type EXPR_KEY.
@@ -2100,8 +2233,11 @@
 =cut
 
 */
+PARROT_CANNOT_RETURN_NULL
+PARROT_WARN_UNUSED_RESULT
 expression *
-expr_from_key(NOTNULL(lexer_state * const lexer), NOTNULL(key * const k)) {
+expr_from_key(ARGIN(lexer_state * const lexer), NOTNULL(key * const k))
+{
     expression *e = new_expr(lexer, EXPR_KEY);
     e->expr.k     = k;
     return e;
@@ -2110,7 +2246,8 @@
 
 /*
 
-=item C<static key_entry * new_key_entry>
+=item C<static key_entry * new_key_entry(lexer_state * const lexer, expression *
+const expr)>
 
 Constructor for a key_entry node. Memory is allocated for the node,
 and the C<expr> field is initialized to the passed in C<expr> value.
@@ -2119,8 +2256,11 @@
 =cut
 
 */
+PARROT_CANNOT_RETURN_NULL
+PARROT_WARN_UNUSED_RESULT
 static key_entry *
-new_key_entry(lexer_state * const lexer, expression * const expr) {
+new_key_entry(ARGIN(lexer_state * const lexer), ARGIN(expression * const expr))
+{
     key_entry *entry = pir_mem_allocate_zeroed_typed(lexer, key_entry);
     entry->expr      = expr;
     entry->next      = NULL;
@@ -2128,8 +2268,7 @@
 }
 /*
 
-=item C<key *
-new_key(lexer_state * const lexer, expression * const expr)>
+=item C<key * new_key(lexer_state * const lexer, expression * const expr)>
 
 Wraps the expression C<expr> in a key node and returns that.
 
@@ -2139,7 +2278,8 @@
 PARROT_WARN_UNUSED_RESULT
 PARROT_CANNOT_RETURN_NULL
 key *
-new_key(NOTNULL(lexer_state * const lexer), NOTNULL(expression * const expr)) {
+new_key(ARGIN(lexer_state * const lexer), NOTNULL(expression * const expr))
+{
     key *k       = pir_mem_allocate_zeroed_typed(lexer, key);
     k->head      = new_key_entry(lexer, expr);
     k->keylength = 1;
@@ -2161,7 +2301,7 @@
 PARROT_WARN_UNUSED_RESULT
 PARROT_CANNOT_RETURN_NULL
 key *
-add_key(NOTNULL(lexer_state * const lexer), NOTNULL(key * const keylist),
+add_key(ARGIN(lexer_state * const lexer), NOTNULL(key * const keylist),
         NOTNULL(expression * const exprkey))
 {
     key_entry *newkey = new_key_entry(lexer, exprkey);
@@ -2183,8 +2323,7 @@
 
 /*
 
-=item C<symbol *
-add_local(symbol * const list, symbol * const local)>
+=item C<symbol * add_local(symbol * const list, symbol * const local)>
 
 Add local C<local> to the list pointed to by C<list>. The new object
 is inserted at the front of the list. C<list> is returned
@@ -2195,7 +2334,8 @@
 PARROT_WARN_UNUSED_RESULT
 PARROT_CANNOT_RETURN_NULL
 symbol *
-add_local(symbol * const list, symbol * const local) {
+add_local(symbol * const list, symbol * const local)
+{
     local->next = list->next;
     list->next  = local;
     return list;
@@ -2217,7 +2357,7 @@
 PARROT_WARN_UNUSED_RESULT
 PARROT_CANNOT_RETURN_NULL
 symbol *
-new_local(lexer_state * const lexer, char const * const name, int has_unique_reg){
+new_local(ARGIN(lexer_state * const lexer), char const * const name, int has_unique_reg){
     symbol *s = new_symbol(lexer, name, UNKNOWN_TYPE);
 
     if (has_unique_reg)
@@ -2229,8 +2369,7 @@
 
 /*
 
-=item C<int
-is_parrot_op(lexer_state * const lexer, char * const name)>
+=item C<int is_parrot_op(lexer_state * const lexer, char const * const name)>
 
 Check whether C<name> is a parrot opcode. C<name> can be either the short
 or fullname of the opcode; for instance, C<print> is the short name, which
@@ -2241,7 +2380,8 @@
 
 */
 int
-is_parrot_op(lexer_state * const lexer, char const * const name) {
+is_parrot_op(ARGIN(lexer_state * const lexer), char const * const name)
+{
     int opcode = lexer->interp->op_lib->op_code(name, 0); /* check short name, e.g. "set" */
 
     /* do *NOT* check for the "long" name variant, such as "set_i_ic";
@@ -2271,7 +2411,7 @@
 
 */
 void
-new_sub_instr(lexer_state * const lexer, int opcode, char const * const opname,
+new_sub_instr(ARGIN(lexer_state * const lexer), int opcode, char const * const opname,
               unsigned num_var_args)
 
 {
@@ -2294,8 +2434,8 @@
 
 /*
 
-=item C<void
-update_op(lexer_state * const lexer, instruction * const instr, int newop)>
+=item C<void update_op(lexer_state * const lexer, instruction * const instr, int
+newop)>
 
 Update the instruction C<instr>; it is replaced by the op with opcode C<newop>.
 The C<opinfo>, C<opname> and C<opcode> fields of C<instr> are updated.
@@ -2304,7 +2444,8 @@
 
 */
 void
-update_op(NOTNULL(lexer_state * const lexer), NOTNULL(instruction * const instr), int newop) {
+update_op(ARGIN(lexer_state * const lexer), NOTNULL(instruction * const instr), int newop)
+{
     /* Deduct number of ints needed for the old instruction, if there is one.
      * This is necessary during strength reduction and other optimizations, once
      * the opinfo is retrieved, we also update the codesize field in the lexer.
@@ -2329,8 +2470,8 @@
 
 /*
 
-=item C<static label *
-new_label(lexer_state * const lexer, char const * const labelid, int offset)>
+=item C<static label * new_label(lexer_state * const lexer, char const * const
+labelid, int offset)>
 
 Constructor for a label struct node. A new C<label> object is created,
 initialized with the label id specified in C<labelid>, and the bytecode
@@ -2340,8 +2481,12 @@
 
 */
 PARROT_MALLOC
+PARROT_CANNOT_RETURN_NULL
+PARROT_WARN_UNUSED_RESULT
 static label *
-new_label(lexer_state * const lexer, char const * const labelid, int offset) {
+new_label(ARGIN(lexer_state * const lexer),
+        ARGIN(char const * const labelid), int offset)
+{
     label *l  = pir_mem_allocate_zeroed_typed(lexer, label);
     l->name   = labelid;
     l->offset = offset;
@@ -2350,8 +2495,7 @@
 
 /*
 
-=item C<static void
-fixup_local_labels(subroutine * const sub)>
+=item C<static void fixup_local_labels(lexer_state * const lexer)>
 
 Fix up all local labels in the subroutine C<sub>. Labels are stored as
 identifiers in an expression node (the C<id> field in the C<expr> union);
@@ -2363,7 +2507,8 @@
 
 */
 static void
-fixup_local_labels(lexer_state * const lexer) {
+fixup_local_labels(ARGIN(lexer_state * const lexer))
+{
     instruction *iter = CURRENT_SUB(lexer)->statements;
 
     /* if there's no instruction in the current sub, then do nothing. */
@@ -2421,8 +2566,7 @@
 
 /*
 
-=item C<void
-fixup_global_labels(lexer_state * const lexer)>
+=item C<void fixup_global_labels(lexer_state * const lexer)>
 
 Fix references to global labels. The lexer keeps a list of instructions that
 can be patched. These instructions currently look up the global label during
@@ -2435,7 +2579,8 @@
 
 */
 void
-fixup_global_labels(lexer_state * const lexer) {
+fixup_global_labels(ARGIN(lexer_state * const lexer))
+{
     global_fixup *iter = lexer->global_refs;
 
     while (iter) {
@@ -2475,8 +2620,7 @@
 
 /*
 
-=item C<void
-close_sub(lexer_state * const lexer)>
+=item C<void close_sub(lexer_state * const lexer)>
 
 Finalize the subroutine. Generate the final instructions in the current
 subroutine, if needed. Then, all local labels are fixed up; i.e., all
@@ -2488,7 +2632,8 @@
 
 */
 void
-close_sub(lexer_state * const lexer) {
+close_sub(ARGIN(lexer_state * const lexer))
+{
     int           need_epilogue = 1;
     int           sub_const_table_index;
     global_label *glob;
@@ -2547,8 +2692,8 @@
 
 /*
 
-=item C<void
-update_sub_register_usage(lexer_state * const lexer, unsigned reg_usage[NUM_PARROT_TYPES])>
+=item C<void update_sub_register_usage(lexer_state * const lexer, unsigned
+reg_usage[NUM_PARROT_TYPES])>
 
 Update register usage for the current subroutine with the register usage
 information in C<reg_usage>.
@@ -2557,7 +2702,8 @@
 
 */
 void
-update_sub_register_usage(lexer_state * const lexer, unsigned reg_usage[NUM_PARROT_TYPES]) {
+update_sub_register_usage(ARGIN(lexer_state * const lexer), unsigned reg_usage[NUM_PARROT_TYPES])
+{
     int i;
     for (i = 0; i < NUM_PARROT_TYPES; ++i)
         CURRENT_SUB(lexer)->info.regs_used[i] = reg_usage[i];
@@ -2566,8 +2712,8 @@
 
 /*
 
-=item C<void
-annotate(lexer_state * const lexer, char const * const key, constant * const value)>
+=item C<void annotate(lexer_state * const lexer, char const * const key,
+constant * const value)>
 
 Add a new annotation with key C<key> and value C<value>.
 
@@ -2575,7 +2721,8 @@
 
 */
 void
-annotate(lexer_state * const lexer, char const * const key, constant * const value) {
+annotate(ARGIN(lexer_state * const lexer), char const * const key, constant * const value)
+{
     annotation *ann     = (annotation *)pir_mem_allocate(lexer, sizeof (annotation));
     ann->key            = key;
     ann->value          = value;


More information about the parrot-commits mailing list