[svn:parrot] r43086 - branches/pmc_freeze_cleanup/src
darbelo at svn.parrot.org
darbelo at svn.parrot.org
Wed Dec 16 05:38:43 UTC 2009
Author: darbelo
Date: Wed Dec 16 05:38:42 2009
New Revision: 43086
URL: https://trac.parrot.org/parrot/changeset/43086
Log:
Add _NULLOK() to an ARGIN macro and add a cast to pacify the compiler.
Modified:
branches/pmc_freeze_cleanup/src/pmc_freeze.c
Modified: branches/pmc_freeze_cleanup/src/pmc_freeze.c
==============================================================================
--- branches/pmc_freeze_cleanup/src/pmc_freeze.c Wed Dec 16 05:20:58 2009 (r43085)
+++ branches/pmc_freeze_cleanup/src/pmc_freeze.c Wed Dec 16 05:38:42 2009 (r43086)
@@ -147,10 +147,9 @@
static void todo_list_init(PARROT_INTERP,
ARGOUT(visit_info *info),
- ARGIN(STRING *input))
+ ARGIN_NULLOK(STRING *input))
__attribute__nonnull__(1)
__attribute__nonnull__(2)
- __attribute__nonnull__(3)
FUNC_MODIFIES(*info);
PARROT_INLINE
@@ -235,8 +234,7 @@
, PARROT_ASSERT_ARG(type))
#define ASSERT_ARGS_todo_list_init __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
PARROT_ASSERT_ARG(interp) \
- , PARROT_ASSERT_ARG(info) \
- , PARROT_ASSERT_ARG(input))
+ , PARROT_ASSERT_ARG(info))
#define ASSERT_ARGS_todo_list_seen __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
PARROT_ASSERT_ARG(interp) \
, PARROT_ASSERT_ARG(pmc) \
@@ -577,8 +575,9 @@
*/
static void
-todo_list_init(PARROT_INTERP, ARGOUT(visit_info *info), ARGIN(STRING *input))
+todo_list_init(PARROT_INTERP, ARGOUT(visit_info *info), ARGIN_NULLOK(STRING *input))
{
+ ASSERT_ARGS(todo_list_init)
/* We want to store a 16-byte aligned header, but the actual
* header may be shorter. */
const unsigned int header_length = PACKFILE_HEADER_BYTES +
@@ -620,7 +619,7 @@
info->buffer = (Buffer *)input;
PARROT_ASSERT(input->_bufstart == input->strstart);
- info->pos = Buffer_bufstart(info->buffer);
+ info->pos = (char *) Buffer_bufstart(info->buffer);
info->input_length = input->strlen;
mem_sys_memcopy(pf->header, info->pos, PACKFILE_HEADER_BYTES);
More information about the parrot-commits
mailing list