Skip to content

Commit 358eeb0

Browse files
committed
regularize "P6opaque attributes NYFI" error messages, include method name and attribute
1 parent 879073f commit 358eeb0

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

src/6model/reprs/P6opaque.c

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -442,7 +442,7 @@ static PMC * get_attribute(PARROT_INTERP, PMC *obj, PMC *class_handle, STRING *n
442442

443443
/* Fall back to the spill storage. */
444444
Parrot_ex_throw_from_c_args(interp, NULL, EXCEPTION_INVALID_OPERATION,
445-
"P6opaque attributes NYFI 1 (attribute '%Ss')", name);
445+
"P6opaque attributes NYFI 1 (attribute '%Ss' in get_attribute)", name);
446446
}
447447
static INTVAL get_attribute_int(PARROT_INTERP, PMC *obj, PMC *class_handle, STRING *name, INTVAL hint) {
448448
P6opaqueInstance *instance = (P6opaqueInstance *)PMC_data(obj);
@@ -480,7 +480,7 @@ static FLOATVAL get_attribute_num(PARROT_INTERP, PMC *obj, PMC *class_handle, ST
480480

481481
/* Fall back to the spill storage. */
482482
Parrot_ex_throw_from_c_args(interp, NULL, EXCEPTION_INVALID_OPERATION,
483-
"P6opaque attributes NYFI 2 (attribute '%Ss')", name);
483+
"P6opaque attributes NYFI 2 (attribute '%Ss' in get_attribute_num)", name);
484484
}
485485
static STRING * get_attribute_str(PARROT_INTERP, PMC *obj, PMC *class_handle, STRING *name, INTVAL hint) {
486486
P6opaqueInstance *instance = (P6opaqueInstance *)PMC_data(obj);
@@ -501,7 +501,7 @@ static STRING * get_attribute_str(PARROT_INTERP, PMC *obj, PMC *class_handle, ST
501501

502502
/* Fall back to the spill storage. */
503503
Parrot_ex_throw_from_c_args(interp, NULL, EXCEPTION_INVALID_OPERATION,
504-
"P6opaque attributes NYFI 3 (attribute '%Ss')", name);
504+
"P6opaque attributes NYFI 3 (attribute '%Ss' in get_attribute_str)", name);
505505
}
506506

507507
/* Binds the given value to the specified attribute. */
@@ -524,7 +524,7 @@ static void bind_attribute(PARROT_INTERP, PMC *obj, PMC *class_handle, STRING *n
524524

525525
/* Fall back to the spill storage. */
526526
Parrot_ex_throw_from_c_args(interp, NULL, EXCEPTION_INVALID_OPERATION,
527-
"P6opaque attributes NYFI 4 (attribute '%Ss' not found)", name);
527+
"P6opaque attributes NYFI 4 (attribute '%Ss' in bind_attribute)", name);
528528
}
529529
static void bind_attribute_int(PARROT_INTERP, PMC *obj, PMC *class_handle, STRING *name, INTVAL hint, INTVAL value) {
530530
P6opaqueInstance *instance = (P6opaqueInstance *)PMC_data(obj);
@@ -545,7 +545,7 @@ static void bind_attribute_int(PARROT_INTERP, PMC *obj, PMC *class_handle, STRIN
545545

546546
/* Fall back to the spill storage. */
547547
Parrot_ex_throw_from_c_args(interp, NULL, EXCEPTION_INVALID_OPERATION,
548-
"P6opaque attributes NYFI 5");
548+
"P6opaque attributes NYFI 5 (attribute '%s' in bind_attribute_int)");
549549
}
550550
static void bind_attribute_num(PARROT_INTERP, PMC *obj, PMC *class_handle, STRING *name, INTVAL hint, FLOATVAL value) {
551551
P6opaqueInstance *instance = (P6opaqueInstance *)PMC_data(obj);
@@ -566,7 +566,7 @@ static void bind_attribute_num(PARROT_INTERP, PMC *obj, PMC *class_handle, STRIN
566566

567567
/* Fall back to the spill storage. */
568568
Parrot_ex_throw_from_c_args(interp, NULL, EXCEPTION_INVALID_OPERATION,
569-
"P6opaque attributes NYFI 6");
569+
"P6opaque attributes NYFI 6 (attribute '%s' in bind_attribute_num)", name);
570570
}
571571
static void bind_attribute_str(PARROT_INTERP, PMC *obj, PMC *class_handle, STRING *name, INTVAL hint, STRING *value) {
572572
P6opaqueInstance *instance = (P6opaqueInstance *)PMC_data(obj);
@@ -587,7 +587,7 @@ static void bind_attribute_str(PARROT_INTERP, PMC *obj, PMC *class_handle, STRIN
587587

588588
/* Fall back to the spill storage. */
589589
Parrot_ex_throw_from_c_args(interp, NULL, EXCEPTION_INVALID_OPERATION,
590-
"P6opaque attributes NYFI 7");
590+
"P6opaque attributes NYFI 7 (attribute '%s' in bind_attribute_str)", name);
591591
}
592592

593593
/* Gets the hint for the given attribute ID. */

0 commit comments

Comments
 (0)