# New Ticket Created by Leon Brocard # Please include the string: [perl #18565] # in the subject line of all future correspondence about this issue. # <URL: http://rt.perl.org/rt2/Ticket/Display.html?id=18565 >
A minor change to aid debugging. (To be honest, it would be wonderful if exceptions gave you a line number and code too, but let's keep it simple for now). Leon -- Leon Brocard.............................http://www.astray.com/ scribot.................................http://www.scribot.com/ ....... Useless invention no. 404: Caffeine-free Diet Coke -- attachment 1 ------------------------------------------------------ url: http://rt.perl.org/rt2/attach/42088/33843/61b57c/key.patch
Index: key.c =================================================================== RCS file: /cvs/public/parrot/key.c,v retrieving revision 1.33 diff -u -r1.33 key.c --- key.c 2 Nov 2002 14:57:47 -0000 1.33 +++ key.c 21 Nov 2002 11:58:04 -0000 @@ -143,7 +143,7 @@ reg = interpreter->ctx.pmc_reg.registers[key->cache.int_val]; return reg->vtable->get_integer(interpreter, reg); default: - internal_exception(INVALID_OPERATION, "Not an integer!\n"); + internal_exception(INVALID_OPERATION, "Key not an integer!\n"); return 0; } } @@ -165,7 +165,7 @@ reg = interpreter->ctx.pmc_reg.registers[key->cache.int_val]; return reg->vtable->get_number(interpreter, reg); default: - internal_exception(INVALID_OPERATION, "Not a number!\n"); + internal_exception(INVALID_OPERATION, "Key not a number!\n"); return 0; } } @@ -187,7 +187,7 @@ reg = interpreter->ctx.pmc_reg.registers[key->cache.int_val]; return reg->vtable->get_string(interpreter, reg); default: - internal_exception(INVALID_OPERATION, "Not a string!\n"); + internal_exception(INVALID_OPERATION, "Key not a string!\n"); return 0; } } @@ -201,7 +201,7 @@ case KEY_pmc_FLAG | KEY_register_FLAG: return interpreter->ctx.pmc_reg.registers[key->cache.int_val]; default: - internal_exception(INVALID_OPERATION, "Not a PMC!\n"); + internal_exception(INVALID_OPERATION, "Key not a PMC!\n"); return 0; } }