[svn:parrot] r44779 - trunk/src/pmc

plobsing at svn.parrot.org plobsing at svn.parrot.org
Mon Mar 8 23:09:27 UTC 2010


Author: plobsing
Date: Mon Mar  8 23:09:26 2010
New Revision: 44779
URL: https://trac.parrot.org/parrot/changeset/44779

Log:
remove Complex.invoke

Modified:
   trunk/src/pmc/complex.pmc

Modified: trunk/src/pmc/complex.pmc
==============================================================================
--- trunk/src/pmc/complex.pmc	Mon Mar  8 23:08:38 2010	(r44778)
+++ trunk/src/pmc/complex.pmc	Mon Mar  8 23:09:26 2010	(r44779)
@@ -224,37 +224,6 @@
 
 /*
 
-=item C<opcode_t *invoke(void *next)>
-
-Pythonic object constructor. SELF is a Complex Class object. Return a new
-C<complex> object according to 2.1. Built-in Functions.
-
-=cut
-
-*/
-    VTABLE opcode_t *invoke(void *next) {
-        const int   argcP = REG_INT(interp, 3);
-        PMC * const res   = Parrot_pmc_new(INTERP, enum_class_Complex);
-
-        if (argcP == 1) {
-            PMC * const arg = REG_PMC(interp, 5);
-
-            if (arg->vtable->base_type == enum_class_String)
-                VTABLE_set_string_native(INTERP, res, VTABLE_get_string(interp, arg));
-            else
-                SET_ATTR_re(INTERP, res, VTABLE_get_number(INTERP, arg));
-        }
-        else if (argcP == 2) {
-            SET_ATTR_re(INTERP, res, VTABLE_get_number(INTERP, REG_PMC(interp, 5)));
-            SET_ATTR_im(INTERP, res, VTABLE_get_number(INTERP, REG_PMC(interp, 6)));
-        }
-
-        REG_PMC(interp, 5) = res;
-        return (opcode_t *)next;
-    }
-
-/*
-
 =back
 
 =head2 Methods


More information about the parrot-commits mailing list