Here's a big patch that adds newlines to all internal_exception calls
for which they were missing.
Luke
Index: classes/delegate.pmc
===================================================================
RCS file: /cvs/public/parrot/classes/delegate.pmc,v
retrieving revision 1.8
diff -u -r1.8 delegate.pmc
--- classes/delegate.pmc 15 Dec 2003 17:17:58 -0000 1.8
+++ classes/delegate.pmc 24 Dec 2003 19:35:17 -0000
@@ -37,7 +37,7 @@
struct regsave *save;
save = mem_sys_allocate(sizeof(struct regsave));
if (!save) {
- internal_exception(ALLOCATION_ERROR, "No memory for save struct");
+ internal_exception(ALLOCATION_ERROR, "No memory for save struct\n");
}
mem_sys_memcopy(save, interp, sizeof(struct regsave));
return save;
@@ -62,7 +62,7 @@
PMC *returnPMC = find_meth(interp, pmc, name);
if (PMC_IS_NULL(returnPMC)) {
internal_exception(METH_NOT_FOUND,
- "Can't find method '%s' for object", name);
+ "Can't find method '%s' for object\n", name);
}
return returnPMC;
}
Index: classes/key.pmc
===================================================================
RCS file: /cvs/public/parrot/classes/key.pmc,v
retrieving revision 1.15
diff -u -r1.15 key.pmc
--- classes/key.pmc 19 Dec 2003 10:01:36 -0000 1.15
+++ classes/key.pmc 24 Dec 2003 19:35:17 -0000
@@ -121,7 +121,7 @@
ret->cache.int_val = -1;
break;
default:
- internal_exception(1, "Key can't iterate backwards");
+ internal_exception(1, "Key can't iterate backwards\n");
break;
}
return ret;
Index: classes/parrotobject.pmc
===================================================================
RCS file: /cvs/public/parrot/classes/parrotobject.pmc,v
retrieving revision 1.14
diff -u -r1.14 parrotobject.pmc
--- classes/parrotobject.pmc 5 Dec 2003 16:40:55 -0000 1.14
+++ classes/parrotobject.pmc 24 Dec 2003 19:35:17 -0000
@@ -82,7 +82,7 @@
POD_CLASS);
INTVAL idx = VTABLE_get_integer_keyed_str(interpreter, class, attr);
if (idx < 0)
- internal_exception(1, "No such attribute");
+ internal_exception(1, "No such attribute\n");
return SELF.get_integer_keyed_int(idx);
}
@@ -102,7 +102,7 @@
POD_CLASS);
INTVAL idx = VTABLE_get_integer_keyed_str(interpreter, class, attr);
if (idx < 0)
- internal_exception(1, "No such attribute");
+ internal_exception(1, "No such attribute\n");
SELF.set_integer_keyed_int(idx, value);
}
Index: classes/scratchpad.pmc
===================================================================
RCS file: /cvs/public/parrot/classes/scratchpad.pmc,v
retrieving revision 1.15
diff -u -r1.15 scratchpad.pmc
--- classes/scratchpad.pmc 19 Dec 2003 10:01:36 -0000 1.15
+++ classes/scratchpad.pmc 24 Dec 2003 19:35:17 -0000
@@ -76,7 +76,7 @@
name = key_string(INTERP, name_key);
}
else {
- internal_exception(-1, "Invalid key");
+ internal_exception(-1, "Invalid key\n");
}
if (key2) {
@@ -84,7 +84,7 @@
pad_index = key_integer(INTERP, key);
}
else {
- internal_exception(-1, "Invalid key");
+ internal_exception(-1, "Invalid key\n");
}
ret = scratchpad_get_index(INTERP, SELF, pad_index,
name, position);
@@ -113,7 +113,7 @@
name = key_string(INTERP, name_key);
}
else {
- internal_exception(-1, "Invalid key");
+ internal_exception(-1, "Invalid key\n");
}
if (key2) {
@@ -121,7 +121,7 @@
pad_index = key_integer(INTERP, key);
}
else {
- internal_exception(-1, "Invalid key");
+ internal_exception(-1, "Invalid key\n");
}
scratchpad_store_index(INTERP, SELF, pad_index, name,
position, value);
Index: classes/unmanagedstruct.pmc
===================================================================
RCS file: /cvs/public/parrot/classes/unmanagedstruct.pmc,v
retrieving revision 1.22
diff -u -r1.22 unmanagedstruct.pmc
--- classes/unmanagedstruct.pmc 4 Nov 2003 18:35:05 -0000 1.22
+++ classes/unmanagedstruct.pmc 24 Dec 2003 19:35:18 -0000
@@ -26,7 +26,7 @@
ix *= 3;
n = (size_t)VTABLE_elements(interpreter, PMC_ptr2p(pmc));
if ((size_t)ix >= n)
- internal_exception(1, "Non existent elements in struct");
+ internal_exception(1, "Non existent elements in struct\n");
/* use structure init */
*type = (int) VTABLE_get_integer_keyed_int(interpreter, PMC_ptr2p(pmc), ix);
offs = (size_t) VTABLE_get_integer_keyed_int(interpreter, PMC_ptr2p(pmc), ix + 2);
@@ -49,7 +49,7 @@
count = (size_t) key_integer(interpreter, next);
max = (size_t) VTABLE_get_integer_keyed_int(interpreter, PMC_ptr2p(pmc), ix + 1);
if (count >= max)
- internal_exception(1, "Non existent array element in struct");
+ internal_exception(1, "Non existent array element in struct\n");
size = data_types[*type - enum_first_type].size;
return p + count * size;
}
@@ -67,7 +67,7 @@
case enum_type_uchar:
return *p;
default:
- internal_exception(1, "unhandled type in struct");
+ internal_exception(1, "unhandled type in struct\n");
}
return -1;
}
@@ -83,7 +83,7 @@
case enum_type_double:
return (FLOATVAL) *(double*) p;
default:
- internal_exception(1, "unhandled type in struct");
+ internal_exception(1, "unhandled type in struct\n");
}
return -1.0;
}
@@ -106,7 +106,7 @@
*(short*)p = (short)value;
break;
default:
- internal_exception(1, "unhandled type in struct");
+ internal_exception(1, "unhandled type in struct\n");
break;
}
}
@@ -149,7 +149,7 @@
size_t toff = 0;
if (n % 3)
- internal_exception(1, "Illegal initializer for struct");
+ internal_exception(1, "Illegal initializer for struct\n");
PMC_ptr2p(SELF) = value;
for (i = 0; i < n; i += 3) {
@@ -158,7 +158,7 @@
int offs = (int) VTABLE_get_integer_keyed_int(interpreter, value, i+2);
if (type < enum_first_type || type >= enum_last_type)
- internal_exception(1, "Illegal type in initializer for struct");
+ internal_exception(1, "Illegal type in initializer for struct\n");
if (count <= 0) {
count = 1;
VTABLE_set_integer_keyed_int(interpreter, value, i+1, count);
Index: lib/Parrot/Pmc2c.pm
===================================================================
RCS file: /cvs/public/parrot/lib/Parrot/Pmc2c.pm,v
retrieving revision 1.9
diff -u -r1.9 Pmc2c.pm
--- lib/Parrot/Pmc2c.pm 18 Dec 2003 14:51:23 -0000 1.9
+++ lib/Parrot/Pmc2c.pm 24 Dec 2003 19:35:19 -0000
@@ -614,7 +614,7 @@
$l
${decl} {
internal_exception(NULL_REG_ACCESS,
- "Null PMC access in $meth()");
+ "Null PMC access in $meth()\\n");
$ret
}
Index: ops/object.ops
===================================================================
RCS file: /cvs/public/parrot/ops/object.ops,v
retrieving revision 1.22
diff -u -r1.22 object.ops
--- ops/object.ops 12 Dec 2003 08:00:13 -0000 1.22
+++ ops/object.ops 24 Dec 2003 19:35:19 -0000
@@ -153,7 +153,7 @@
PMC *class = VTABLE_get_pmc_keyed_str(interpreter,
interpreter->class_hash, $2);
if (!class) {
- internal_exception(NO_CLASS, "Class doesn't exist");
+ internal_exception(NO_CLASS, "Class doesn't exist\n");
}
$1 = Parrot_single_subclass(interpreter, class, $3);
goto NEXT();
@@ -163,7 +163,7 @@
PMC *class = VTABLE_get_pmc_keyed_str(interpreter,
interpreter->class_hash, $2);
if (!class) {
- internal_exception(NO_CLASS, "Class doesn't exist");
+ internal_exception(NO_CLASS, "Class doesn't exist\n");
}
$1 = Parrot_single_subclass(interpreter, class, NULL);
goto NEXT();
@@ -194,7 +194,7 @@
if (VTABLE_exists_keyed_str(interpreter, interpreter->class_hash, $2)) {
$1 = VTABLE_get_pmc_keyed_str(interpreter, interpreter->class_hash, $2);
} else {
- internal_exception(NO_CLASS, "Class doesn't exist");
+ internal_exception(NO_CLASS, "Class doesn't exist\n");
}
goto NEXT();
}
@@ -240,7 +240,7 @@
$1 = VTABLE_get_string(interpreter, classname_pmc);
}
else {
- internal_exception(NO_CLASS, "Class doesn't exist");
+ internal_exception(NO_CLASS, "Class doesn't exist\n");
}
goto NEXT();
@@ -274,7 +274,7 @@
op addattrib(out INT, in PMC, in STR) {
if (!PObj_is_class_TEST($2))
- internal_exception(1, "PMC is not a class");
+ internal_exception(1, "PMC is not a class\n");
$1 = Parrot_add_attribute(interpreter, $2, $3);
goto NEXT();
}
Index: ops/var.ops
===================================================================
RCS file: /cvs/public/parrot/ops/var.ops,v
retrieving revision 1.11
diff -u -r1.11 var.ops
--- ops/var.ops 3 Dec 2003 14:43:15 -0000 1.11
+++ ops/var.ops 24 Dec 2003 19:35:19 -0000
@@ -169,7 +169,7 @@
op find_lex(out PMC, in STR) {
opcode_t * resume;
if (!$2)
- internal_exception(1, "Tried to get null lexical.");
+ internal_exception(1, "Tried to get null lexical.\n");
$1 = scratchpad_get(interpreter, scratchpad_get_current(interpreter), $2, 0);
resume = expr NEXT();
if (!$1)
@@ -191,7 +191,7 @@
op find_lex(out PMC, in INT, in STR) {
opcode_t * resume;
if (!$3)
- internal_exception(1, "Tried to get null lexical.");
+ internal_exception(1, "Tried to get null lexical.\n");
$1 = scratchpad_get_index(interpreter, scratchpad_get_current(interpreter),
$2, $3, 0);
resume = expr NEXT();
@@ -253,7 +253,7 @@
opcode_t * resume;
PMC * globals = interpreter->globals->stash_hash;
if (!$2)
- internal_exception(1, "Tried to get null global.");
+ internal_exception(1, "Tried to get null global.\n");
resume = expr NEXT();
if (!VTABLE_exists_keyed_str(interpreter, globals, $2))
Index: src/events.c
===================================================================
RCS file: /cvs/public/parrot/src/events.c,v
retrieving revision 1.15
diff -u -r1.15 events.c
--- src/events.c 23 Dec 2003 09:57:37 -0000 1.15
+++ src/events.c 24 Dec 2003 19:35:19 -0000
@@ -228,7 +228,7 @@
}
else {
/* we shouldn't get here probably */
- internal_exception(1, "Spurious event is event queue");
+ internal_exception(1, "Spurious event is event queue\n");
}
/*
* one or more entries arrived - we hold the mutex again
@@ -263,7 +263,7 @@
}
break;
default:
- internal_exception(1, "Unknown queue entry");
+ internal_exception(1, "Unknown queue entry\n");
}
/*
* TODO check for a stop event to do cleanup
Index: src/hash.c
===================================================================
RCS file: /cvs/public/parrot/src/hash.c,v
retrieving revision 1.66
diff -u -r1.66 hash.c
--- src/hash.c 19 Dec 2003 10:01:42 -0000 1.66
+++ src/hash.c 24 Dec 2003 19:35:19 -0000
@@ -213,7 +213,7 @@
}
return key;
default:
- internal_exception(1, "Illegal key_type");
+ internal_exception(1, "Illegal key_type\n");
}
return key;
}
Index: src/interpreter.c
===================================================================
RCS file: /cvs/public/parrot/src/interpreter.c,v
retrieving revision 1.246
diff -u -r1.246 interpreter.c
--- src/interpreter.c 22 Dec 2003 15:32:02 -0000 1.246
+++ src/interpreter.c 24 Dec 2003 19:35:19 -0000
@@ -74,26 +74,26 @@
case PARROT_ARG_KI:
case PARROT_ARG_I:
if (arg < 0 || arg >= NUM_REGISTERS)
- internal_exception(INTERP_ERROR, "Illegal register number");
+ internal_exception(INTERP_ERROR, "Illegal register number\n");
pc_prederef[i] = (void *)&interpreter->int_reg.registers[arg];
break;
case PARROT_ARG_N:
if (arg < 0 || arg >= NUM_REGISTERS)
- internal_exception(INTERP_ERROR, "Illegal register number");
+ internal_exception(INTERP_ERROR, "Illegal register number\n");
pc_prederef[i] = (void *)&interpreter->num_reg.registers[arg];
break;
case PARROT_ARG_K:
case PARROT_ARG_P:
if (arg < 0 || arg >= NUM_REGISTERS)
- internal_exception(INTERP_ERROR, "Illegal register number");
+ internal_exception(INTERP_ERROR, "Illegal register number\n");
pc_prederef[i] = (void *)&interpreter->pmc_reg.registers[arg];
break;
case PARROT_ARG_S:
if (arg < 0 || arg >= NUM_REGISTERS)
- internal_exception(INTERP_ERROR, "Illegal register number");
+ internal_exception(INTERP_ERROR, "Illegal register number\n");
pc_prederef[i] = (void *)&interpreter->string_reg.registers[arg];
break;
@@ -104,13 +104,13 @@
case PARROT_ARG_NC:
if (arg < 0 || arg >= const_table->const_count)
- internal_exception(INTERP_ERROR, "Illegal constant number");
+ internal_exception(INTERP_ERROR, "Illegal constant number\n");
pc_prederef[i] = (void *) &const_table->constants[arg]->u.number;
break;
case PARROT_ARG_PC:
if (arg < 0 || arg >= const_table->const_count)
- internal_exception(INTERP_ERROR, "Illegal constant number");
+ internal_exception(INTERP_ERROR, "Illegal constant number\n");
/* pc_prederef[i] = (void *)
&const_table->constants[arg]->pmc; */
internal_exception(ARG_OP_NOT_HANDLED,
@@ -119,14 +119,14 @@
case PARROT_ARG_SC:
if (arg < 0 || arg >= const_table->const_count)
- internal_exception(INTERP_ERROR, "Illegal constant number");
+ internal_exception(INTERP_ERROR, "Illegal constant number\n");
pc_prederef[i] = (void *)
&const_table->constants[arg]->u.string;
break;
case PARROT_ARG_KC:
if (arg < 0 || arg >= const_table->const_count)
- internal_exception(INTERP_ERROR, "Illegal constant number");
+ internal_exception(INTERP_ERROR, "Illegal constant number\n");
pc_prederef[i] = (void *)
&const_table->constants[arg]->u.key;
break;
@@ -155,7 +155,7 @@
op_func_t *prederef_op_func = interpreter->op_lib->op_func_table;
if (*pc < 0 || *pc >= (opcode_t)interpreter->op_count)
- internal_exception(INTERP_ERROR, "Illegal opcode");
+ internal_exception(INTERP_ERROR, "Illegal opcode\n");
switch (type) {
case PARROT_SWITCH_CORE:
*pc_prederef = (void**) *pc;
@@ -165,7 +165,7 @@
*pc_prederef = ((void**)(prederef_op_func)) [*pc];
break;
default:
- internal_exception(1, "Tried to prederef wrong core");
+ internal_exception(1, "Tried to prederef wrong core\n");
break;
}
/* and arguments */
@@ -205,7 +205,7 @@
break;
}
if (!init_func)
- internal_exception(1, "Couldn't find init_func for core %d", which);
+ internal_exception(1, "Couldn't find init_func for core %d\n", which);
return init_func;
}
return (oplib_init_f) D2FPTR(lib->cache.struct_val);
@@ -529,14 +529,14 @@
# endif
core = runops_cgoto_core;
#else
- internal_exception(1, "Error: PARROT_CGOTO_CORE not available");
+ internal_exception(1, "Error: PARROT_CGOTO_CORE not available\n");
#endif
break;
case PARROT_CGP_CORE:
#ifdef HAVE_COMPUTED_GOTO
core = runops_cgp;
#else
- internal_exception(1, "Error: PARROT_CGP_CORE not available");
+ internal_exception(1, "Error: PARROT_CGP_CORE not available\n");
#endif
break;
case PARROT_SWITCH_CORE:
@@ -573,7 +573,7 @@
interpreter->lo_var_ptr = old_lo_var_ptr;
if ((interpreter->resume_flag & RESUME_RESTART) &&
(int)interpreter->resume_offset < 0)
- internal_exception(1, "branch_cs: illegal resume offset");
+ internal_exception(1, "branch_cs: illegal resume offset\n");
}
}
@@ -600,7 +600,7 @@
if ((int)interpreter->resume_offset >= PF_NCONST(pf) ||
(int)interpreter->resume_offset < 0)
- internal_exception(1, "branch_cs: illegal resume offset");
+ internal_exception(1, "branch_cs: illegal resume offset\n");
c = PF_CONST(pf, interpreter->resume_offset);
if (c->type != PFC_STRING)
internal_exception(1, "branch_cs: not a string\n");
@@ -691,7 +691,7 @@
struct regsave *save;
save = mem_sys_allocate(sizeof(struct regsave));
if (!save) {
- internal_exception(ALLOCATION_ERROR, "No memory for save struct");
+ internal_exception(ALLOCATION_ERROR, "No memory for save struct\n");
}
mem_sys_memcopy(save, interp, sizeof(struct regsave));
return save;
@@ -772,7 +772,7 @@
break;
default:
internal_exception(1,
- "unhandle signature '%c' in Parrot_runops_fromc_args",
+ "unhandle signature '%c' in Parrot_runops_fromc_args\n",
sig[-1]);
}
}
@@ -796,7 +796,7 @@
case 'N': retval = (void* )®_NUM(5); break;
default:
internal_exception(1,
- "unhandle signature '%c' in Parrot_runops_fromc_args",
+ "unhandle signature '%c' in Parrot_runops_fromc_args\n",
ret);
}
return retval;
Index: src/objects.c
===================================================================
RCS file: /cvs/public/parrot/src/objects.c,v
retrieving revision 1.28
diff -u -r1.28 objects.c
--- src/objects.c 19 Dec 2003 10:01:42 -0000 1.28
+++ src/objects.c 24 Dec 2003 19:35:19 -0000
@@ -40,7 +40,7 @@
PMC *parents, *temp_pmc;
if (!PObj_is_class_TEST(base_class)) {
- internal_exception(NO_CLASS, "Can't subclass a non-class!");
+ internal_exception(NO_CLASS, "Can't subclass a non-class!\n");
}
child_class = pmc_new(interpreter, enum_class_ParrotClass);
Index: src/packfile.c
===================================================================
RCS file: /cvs/public/parrot/src/packfile.c,v
retrieving revision 1.126
diff -u -r1.126 packfile.c
--- src/packfile.c 25 Nov 2003 00:31:13 -0000 1.126
+++ src/packfile.c 24 Dec 2003 19:35:19 -0000
@@ -195,7 +195,7 @@
ci = ft->fixups[i]->offset;
if (ci < 0 || ci >= ct->const_count)
internal_exception(1,
- "Illegal fixup offset (%d) in enum_fixup_sub");
+ "Illegal fixup offset (%d) in enum_fixup_sub\n");
sub_pmc = ct->constants[ci]->u.key;
switch (sub_pmc->vtable->base_type) {
case enum_class_Sub:
@@ -2102,7 +2102,7 @@
compiler = VTABLE_get_pmc_keyed(interpreter, compreg_hash, key);
if (!VTABLE_defined(interpreter, compiler)) {
- internal_exception(1, "Couldn't find FILE compiler");
+ internal_exception(1, "Couldn't find FILE compiler\n");
return;
}
file = string_from_cstring(interpreter, filename, 0);
@@ -2117,7 +2117,7 @@
fixup_subs(interpreter, pf);
}
else
- internal_exception(1, "compiler return NULL PackFile");
+ internal_exception(1, "compiler return NULL PackFile\n");
}
}
Index: src/packout.c
===================================================================
RCS file: /cvs/public/parrot/src/packout.c,v
retrieving revision 1.32
diff -u -r1.32 packout.c
--- src/packout.c 22 Nov 2003 11:20:13 -0000 1.32
+++ src/packout.c 24 Dec 2003 19:35:20 -0000
@@ -194,7 +194,7 @@
}
break;
default:
- internal_exception(1, "pack_size: Unknown PMC constant");
+ internal_exception(1, "pack_size: Unknown PMC constant\n");
break;
}
break;
Index: src/pmc.c
===================================================================
RCS file: /cvs/public/parrot/src/pmc.c,v
retrieving revision 1.59
diff -u -r1.59 pmc.c
--- src/pmc.c 10 Dec 2003 17:18:35 -0000 1.59
+++ src/pmc.c 24 Dec 2003 19:35:20 -0000
@@ -224,7 +224,7 @@
}
if (type < enum_type_undef) {
internal_exception(1, "native type with name '%s' already exists - "
- "can't register PMC", data_types[type].name);
+ "can't register PMC\n", data_types[type].name);
return 0;
}
Index: src/pmc_freeze.c
===================================================================
RCS file: /cvs/public/parrot/src/pmc_freeze.c,v
retrieving revision 1.13
diff -u -r1.13 pmc_freeze.c
--- src/pmc_freeze.c 1 Dec 2003 09:30:18 -0000 1.13
+++ src/pmc_freeze.c 24 Dec 2003 19:35:20 -0000
@@ -497,7 +497,7 @@
else { /* type follows */
info->last_type = *type = io->vtable->shift_integer(interpreter, io);
if (*type <= 0 || *type >= enum_class_max)
- internal_exception(1, "Unknown PMC type to thaw %d", (int) *type);
+ internal_exception(1, "Unknown PMC type to thaw %d\n", (int) *type);
}
*id = (UINTVAL) n;
return seen;
@@ -520,7 +520,7 @@
info->visit_action = pmc->vtable->freeze;
break;
default:
- internal_exception(1, "Illegal action %d", info->what);
+ internal_exception(1, "Illegal action %d\n", info->what);
break;
}
}
@@ -542,7 +542,7 @@
pmc = constant_pmc_new_noinit(interpreter, type);
break;
default:
- internal_exception(1, "Illegal visit_next type");
+ internal_exception(1, "Illegal visit_next type\n");
break;
}
assert(info->thaw_ptr);
@@ -644,7 +644,7 @@
}
id += arena->total_objects;
}
- internal_exception(1, "Couldn't find PMC in arenas");
+ internal_exception(1, "Couldn't find PMC in arenas\n");
return -1;
}
#else
@@ -679,7 +679,7 @@
id += arena->total_objects;
}
- internal_exception(1, "Couldn't find PMC in arenas");
+ internal_exception(1, "Couldn't find PMC in arenas\n");
return -1;
}
#endif
Index: src/register.c
===================================================================
RCS file: /cvs/public/parrot/src/register.c,v
retrieving revision 1.34
diff -u -r1.34 register.c
--- src/register.c 28 Oct 2003 03:13:06 -0000 1.34
+++ src/register.c 24 Dec 2003 19:35:20 -0000
@@ -71,7 +71,7 @@
}
/* Nope. So pitch a fit */
else {
- internal_exception(NO_REG_FRAMES, "No more I register frames to pop!");
+ internal_exception(NO_REG_FRAMES, "No more I register frames to pop!\n");
}
}
@@ -146,7 +146,7 @@
}
/* Nope. So pitch a fit */
else {
- internal_exception(NO_REG_FRAMES, "No more S register frames to pop!");
+ internal_exception(NO_REG_FRAMES, "No more S register frames to pop!\n");
}
}
@@ -221,7 +221,7 @@
}
/* Nope. So pitch a fit */
else {
- internal_exception(NO_REG_FRAMES, "No more N register frames to pop!");
+ internal_exception(NO_REG_FRAMES, "No more N register frames to pop!\n");
}
}
@@ -296,7 +296,7 @@
}
/* Nope. So pitch a fit */
else {
- internal_exception(NO_REG_FRAMES, "No more P register frames to pop!");
+ internal_exception(NO_REG_FRAMES, "No more P register frames to pop!\n");
}
}
Index: src/resources.c
===================================================================
RCS file: /cvs/public/parrot/src/resources.c,v
retrieving revision 1.113
diff -u -r1.113 resources.c
--- src/resources.c 12 Nov 2003 11:02:34 -0000 1.113
+++ src/resources.c 24 Dec 2003 19:35:20 -0000
@@ -503,7 +503,7 @@
str->bufstart = mem_allocate(interpreter, &req_size, pool,
STRING_ALIGNMENT - 1);
if (str->bufstart == NULL) {
- internal_exception(ALLOCATION_ERROR, "Out of memory");
+ internal_exception(ALLOCATION_ERROR, "Out of memory\n");
}
str->buflen = req_size;
str->strstart = str->bufstart;
Index: src/spf_render.c
===================================================================
RCS file: /cvs/public/parrot/src/spf_render.c,v
retrieving revision 1.27
diff -u -r1.27 spf_render.c
--- src/spf_render.c 23 Oct 2003 17:48:59 -0000 1.27
+++ src/spf_render.c 24 Dec 2003 19:35:20 -0000
@@ -641,7 +641,7 @@
}
else {
internal_exception(INVALID_CHARACTER,
- "'%c' is not a valid sprintf
format",
+ "'%c' is not a valid sprintf
format\n",
ch);
}
}
Index: src/spf_vtable.c
===================================================================
RCS file: /cvs/public/parrot/src/spf_vtable.c,v
retrieving revision 1.14
diff -u -r1.14 spf_vtable.c
--- src/spf_vtable.c 23 Oct 2003 17:48:59 -0000 1.14
+++ src/spf_vtable.c 24 Dec 2003 19:35:20 -0000
@@ -151,7 +151,7 @@
}
default:
internal_exception(INVALID_CHARACTER,
- "Internal sprintf doesn't recognize size %d for a float",
+ "Internal sprintf doesn't recognize size %d for a float\n",
size);
return (HUGEFLOATVAL)0.0;
}
@@ -187,7 +187,7 @@
default:
internal_exception(INVALID_CHARACTER,
- "Internal sprintf doesn't recognize size %d for a string",
+ "Internal sprintf doesn't recognize size %d for a string\n",
size);
return NULL;
}
Index: src/string.c
===================================================================
RCS file: /cvs/public/parrot/src/string.c,v
retrieving revision 1.163
diff -u -r1.163 string.c
--- src/string.c 21 Dec 2003 10:15:19 -0000 1.163
+++ src/string.c 24 Dec 2003 19:35:20 -0000
@@ -477,7 +477,7 @@
if ((s == NULL) || (len == 0)) {
internal_exception(ORD_OUT_OF_STRING,
- "Cannot get character of empty string");
+ "Cannot get character of empty string\n");
}
else {
UINTVAL true_index;
@@ -486,7 +486,7 @@
if (idx < 0) {
if ((INTVAL)(idx + len) < 0) {
internal_exception(ORD_OUT_OF_STRING,
- "Cannot get character before beginning of string");
+ "Cannot get character before beginning of
string\n");
}
else {
true_index = (UINTVAL)(len + idx);
@@ -495,7 +495,7 @@
if (true_index > (len - 1)) {
internal_exception(ORD_OUT_OF_STRING,
- "Cannot get character past end of string");
+ "Cannot get character past end of string\n");
}
return string_index(s, true_index);
@@ -728,7 +728,7 @@
if (true_offset > src->strlen - 1) { /* 0 based... */
internal_exception(SUBSTR_OUT_OF_STRING,
- "Cannot take substr outside string");
+ "Cannot take substr outside string\n");
}
true_length = (UINTVAL)length;
@@ -758,7 +758,7 @@
if (subend_off < substart_off) {
internal_exception(SUBSTR_OUT_OF_STRING,
- "substr: subend somehow is less than substart");
+ "substr: subend somehow is less than substart\n");
}
dest->strstart = (char *)dest->strstart + substart_off;
@@ -813,7 +813,7 @@
*/
if (true_offset > src->strlen) {
internal_exception(SUBSTR_OUT_OF_STRING,
- "Can only replace inside string or index after end of string");
+ "Can only replace inside string or index after end of string\n");
}
if (true_length > (src->strlen - true_offset)) {
true_length = (UINTVAL)(src->strlen - true_offset);
@@ -831,7 +831,7 @@
if (subend_off < substart_off) {
internal_exception(SUBSTR_OUT_OF_STRING,
- "replace: subend somehow is less than substart");
+ "replace: subend somehow is less than substart\n");
}
/* XXX if *d == NULL, dest is unused, we could drop below lines
Index: src/sub.c
===================================================================
RCS file: /cvs/public/parrot/src/sub.c,v
retrieving revision 1.40
diff -u -r1.40 sub.c
--- src/sub.c 25 Oct 2003 06:13:21 -0000 1.40
+++ src/sub.c 24 Dec 2003 19:35:20 -0000
@@ -50,7 +50,7 @@
static void coro_error(Stack_Entry_t *e)
{
- internal_exception(1, "Coroutine popped main stack");
+ internal_exception(1, "Coroutine popped main stack\n");
}
/*
@@ -136,7 +136,7 @@
}
}
if (!mark_found)
- internal_exception(1, "The coroutine messed with the stack");
+ internal_exception(1, "The coroutine messed with the stack\n");
hi = stack_height(interp, *interp_stack);
hs = stack_height(interp, *saved_stack);
if (!i || (hi == hc + hs)) {
@@ -311,7 +311,7 @@
pad->cache.int_val + scope_index : scope_index;
if (scope_index >= pad->cache.int_val || scope_index < 0) {
- internal_exception(-1, "Pad index out of range");
+ internal_exception(-1, "Pad index out of range\n");
return NULL;
}
@@ -441,7 +441,7 @@
/* use name to find lex and position */
lex = scratchpad_find(interp, pad, name, &position);
if (!lex)
- internal_exception(-1, "Lexical '%s' not found",
+ internal_exception(-1, "Lexical '%s' not found\n",
(name == NULL) ? "???"
: string_to_cstring(interp, name));
}
Index: src/thread.c
===================================================================
RCS file: /cvs/public/parrot/src/thread.c,v
retrieving revision 1.8
diff -u -r1.8 thread.c
--- src/thread.c 22 Dec 2003 15:32:02 -0000 1.8
+++ src/thread.c 24 Dec 2003 19:35:20 -0000
@@ -142,15 +142,15 @@
{
if (tid >= n_interpreters) {
UNLOCK(interpreter_array_mutex);
- internal_exception(1, "%s: illegal thread tid %d", from, tid);
+ internal_exception(1, "%s: illegal thread tid %d\n", from, tid);
}
if (tid == 0) {
UNLOCK(interpreter_array_mutex);
- internal_exception(1, "%s: llegal thread tid %d (main)", from, tid);
+ internal_exception(1, "%s: llegal thread tid %d (main)\n", from, tid);
}
if (!interpreter_array[tid]) {
UNLOCK(interpreter_array_mutex);
- internal_exception(1, "%s: illegal thread tid %d - empty", from, tid);
+ internal_exception(1, "%s: illegal thread tid %d - empty\n", from, tid);
}
return interpreter_array[tid];
}
@@ -181,7 +181,7 @@
*/
state = interpreter->thread_data->state;
UNLOCK(interpreter_array_mutex);
- internal_exception(1, "join: illegal thread state %d tid %d", state, tid);
+ internal_exception(1, "join: illegal thread state %d tid %d\n", state, tid);
return NULL;
}
Index: src/trace.c
===================================================================
RCS file: /cvs/public/parrot/src/trace.c,v
retrieving revision 1.44
diff -u -r1.44 trace.c
--- src/trace.c 19 Nov 2003 09:57:36 -0000 1.44
+++ src/trace.c 24 Dec 2003 19:35:20 -0000
@@ -206,7 +206,7 @@
/* this isn't handled, so at least report the error
* instead of silently ignoring the problem */
internal_exception(ARG_OP_NOT_HANDLED,
- "PARROT_ARG_OP in enumeration not handled in
switch");
+ "PARROT_ARG_OP in enumeration not handled in
switch\n");
break;
default:
/* -Wall expects us to cover PARROT_ARG_OP somewhere. */
Index: src/tsq.c
===================================================================
RCS file: /cvs/public/parrot/src/tsq.c,v
retrieving revision 1.11
diff -u -r1.11 tsq.c
--- src/tsq.c 19 Dec 2003 12:49:22 -0000 1.11
+++ src/tsq.c 24 Dec 2003 19:35:20 -0000
@@ -179,7 +179,7 @@
queue_destroy(QUEUE *queue)
{
if (peek_entry(queue))
- internal_exception(1, "Queue not emty on destroy");
+ internal_exception(1, "Queue not emty on destroy\n");
COND_DESTROY(queue->queue_condition);
MUTEX_DESTROY(queue->queue_mutex);
mem_sys_free(queue);
Index: t/op/stacks.t
===================================================================
RCS file: /cvs/public/parrot/t/op/stacks.t,v
retrieving revision 1.31
diff -u -r1.31 stacks.t
--- t/op/stacks.t 18 Jul 2003 16:01:11 -0000 1.31
+++ t/op/stacks.t 24 Dec 2003 19:35:20 -0000
@@ -678,15 +678,15 @@
# Now, to make it do BAD THINGS!
-output_is(<<"CODE",'No more I register frames to pop!','ENO I frames');
+output_is(<<"CODE","No more I register frames to pop!\n",'ENO I frames');
popi
end
CODE
-output_is(<<"CODE",'No more N register frames to pop!','ENO N frames');
+output_is(<<"CODE","No more N register frames to pop!\n",'ENO N frames');
popn
end
CODE
-output_is(<<"CODE",'No more S register frames to pop!','ENO S frames');
+output_is(<<"CODE","No more S register frames to pop!\n",'ENO S frames');
pops
end
CODE
Index: t/op/string.t
===================================================================
RCS file: /cvs/public/parrot/t/op/string.t,v
retrieving revision 1.61
diff -u -r1.61 string.t
--- t/op/string.t 4 Nov 2003 20:05:26 -0000 1.61
+++ t/op/string.t 24 Dec 2003 19:35:20 -0000
@@ -239,7 +239,7 @@
OUTPUT
# This asks for substring it shouldn't be allowed...
-output_is(<<'CODE', 'Cannot take substr outside string', "substr OOB");
+output_is(<<'CODE', "Cannot take substr outside string\n", "substr OOB");
set S0, "A string of length 21"
set I0, -99
set I1, 6
@@ -248,7 +248,7 @@
CODE
# This asks for substring it shouldn't be allowed...
-output_is(<<'CODE', 'Cannot take substr outside string', "substr OOB");
+output_is(<<'CODE', "Cannot take substr outside string\n", "substr OOB");
set S0, "A string of length 21"
set I0, 99
set I1, 6
@@ -356,7 +356,7 @@
OUTPUT
-output_is( <<'CODE', 'Can only replace inside string or index after end of string',
"5 arg substr, offset past end of string" );
+output_is( <<'CODE', "Can only replace inside string or index after end of string\n",
"5 arg substr, offset past end of string" );
set S0, "abcdefghijk"
set S1, "xyz"
substr S2, S0, 12, 3, S1
@@ -420,7 +420,7 @@
fghi
OUTPUT
-output_is( <<'CODE', 'Can only replace inside string or index after end of string',
"5 arg substr, -ve offset out of string" );
+output_is( <<'CODE', "Can only replace inside string or index after end of string\n",
"5 arg substr, -ve offset out of string" );
set S0, "abcdefghijk"
set S1, "xyz"
substr S2, S0, -12, 4, S1
@@ -875,25 +875,25 @@
foo
OUTPUT
-output_is(<<'CODE','Cannot get character of empty string','2-param ord, empty
string');
+output_is(<<'CODE',"Cannot get character of empty string\n",'2-param ord, empty
string');
ord I0,""
print I0
end
CODE
-output_is(<<'CODE','Cannot get character of empty string','2-param ord, empty string
register');
+output_is(<<'CODE',"Cannot get character of empty string\n",'2-param ord, empty
string register');
ord I0,S0
print I0
end
CODE
-output_is(<<'CODE','Cannot get character of empty string','3-param ord, empty
string');
+output_is(<<'CODE',"Cannot get character of empty string\n",'3-param ord, empty
string');
ord I0,"",0
print I0
end
CODE
-output_is(<<'CODE','Cannot get character of empty string','3-param ord, empty string
register');
+output_is(<<'CODE',"Cannot get character of empty string\n",'3-param ord, empty
string register');
ord I0,S0,0
print I0
end
@@ -944,13 +944,13 @@
end
CODE
-output_is(<<'CODE', 'Cannot get character past end of string','3-param ord,
multi-character string');
+output_is(<<'CODE', "Cannot get character past end of string\n",'3-param ord,
multi-character string');
ord I0,"ab",2
print I0
end
CODE
-output_is(<<'CODE', 'Cannot get character past end of string','3-param ord,
multi-character string');
+output_is(<<'CODE', "Cannot get character past end of string\n",'3-param ord,
multi-character string');
set S0,"ab"
ord I0,S0,2
print I0
@@ -983,7 +983,7 @@
end
CODE
-output_is(<<'CODE','Cannot get character before beginning of string','3-param ord,
multi-character string register, from end, OOB');
+output_is(<<'CODE',"Cannot get character before beginning of string\n",'3-param ord,
multi-character string register, from end, OOB');
set S0,"ab"
ord I0,S0,-3
print I0