Author: chromatic
Date: Wed Apr 18 18:05:52 2007
New Revision: 18280

Modified:
   trunk/include/parrot/exceptions.h
   trunk/src/objects.c

Log:
Fixed a typo in an exception name.

Minor header cleanups (hey, you have to recompile anyway).

Modified: trunk/include/parrot/exceptions.h
==============================================================================
--- trunk/include/parrot/exceptions.h   (original)
+++ trunk/include/parrot/exceptions.h   Wed Apr 18 18:05:52 2007
@@ -132,7 +132,7 @@
         INTERNAL_NOT_IMPLEMENTED,
         ERR_OVERFLOW,
         LOSSY_CONVERSION,
-        ROLE_COMPOSITOIN_METH_CONFLICT
+        ROLE_COMPOSITION_METH_CONFLICT
 } exception_type_enum;
 
 /* &end_gen */
@@ -140,19 +140,20 @@
 /* &gen_from_enum(except_severity.pasm) subst(s/(\w+)/uc($1)/e) */
 
 typedef enum {
-    EXCEPT_normal = 0,
+    EXCEPT_normal  = 0,
     EXCEPT_warning = 1,
-    EXCEPT_error = 2,
-    EXCEPT_severe = 3,
-    EXCEPT_fatal = 4,
-    EXCEPT_doomed = 5,
-    EXCEPT_exit = 6
+    EXCEPT_error   = 2,
+    EXCEPT_severe  = 3,
+    EXCEPT_fatal   = 4,
+    EXCEPT_doomed  = 5,
+    EXCEPT_exit    = 6
 } exception_severity;
 
 /* &end_gen */
 
-/* Right now there's nothing special for the jump buffer, but there might be 
one later, so we wrap it in a struct so that we can expand it later */
-struct parrot_exception_t {
+/* Right now there's nothing special for the jump buffer, but there might be
+ * one later, so we wrap it in a struct so that we can expand it later */
+typedef struct parrot_exception_t {
     Parrot_jump_buff destination;       /* jmp_buf */
     exception_severity severity;        /* s. above */
     long error;                         /* exception_type_enum */
@@ -161,9 +162,8 @@
     struct parrot_exception_t *prev;    /* interpreters handler stack */
     long language;                      /* what is this? */
     long system;                        /* what is this? */
-};
+} Parrot_exception;
 
-typedef struct parrot_exception_t Parrot_exception;
 /*
  * user level exception handling
  */

Modified: trunk/src/objects.c
==============================================================================
--- trunk/src/objects.c (original)
+++ trunk/src/objects.c Wed Apr 18 18:05:52 2007
@@ -1931,7 +1931,7 @@
              * XXX TODO: multi-method handling. */
             if (VTABLE_exists_keyed_str(interp, methods_hash, method_name)) {
                 /* Conflicts with something already in the class. */
-                real_exception(interp, NULL, ROLE_COMPOSITOIN_METH_CONFLICT,
+                real_exception(interp, NULL, ROLE_COMPOSITION_METH_CONFLICT,
                     "A conflict occurred during role composition due to method 
'%S'.",
                     method_name);
                 return;
@@ -1940,7 +1940,7 @@
             /* What about a conflict with ourslef? */
             if (VTABLE_exists_keyed_str(interp, proposed_add_methods, 
method_name)) {
                 /* Something very weird is going on. */
-                real_exception(interp, NULL, ROLE_COMPOSITOIN_METH_CONFLICT,
+                real_exception(interp, NULL, ROLE_COMPOSITION_METH_CONFLICT,
                     "A conflict occurred during role composition;"
                     " the method '%S' from the role managed to conflict with 
itself somehow.",
                     method_name);
@@ -1960,7 +1960,7 @@
              * XXX TODO: multi-method handling. */
             if (VTABLE_exists_keyed_str(interp, methods_hash, alias_name)) {
                 /* Conflicts with something already in the class. */
-                real_exception(interp, NULL, ROLE_COMPOSITOIN_METH_CONFLICT,
+                real_exception(interp, NULL, ROLE_COMPOSITION_METH_CONFLICT,
                     "A conflict occurred during role composition"
                     " due to the aliasing of '%S' to '%S'.",
                     method_name, alias_name);
@@ -1969,7 +1969,7 @@
 
             /* What about a conflict with ourslef? */
             if (VTABLE_exists_keyed_str(interp, proposed_add_methods, 
alias_name)) {
-                real_exception(interp, NULL, ROLE_COMPOSITOIN_METH_CONFLICT,
+                real_exception(interp, NULL, ROLE_COMPOSITION_METH_CONFLICT,
                     "A conflict occurred during role composition"
                     " due to the aliasing of '%S' to '%S' (role already has"
                     " a method '%S').",

Reply via email to