Permalink
Browse files

changed interp in pmc class to INTERP for unification

git-svn-id: https://svn.parrot.org/parrot/trunk@46300 d31e2699-5ff4-0310-a27c-f18f2fbe73fe
  • Loading branch information...
1 parent 4d3324b commit 26914e12adecfae2948f49b7fd5e0e54aa0178e7 Jimmy Zhuo committed May 5, 2010
Showing with 1,286 additions and 1,287 deletions.
  1. +17 −17 src/dynpmc/dynlexpad.pmc
  2. +15 −15 src/dynpmc/file.pmc
  3. +4 −4 src/dynpmc/foo.pmc
  4. +6 −6 src/dynpmc/os.pmc
  5. +13 −13 src/dynpmc/pccmethod_test.pmc
  6. +10 −10 src/dynpmc/subproxy.pmc
  7. +3 −4 src/oo.c
  8. +6 −6 src/pmc/addrregistry.pmc
  9. +18 −18 src/pmc/arrayiterator.pmc
  10. +28 −28 src/pmc/bigint.pmc
  11. +28 −28 src/pmc/bignum.pmc
  12. +23 −23 src/pmc/callcontext.pmc
  13. +18 −18 src/pmc/complex.pmc
  14. +5 −5 src/pmc/coroutine.pmc
  15. +77 −77 src/pmc/default.pmc
  16. +6 −6 src/pmc/env.pmc
  17. +4 −4 src/pmc/eval.pmc
  18. +7 −7 src/pmc/eventhandler.pmc
  19. +84 −84 src/pmc/exception.pmc
  20. +15 −15 src/pmc/exceptionhandler.pmc
  21. +36 −36 src/pmc/exporter.pmc
  22. +10 −10 src/pmc/filehandle.pmc
  23. +2 −2 src/pmc/fixedbooleanarray.pmc
  24. +1 −1 src/pmc/fixedfloatarray.pmc
  25. +4 −4 src/pmc/fixedintegerarray.pmc
  26. +7 −7 src/pmc/fixedpmcarray.pmc
  27. +6 −6 src/pmc/fixedstringarray.pmc
  28. +2 −2 src/pmc/handle.pmc
  29. +8 −8 src/pmc/hash.pmc
  30. +11 −11 src/pmc/imageio.pmc
  31. +6 −6 src/pmc/imageiosize.pmc
  32. +57 −57 src/pmc/integer.pmc
  33. +1 −1 src/pmc/key.pmc
  34. +6 −6 src/pmc/lexinfo.pmc
  35. +2 −2 src/pmc/managedstruct.pmc
  36. +23 −23 src/pmc/multisub.pmc
  37. +39 −39 src/pmc/namespace.pmc
  38. +5 −5 src/pmc/null.pmc
  39. +92 −92 src/pmc/object.pmc
  40. +3 −3 src/pmc/opcode.pmc
  41. +2 −2 src/pmc/oplib.pmc
  42. +42 −42 src/pmc/packfile.pmc
  43. +5 −5 src/pmc/packfileannotation.pmc
  44. +48 −48 src/pmc/packfileannotations.pmc
  45. +40 −40 src/pmc/packfileconstanttable.pmc
  46. +23 −23 src/pmc/packfiledirectory.pmc
  47. +4 −4 src/pmc/packfilefixupentry.pmc
  48. +12 −12 src/pmc/packfilefixuptable.pmc
  49. +10 −10 src/pmc/packfilerawsegment.pmc
  50. +3 −3 src/pmc/packfilesegment.pmc
  51. +49 −49 src/pmc/parrotinterpreter.pmc
  52. +11 −11 src/pmc/parrotthread.pmc
  53. +73 −73 src/pmc/pmcproxy.pmc
  54. +5 −5 src/pmc/resizablebooleanarray.pmc
  55. +4 −4 src/pmc/resizablefloatarray.pmc
  56. +5 −5 src/pmc/resizableintegerarray.pmc
  57. +8 −8 src/pmc/resizablestringarray.pmc
  58. +76 −76 src/pmc/role.pmc
  59. +20 −20 src/pmc/scheduler.pmc
  60. +6 −6 src/pmc/schedulermessage.pmc
  61. +8 −8 src/pmc/socket.pmc
  62. +8 −8 src/pmc/string.pmc
  63. +11 −11 src/pmc/stringhandle.pmc
  64. +53 −53 src/pmc/sub.pmc
  65. +40 −40 src/pmc/task.pmc
  66. +3 −3 src/pmc/timer.pmc
  67. +8 −8 src/pmc/undef.pmc
  68. +1 −1 src/pmc/unmanagedstruct.pmc
View
34 src/dynpmc/dynlexpad.pmc
@@ -24,7 +24,7 @@ pmclass DynLexPad dynpmc provides lexpad auto_attrs {
ATTR PMC *init; /* the PMC used to initialize this DynLexPad */
VTABLE void init() {
- Parrot_ex_throw_from_c_args(interp, NULL, EXCEPTION_INVALID_OPERATION,
+ Parrot_ex_throw_from_c_args(INTERP, NULL, EXCEPTION_INVALID_OPERATION,
"don't create me like this");
}
@@ -44,8 +44,8 @@ lexinfo.
Parrot_DynLexPad_attributes *attrs =
(Parrot_DynLexPad_attributes *) PMC_data(SELF);
- if (VTABLE_elements(interp, lexinfo)) {
- attrs->init = Parrot_pmc_new_init(interp, enum_class_LexPad, lexinfo);
+ if (VTABLE_elements(INTERP, lexinfo)) {
+ attrs->init = Parrot_pmc_new_init(INTERP, enum_class_LexPad, lexinfo);
}
else
attrs->init = NULL;
@@ -68,7 +68,7 @@ Initialize the LexPad PMC and remember the associate context.
VTABLE void set_pointer(void* ctx) {
PMC *std_pad = PARROT_DYNLEXPAD(SELF)->init;
if (std_pad)
- VTABLE_set_pointer(interp, std_pad, ctx);
+ VTABLE_set_pointer(INTERP, std_pad, ctx);
}
/*
@@ -81,7 +81,7 @@ Returns the number of elements in the hash.
*/
VTABLE INTVAL elements() {
- return parrot_hash_size(interp, PARROT_DYNLEXPAD(SELF)->hash);
+ return parrot_hash_size(INTERP, PARROT_DYNLEXPAD(SELF)->hash);
}
/*
@@ -97,17 +97,17 @@ Returns whether a lexical C<name> exists in the hash.
*/
VTABLE INTVAL exists_keyed(PMC* name) {
- STRING *s = VTABLE_get_string(interp, name);
+ STRING *s = VTABLE_get_string(INTERP, name);
return SELF.exists_keyed_str(s);
}
VTABLE INTVAL exists_keyed_str(STRING* name) {
PMC *std_pad;
- if (parrot_hash_exists(interp, PARROT_DYNLEXPAD(SELF)->hash, name))
+ if (parrot_hash_exists(INTERP, PARROT_DYNLEXPAD(SELF)->hash, name))
return 1;
std_pad = PARROT_DYNLEXPAD(SELF)->init;
if (std_pad)
- return VTABLE_exists_keyed_str(interp, std_pad, name);
+ return VTABLE_exists_keyed_str(INTERP, std_pad, name);
return 0;
}
@@ -124,14 +124,14 @@ lexical doesn't exist.
*/
VTABLE PMC* get_pmc_keyed_str(STRING* name) {
- HashBucket *b = parrot_hash_get_bucket(interp,
+ HashBucket *b = parrot_hash_get_bucket(INTERP,
PARROT_DYNLEXPAD(SELF)->hash, name);
if (!b) {
PMC *std_pad = PARROT_DYNLEXPAD(SELF)->init;
if (std_pad)
- return VTABLE_get_pmc_keyed_str(interp, std_pad, name);
+ return VTABLE_get_pmc_keyed_str(INTERP, std_pad, name);
return PMCNULL;
}
@@ -140,7 +140,7 @@ lexical doesn't exist.
}
VTABLE PMC* get_pmc_keyed(PMC* name) {
- STRING *s = VTABLE_get_string(interp, name);
+ STRING *s = VTABLE_get_string(INTERP, name);
return SELF.get_pmc_keyed_str(s);
}
@@ -159,17 +159,17 @@ doesn't exist, it is created.
*/
VTABLE void set_pmc_keyed(PMC* name, PMC* value) {
- STRING *s = VTABLE_get_string(interp, name);
+ STRING *s = VTABLE_get_string(INTERP, name);
SELF.set_pmc_keyed_str(s, value);
}
VTABLE void set_pmc_keyed_str(STRING* name, PMC* value) {
PMC *std_pad = PARROT_DYNLEXPAD(SELF)->init;
- if (std_pad && VTABLE_exists_keyed_str(interp, std_pad, name))
- VTABLE_set_pmc_keyed_str(interp, std_pad, name, value);
+ if (std_pad && VTABLE_exists_keyed_str(INTERP, std_pad, name))
+ VTABLE_set_pmc_keyed_str(INTERP, std_pad, name, value);
- parrot_hash_put(interp, PARROT_DYNLEXPAD(SELF)->hash, name, value);
+ parrot_hash_put(INTERP, PARROT_DYNLEXPAD(SELF)->hash, name, value);
}
/*
@@ -184,7 +184,7 @@ Destroy DynLexPad.
VTABLE void destroy() {
if (PARROT_DYNLEXPAD(SELF)->hash) {
- parrot_hash_destroy(interp, PARROT_DYNLEXPAD(SELF)->hash);
+ parrot_hash_destroy(INTERP, PARROT_DYNLEXPAD(SELF)->hash);
PARROT_DYNLEXPAD(SELF)->hash = NULL;
}
}
@@ -202,7 +202,7 @@ Marks the lexpad hash as live.
PMC *std_pad = PARROT_DYNLEXPAD(SELF)->init;
Parrot_gc_mark_PMC_alive(INTERP, std_pad);
if (PARROT_DYNLEXPAD(SELF)->hash)
- parrot_mark_hash(interp, PARROT_DYNLEXPAD(SELF)->hash);
+ parrot_mark_hash(INTERP, PARROT_DYNLEXPAD(SELF)->hash);
}
View
30 src/dynpmc/file.pmc
@@ -67,7 +67,7 @@ Returns a true value (1) if the supplied file or directory exists.
METHOD exists(STRING *path) {
struct stat info;
- char * const cpath = Parrot_str_to_cstring(interp, path);
+ char * const cpath = Parrot_str_to_cstring(INTERP, path);
#ifdef WIN32
const int error = stat(cpath, &info);
#else
@@ -93,7 +93,7 @@ Returns a true value (1) if the supplied path is a directory.
METHOD is_dir(STRING *path) {
struct stat info;
- char * const cpath = Parrot_str_to_cstring(interp, path);
+ char * const cpath = Parrot_str_to_cstring(INTERP, path);
#ifdef WIN32
const int error = stat(cpath, &info);
#else
@@ -103,7 +103,7 @@ Returns a true value (1) if the supplied path is a directory.
if (error) {
const char * const errmsg = strerror(errno);
- Parrot_ex_throw_from_c_args(interp, NULL, EXCEPTION_EXTERNAL_ERROR,
+ Parrot_ex_throw_from_c_args(INTERP, NULL, EXCEPTION_EXTERNAL_ERROR,
errmsg);
}
@@ -125,7 +125,7 @@ Returns a true value (1) if the supplied path is a plain file.
METHOD is_file(STRING *path) {
struct stat info;
- char * const cpath = Parrot_str_to_cstring(interp, path);
+ char * const cpath = Parrot_str_to_cstring(INTERP, path);
#ifdef WIN32
int error = stat(cpath, &info);
#else
@@ -135,7 +135,7 @@ Returns a true value (1) if the supplied path is a plain file.
if (error) {
const char * const errmsg = strerror(errno);
- Parrot_ex_throw_from_c_args(interp, NULL, EXCEPTION_EXTERNAL_ERROR,
+ Parrot_ex_throw_from_c_args(INTERP, NULL, EXCEPTION_EXTERNAL_ERROR,
errmsg);
}
@@ -162,14 +162,14 @@ Returns a true value (1) if the supplied path is a link.
#else
struct stat info;
- char * const cpath = Parrot_str_to_cstring(interp, path);
+ char * const cpath = Parrot_str_to_cstring(INTERP, path);
const int error = lstat(cpath, &info);
Parrot_str_free_cstring(cpath);
if (error) {
const char * const errmsg = strerror(errno);
- Parrot_ex_throw_from_c_args(interp, NULL, EXCEPTION_EXTERNAL_ERROR,
+ Parrot_ex_throw_from_c_args(INTERP, NULL, EXCEPTION_EXTERNAL_ERROR,
errmsg);
}
@@ -199,13 +199,13 @@ free to change or give me hints on how to change it. -- ambs
METHOD copy(STRING *from, STRING *to) {
#define CHUNK_SIZE 1024
- char * const cfrom = Parrot_str_to_cstring(interp, from);
+ char * const cfrom = Parrot_str_to_cstring(INTERP, from);
FILE * const source = fopen(cfrom, "rb");
Parrot_str_free_cstring(cfrom);
if (source) {
- char * const cto = Parrot_str_to_cstring(interp, to);
+ char * const cto = Parrot_str_to_cstring(INTERP, to);
FILE * const target = fopen(cto, "w+b");
Parrot_str_free_cstring(cto);
@@ -218,7 +218,7 @@ free to change or give me hints on how to change it. -- ambs
if (bytes_read) {
const size_t bytes_written = fwrite(buf, 1, bytes_read, target);
if (bytes_read != bytes_written) {
- Parrot_ex_throw_from_c_args(interp, NULL,
+ Parrot_ex_throw_from_c_args(INTERP, NULL,
EXCEPTION_EXTERNAL_ERROR, "Error writing file");
break;
}
@@ -228,14 +228,14 @@ free to change or give me hints on how to change it. -- ambs
}
else {
const char * const errmsg = strerror(errno);
- Parrot_ex_throw_from_c_args(interp, NULL, EXCEPTION_EXTERNAL_ERROR,
+ Parrot_ex_throw_from_c_args(INTERP, NULL, EXCEPTION_EXTERNAL_ERROR,
errmsg);
}
fclose(source);
}
else {
const char * const errmsg = strerror(errno);
- Parrot_ex_throw_from_c_args(interp, NULL, EXCEPTION_EXTERNAL_ERROR,
+ Parrot_ex_throw_from_c_args(INTERP, NULL, EXCEPTION_EXTERNAL_ERROR,
errmsg);
}
#undef CHUNK_SIZE
@@ -252,16 +252,16 @@ Rename a file C<from> to the path C<to>.
*/
METHOD rename(STRING *from, STRING *to) {
- char * const cfrom = Parrot_str_to_cstring(interp, from);
- char * const cto = Parrot_str_to_cstring(interp, to);
+ char * const cfrom = Parrot_str_to_cstring(INTERP, from);
+ char * const cto = Parrot_str_to_cstring(INTERP, to);
const int error = rename(cfrom, cto);
Parrot_str_free_cstring(cfrom);
Parrot_str_free_cstring(cto);
if (error) {
const char * const errmsg = strerror(errno);
- Parrot_ex_throw_from_c_args(interp, NULL, EXCEPTION_EXTERNAL_ERROR,
+ Parrot_ex_throw_from_c_args(INTERP, NULL, EXCEPTION_EXTERNAL_ERROR,
errmsg);
}
}
View
8 src/dynpmc/foo.pmc
@@ -16,15 +16,15 @@ pmclass Foo dynpmc group foo_group provides scalar extends Integer auto_attrs {
MULTI PMC* subtract(Integer value, PMC *dest) {
if (!dest)
- dest = Parrot_pmc_new(interp, SELF->vtable->base_type);
- VTABLE_set_integer_native(interp, dest, 144);
+ dest = Parrot_pmc_new(INTERP, SELF->vtable->base_type);
+ VTABLE_set_integer_native(INTERP, dest, 144);
return dest;
}
MULTI PMC* subtract(DEFAULT value, PMC *dest) {
if (!dest)
- dest = Parrot_pmc_new(interp, SELF->vtable->base_type);
- VTABLE_set_integer_native(interp, dest, 244);
+ dest = Parrot_pmc_new(INTERP, SELF->vtable->base_type);
+ VTABLE_set_integer_native(INTERP, dest, 244);
return dest;
}
}
View
12 src/dynpmc/os.pmc
@@ -506,13 +506,13 @@ reads entries from a directory.
HANDLE hFind = INVALID_HANDLE_VALUE;
/* Add \* to the directory name and start search. */
- STRING *last_char = Parrot_str_substr(interp, path,
- Parrot_str_length(interp, path) - 1, 1, NULL, 0);
- int trailing_slash = Parrot_str_equal(interp, last_char, string_from_literal(interp, "\\"))
+ STRING *last_char = Parrot_str_substr(INTERP, path,
+ Parrot_str_length(INTERP, path) - 1, 1, NULL, 0);
+ int trailing_slash = Parrot_str_equal(INTERP, last_char, string_from_literal(INTERP, "\\"))
||
- Parrot_str_equal(interp, last_char, string_from_literal(interp, "/"));
- cpath = Parrot_str_to_cstring(interp, Parrot_str_concat(interp,
- path, string_from_literal(interp, trailing_slash ? "*" : "\\*"), 0));
+ Parrot_str_equal(INTERP, last_char, string_from_literal(INTERP, "/"));
+ cpath = Parrot_str_to_cstring(INTERP, Parrot_str_concat(INTERP,
+ path, string_from_literal(INTERP, trailing_slash ? "*" : "\\*"), 0));
hFind = FindFirstFile(cpath, &file_find_data);
Parrot_str_free_cstring(cpath);
if (hFind == INVALID_HANDLE_VALUE)
View
26 src/dynpmc/pccmethod_test.pmc
@@ -20,41 +20,41 @@ pmclass PCCMETHOD_Test dynpmc provides hash {
METHOD test_method()
{
UNUSED(SELF);
- Parrot_io_printf(interp, "test_method\n");
+ Parrot_io_printf(INTERP, "test_method\n");
}
METHOD test_method0(int a1)
{
UNUSED(SELF);
- Parrot_io_printf(interp, "test_method0\n");
- Parrot_io_printf(interp, "%d\n", a1);
+ Parrot_io_printf(INTERP, "test_method0\n");
+ Parrot_io_printf(INTERP, "%d\n", a1);
}
METHOD test_method1(int a1, int a2, int a3, int a4, int a5, int a6)
{
UNUSED(SELF);
- Parrot_io_printf(interp, "test_method1\n");
- Parrot_io_printf(interp, "%d,%d,%d,%d,%d,%d\n", a1, a2, a3, a4, a5, a6);
+ Parrot_io_printf(INTERP, "test_method1\n");
+ Parrot_io_printf(INTERP, "%d,%d,%d,%d,%d,%d\n", a1, a2, a3, a4, a5, a6);
}
METHOD test_method2(int a1 :optional, int a1o :opt_flag,
PMC *slurpy_pos :slurpy)
{
- STRING *kevin = CONST_STRING(interp, "KEVIN");
+ STRING *kevin = CONST_STRING(INTERP, "KEVIN");
UNUSED(SELF);
- Parrot_io_printf(interp, "test_method2\n");
- Parrot_io_printf(interp, "%d, %d, %Ss %Ss\n", a1, a1o,
- VTABLE_name(interp, slurpy_pos),
- VTABLE_get_repr(interp, slurpy_pos));
+ Parrot_io_printf(INTERP, "test_method2\n");
+ Parrot_io_printf(INTERP, "%d, %d, %Ss %Ss\n", a1, a1o,
+ VTABLE_name(INTERP, slurpy_pos),
+ VTABLE_get_repr(INTERP, slurpy_pos));
RETURN(int 1000, STRING *kevin);
}
METHOD test_method3(PMC *a1 :named("a1name"), PMC *a2 :named("a2name"))
{
UNUSED(SELF);
- Parrot_io_printf(interp, "test_method3\n");
- Parrot_io_printf(interp, "%Ps, %Ps\n", a1, a2);
+ Parrot_io_printf(INTERP, "test_method3\n");
+ Parrot_io_printf(INTERP, "%Ps, %Ps\n", a1, a2);
}
METHOD test_method4(int george :optional, int g_f :opt_flag,
@@ -65,7 +65,7 @@ pmclass PCCMETHOD_Test dynpmc provides hash {
UNUSED(g_f);
UNUSED(slurpy_pos);
UNUSED(slurpy_named);
- Parrot_io_printf(interp, "test_method4\n");
+ Parrot_io_printf(INTERP, "test_method4\n");
}
}
View
20 src/dynpmc/subproxy.pmc
@@ -34,22 +34,22 @@ pmclass SubProxy dynpmc extends Sub auto_attrs {
Parrot_Sub_attributes *rsub, *my_sub;
if (!key)
- Parrot_ex_throw_from_c_args(interp, NULL, 1, "SubProxy: no key");
+ Parrot_ex_throw_from_c_args(INTERP, NULL, 1, "SubProxy: no key");
- file = VTABLE_get_string(interp, key);
+ file = VTABLE_get_string(INTERP, key);
if (!file)
- Parrot_ex_throw_from_c_args(interp, NULL, 1, "SubProxy: no file");
+ Parrot_ex_throw_from_c_args(INTERP, NULL, 1, "SubProxy: no file");
- sub_pmc = key_next(interp, key);
+ sub_pmc = key_next(INTERP, key);
if (!sub_pmc)
- Parrot_ex_throw_from_c_args(interp, NULL, 1, "SubProxy: no sub");
+ Parrot_ex_throw_from_c_args(INTERP, NULL, 1, "SubProxy: no sub");
- Parrot_load_bytecode(interp, file);
- rsub_pmc = VTABLE_get_pmc_keyed(interp,
- interp->root_namespace, sub_pmc);
+ Parrot_load_bytecode(INTERP, file);
+ rsub_pmc = VTABLE_get_pmc_keyed(INTERP,
+ INTERP->root_namespace, sub_pmc);
- if (!VTABLE_defined(interp, rsub_pmc))
- Parrot_ex_throw_from_c_args(interp, NULL, 1,
+ if (!VTABLE_defined(INTERP, rsub_pmc))
+ Parrot_ex_throw_from_c_args(INTERP, NULL, 1,
"SubProxy: sub not found");
PObj_get_FLAGS(SELF) &= ~PObj_private0_FLAG;
View
7 src/oo.c
@@ -433,10 +433,9 @@ Parrot_oo_find_vtable_override_for_class(PARROT_INTERP,
ARGIN(PMC *classobj), ARGIN(STRING *name))
{
ASSERT_ARGS(Parrot_oo_find_vtable_override_for_class)
- Parrot_Class_attributes *class_info;
+ const Parrot_Class_attributes * const class_info = PARROT_CLASS(classobj);;
PARROT_ASSERT(PObj_is_class_TEST(classobj));
- class_info = PARROT_CLASS(classobj);
return VTABLE_get_pmc_keyed_str(interp, class_info->vtable_overrides, name);
}
@@ -802,8 +801,8 @@ static void
invalidate_all_caches(PARROT_INTERP)
{
ASSERT_ARGS(invalidate_all_caches)
- UINTVAL i;
- for (i = 1; i < (UINTVAL)interp->n_vtable_max; ++i)
+ int i;
+ for (i = 1; i < interp->n_vtable_max; ++i)
invalidate_type_caches(interp, i);
}
View
12 src/pmc/addrregistry.pmc
@@ -77,7 +77,7 @@ Returns true if the hash size is not zero.
Hash *hash;
const void *value;
- GET_ATTR_hash(interp, SELF, hash);
+ GET_ATTR_hash(INTERP, SELF, hash);
value = parrot_hash_get(INTERP, hash, key);
if (value)
@@ -89,15 +89,15 @@ Returns true if the hash size is not zero.
VTABLE INTVAL elements() {
const Hash *hash;
- GET_ATTR_hash(interp, SELF, hash);
+ GET_ATTR_hash(INTERP, SELF, hash);
return parrot_hash_size(INTERP, hash);
}
VTABLE INTVAL get_bool() {
const Hash *hash;
- GET_ATTR_hash(interp, SELF, hash);
+ GET_ATTR_hash(INTERP, SELF, hash);
return parrot_hash_size(INTERP, hash) != 0;
}
@@ -128,7 +128,7 @@ reaches 0, delete the entry.
Hash *hash;
UNUSED(value);
- GET_ATTR_hash(interp, SELF, hash);
+ GET_ATTR_hash(INTERP, SELF, hash);
oldval = parrot_hash_get(INTERP, hash, key);
@@ -140,15 +140,15 @@ reaches 0, delete the entry.
VTABLE void set_integer_keyed(PMC *key, INTVAL value) {
Hash *hash;
- GET_ATTR_hash(interp, SELF, hash);
+ GET_ATTR_hash(INTERP, SELF, hash);
parrot_hash_put(INTERP, hash, key, (void *)value);
}
VTABLE void delete_keyed(PMC *key) {
Hash *hash;
void *value;
- GET_ATTR_hash(interp, SELF, hash);
+ GET_ATTR_hash(INTERP, SELF, hash);
value = parrot_hash_get(INTERP, hash, key);
/* these casts look bad, but they avoid type punning warnings with -O */
View
36 src/pmc/arrayiterator.pmc
@@ -90,7 +90,7 @@ Defaults iteration mode to iterate from start.
VTABLE void init_pmc(PMC *array) {
- SET_ATTR_array(interp, SELF, array);
+ SET_ATTR_array(INTERP, SELF, array);
PObj_custom_mark_SET(SELF);
@@ -128,14 +128,14 @@ Marks the current idx/key and the aggregate as live.
PMC *array;
PMC *clone;
- GET_ATTR_array(interp, SELF, array);
- GET_ATTR_pos(interp, SELF, pos);
- GET_ATTR_reverse(interp, SELF, reverse);
+ GET_ATTR_array(INTERP, SELF, array);
+ GET_ATTR_pos(INTERP, SELF, pos);
+ GET_ATTR_reverse(INTERP, SELF, reverse);
clone = Parrot_pmc_new_init(INTERP, enum_class_ArrayIterator, array);
- SET_ATTR_pos(interp, clone, pos);
- SET_ATTR_reverse(interp, clone, reverse);
+ SET_ATTR_pos(INTERP, clone, pos);
+ SET_ATTR_reverse(INTERP, clone, reverse);
return clone;
}
@@ -167,15 +167,15 @@ Returns the number of remaining elements in the array.
VTABLE INTVAL elements() {
INTVAL reverse, pos, length;
- GET_ATTR_reverse(interp, SELF, reverse);
+ GET_ATTR_reverse(INTERP, SELF, reverse);
if (reverse) {
- GET_ATTR_pos(interp, SELF, pos);
+ GET_ATTR_pos(INTERP, SELF, pos);
return pos;
}
else {
- GET_ATTR_length(interp, SELF, length);
- GET_ATTR_pos(interp, SELF, pos);
+ GET_ATTR_length(INTERP, SELF, length);
+ GET_ATTR_pos(INTERP, SELF, pos);
return length - pos;
}
}
@@ -201,18 +201,18 @@ Reset the Iterator. C<value> must be one of
PMC *array;
if (value == ITERATE_FROM_START) {
- GET_ATTR_array(interp, SELF, array);
- SET_ATTR_reverse(interp, SELF, 0);
- SET_ATTR_pos(interp, SELF, 0);
- SET_ATTR_length(interp, SELF, VTABLE_elements(INTERP, array));
+ GET_ATTR_array(INTERP, SELF, array);
+ SET_ATTR_reverse(INTERP, SELF, 0);
+ SET_ATTR_pos(INTERP, SELF, 0);
+ SET_ATTR_length(INTERP, SELF, VTABLE_elements(INTERP, array));
}
else if (value == ITERATE_FROM_END) {
INTVAL element;
- GET_ATTR_array(interp, SELF, array);
+ GET_ATTR_array(INTERP, SELF, array);
element = VTABLE_elements(INTERP, array);
- SET_ATTR_reverse(interp, SELF, 1);
- SET_ATTR_length(interp, SELF, element);
- SET_ATTR_pos(interp, SELF, element);
+ SET_ATTR_reverse(INTERP, SELF, 1);
+ SET_ATTR_length(INTERP, SELF, element);
+ SET_ATTR_pos(INTERP, SELF, element);
}
else
Parrot_ex_throw_from_c_args(INTERP, NULL, EXCEPTION_INVALID_OPERATION,
View
56 src/pmc/bigint.pmc
@@ -1183,7 +1183,7 @@ Decrements the integer.
MULTI PMC *add(Integer value, PMC *dest) {
dest = Parrot_pmc_new(INTERP, VTABLE_type(INTERP, SELF));
- bigint_add_bigint_int(INTERP, SELF, VTABLE_get_integer(interp, value), dest);
+ bigint_add_bigint_int(INTERP, SELF, VTABLE_get_integer(INTERP, value), dest);
return dest;
}
@@ -1192,7 +1192,7 @@ Decrements the integer.
Parrot_ex_throw_from_c_args(INTERP, NULL,
EXCEPTION_INTERNAL_NOT_IMPLEMENTED,
"BigInt: no multiple dispatch variant 'add' for %Ss",
- VTABLE_name(interp, value));
+ VTABLE_name(INTERP, value));
}
VTABLE PMC *add_int(INTVAL value, PMC *dest) {
@@ -1207,14 +1207,14 @@ Decrements the integer.
}
MULTI void i_add(Integer value) {
- bigint_add_bigint_int(INTERP, SELF, VTABLE_get_integer(interp, value), SELF);
+ bigint_add_bigint_int(INTERP, SELF, VTABLE_get_integer(INTERP, value), SELF);
}
MULTI void i_add(DEFAULT value) {
Parrot_ex_throw_from_c_args(INTERP, NULL,
EXCEPTION_INTERNAL_NOT_IMPLEMENTED,
"BigInt: no multiple dispatch variant 'i_add' for %Ss",
- VTABLE_name(interp, value));
+ VTABLE_name(INTERP, value));
}
VTABLE void i_add_int(INTVAL value) {
@@ -1239,7 +1239,7 @@ Decrements the integer.
MULTI PMC *subtract(Integer value, PMC *dest) {
dest = Parrot_pmc_new(INTERP, VTABLE_type(INTERP, SELF));
- bigint_sub_bigint_int(INTERP, SELF, VTABLE_get_integer(interp, value), dest);
+ bigint_sub_bigint_int(INTERP, SELF, VTABLE_get_integer(INTERP, value), dest);
return dest;
}
@@ -1248,7 +1248,7 @@ Decrements the integer.
Parrot_ex_throw_from_c_args(INTERP, NULL,
EXCEPTION_INTERNAL_NOT_IMPLEMENTED,
"BigInt: no multiple dispatch variant 'subtract' for %Ss",
- VTABLE_name(interp, value));
+ VTABLE_name(INTERP, value));
}
VTABLE PMC *subtract_int(INTVAL value, PMC *dest) {
@@ -1263,14 +1263,14 @@ Decrements the integer.
}
MULTI void i_subtract(Integer value) {
- bigint_sub_bigint_int(INTERP, SELF, VTABLE_get_integer(interp, value), SELF);
+ bigint_sub_bigint_int(INTERP, SELF, VTABLE_get_integer(INTERP, value), SELF);
}
MULTI void i_subtract(DEFAULT value) {
Parrot_ex_throw_from_c_args(INTERP, NULL,
EXCEPTION_INTERNAL_NOT_IMPLEMENTED,
"BigInt: no multiple dispatch variant 'i_subtract' for %Ss",
- VTABLE_name(interp, value));
+ VTABLE_name(INTERP, value));
}
VTABLE void i_subtract_int(INTVAL value) {
@@ -1295,7 +1295,7 @@ Decrements the integer.
MULTI PMC *multiply(Integer value, PMC *dest) {
dest = Parrot_pmc_new(INTERP, VTABLE_type(INTERP, SELF));
- bigint_mul_bigint_int(INTERP, SELF, VTABLE_get_integer(interp, value), dest);
+ bigint_mul_bigint_int(INTERP, SELF, VTABLE_get_integer(INTERP, value), dest);
return dest;
}
@@ -1304,7 +1304,7 @@ Decrements the integer.
Parrot_ex_throw_from_c_args(INTERP, NULL,
EXCEPTION_INTERNAL_NOT_IMPLEMENTED,
"BigInt: no multiple dispatch variant 'multiply' for %Ss",
- VTABLE_name(interp, value));
+ VTABLE_name(INTERP, value));
}
VTABLE PMC *multiply_int(INTVAL value, PMC *dest) {
@@ -1318,13 +1318,13 @@ Decrements the integer.
bigint_mul_bigint(INTERP, SELF, value, SELF);
}
MULTI void i_multiply(Integer value) {
- bigint_mul_bigint_int(INTERP, SELF, VTABLE_get_integer(interp, value), SELF);
+ bigint_mul_bigint_int(INTERP, SELF, VTABLE_get_integer(INTERP, value), SELF);
}
MULTI void i_multiply(DEFAULT value) {
Parrot_ex_throw_from_c_args(INTERP, NULL,
EXCEPTION_INTERNAL_NOT_IMPLEMENTED,
"BigInt: no multiple dispatch variant 'i_multiply' for %Ss",
- VTABLE_name(interp, value));
+ VTABLE_name(INTERP, value));
}
VTABLE void i_multiply_int(INTVAL value) {
@@ -1358,7 +1358,7 @@ Decrements the integer.
MULTI PMC *divide(Integer value, PMC *dest) {
dest = Parrot_pmc_new(INTERP, VTABLE_type(INTERP, SELF));
- bigint_div_bigint_int(INTERP, SELF, VTABLE_get_integer(interp, value), dest);
+ bigint_div_bigint_int(INTERP, SELF, VTABLE_get_integer(INTERP, value), dest);
return dest;
}
@@ -1367,7 +1367,7 @@ Decrements the integer.
Parrot_ex_throw_from_c_args(INTERP, NULL,
EXCEPTION_INTERNAL_NOT_IMPLEMENTED,
"BigInt: no multiple dispatch variant 'divide' for %Ss",
- VTABLE_name(interp, value));
+ VTABLE_name(INTERP, value));
}
VTABLE PMC *divide_int(INTVAL value, PMC *dest) {
@@ -1381,13 +1381,13 @@ Decrements the integer.
bigint_div_bigint(INTERP, SELF, value, SELF);
}
MULTI void i_divide(Integer value) {
- bigint_div_bigint_int(INTERP, SELF, VTABLE_get_integer(interp, value), SELF);
+ bigint_div_bigint_int(INTERP, SELF, VTABLE_get_integer(INTERP, value), SELF);
}
MULTI void i_divide(DEFAULT value) {
Parrot_ex_throw_from_c_args(INTERP, NULL,
EXCEPTION_INTERNAL_NOT_IMPLEMENTED,
"BigInt: no multiple dispatch variant 'i_divide' for %Ss",
- VTABLE_name(interp, value));
+ VTABLE_name(INTERP, value));
}
VTABLE void i_divide_int(INTVAL value) {
@@ -1404,7 +1404,7 @@ Decrements the integer.
MULTI PMC *floor_divide(Integer value, PMC *dest) {
dest = Parrot_pmc_new(INTERP, VTABLE_type(INTERP, SELF));
- bigint_fdiv_bigint_int(INTERP, SELF, VTABLE_get_integer(interp, value), dest);
+ bigint_fdiv_bigint_int(INTERP, SELF, VTABLE_get_integer(INTERP, value), dest);
return dest;
}
@@ -1413,7 +1413,7 @@ Decrements the integer.
Parrot_ex_throw_from_c_args(INTERP, NULL,
EXCEPTION_INTERNAL_NOT_IMPLEMENTED,
"BigInt: no multiple dispatch variant 'floor_divide' for %Ss",
- VTABLE_name(interp, value));
+ VTABLE_name(INTERP, value));
}
VTABLE PMC *floor_divide_int(INTVAL value, PMC *dest) {
@@ -1428,14 +1428,14 @@ Decrements the integer.
}
MULTI void i_floor_divide(Integer value) {
- bigint_fdiv_bigint_int(INTERP, SELF, VTABLE_get_integer(interp, value), SELF);
+ bigint_fdiv_bigint_int(INTERP, SELF, VTABLE_get_integer(INTERP, value), SELF);
}
MULTI void i_floor_divide(DEFAULT value) {
Parrot_ex_throw_from_c_args(INTERP, NULL,
EXCEPTION_INTERNAL_NOT_IMPLEMENTED,
"BigInt: no multiple dispatch variant 'i_floor_divide' for %Ss",
- VTABLE_name(interp, value));
+ VTABLE_name(INTERP, value));
}
VTABLE void i_floor_divide_int(INTVAL value) {
@@ -1452,7 +1452,7 @@ Decrements the integer.
MULTI PMC *modulus(Integer value, PMC *dest) {
dest = Parrot_pmc_new(INTERP, VTABLE_type(INTERP, SELF));
- bigint_mod_bigint_int(INTERP, SELF, VTABLE_get_integer(interp, value), dest);
+ bigint_mod_bigint_int(INTERP, SELF, VTABLE_get_integer(INTERP, value), dest);
return dest;
}
@@ -1461,50 +1461,50 @@ Decrements the integer.
Parrot_ex_throw_from_c_args(INTERP, NULL,
EXCEPTION_INTERNAL_NOT_IMPLEMENTED,
"BigInt: no multiple dispatch variant 'modulus' for %Ss",
- VTABLE_name(interp, value));
+ VTABLE_name(INTERP, value));
}
MULTI void i_modulus(BigInt value) {
bigint_mod_bigint(INTERP, SELF, value, SELF);
}
MULTI void i_modulus(Integer value) {
- bigint_mod_bigint_int(INTERP, SELF, VTABLE_get_integer(interp, value), SELF);
+ bigint_mod_bigint_int(INTERP, SELF, VTABLE_get_integer(INTERP, value), SELF);
}
MULTI void i_modulus(DEFAULT value) {
Parrot_ex_throw_from_c_args(INTERP, NULL,
EXCEPTION_INTERNAL_NOT_IMPLEMENTED,
"BigInt: no multiple dispatch variant 'i_modulus' for %Ss",
- VTABLE_name(interp, value));
+ VTABLE_name(INTERP, value));
}
MULTI INTVAL cmp(BigInt value) {
return bigint_cmp(INTERP, SELF, value);
}
MULTI INTVAL cmp(Integer value) {
- return bigint_cmp_int(INTERP, SELF, VTABLE_get_integer(interp, value));
+ return bigint_cmp_int(INTERP, SELF, VTABLE_get_integer(INTERP, value));
}
MULTI INTVAL cmp(DEFAULT value) {
Parrot_ex_throw_from_c_args(INTERP, NULL,
EXCEPTION_INTERNAL_NOT_IMPLEMENTED,
"BigInt: no multiple dispatch variant 'cmp' for %Ss",
- VTABLE_name(interp, value));
+ VTABLE_name(INTERP, value));
}
MULTI INTVAL is_equal(BigInt value) {
return bigint_cmp(INTERP, SELF, value) == 0;
}
MULTI INTVAL is_equal(Integer value) {
- return bigint_cmp_int(INTERP, SELF, VTABLE_get_integer(interp, value)) == 0;
+ return bigint_cmp_int(INTERP, SELF, VTABLE_get_integer(INTERP, value)) == 0;
}
MULTI INTVAL is_equal(DEFAULT value) {
Parrot_ex_throw_from_c_args(INTERP, NULL,
EXCEPTION_INTERNAL_NOT_IMPLEMENTED,
"BigInt: no multiple dispatch variant 'is_equal' for %Ss",
- VTABLE_name(interp, value));
+ VTABLE_name(INTERP, value));
}
/*
View
56 src/pmc/bignum.pmc
@@ -1442,7 +1442,7 @@ Trunc the BigNum to an BigInt.
#if PARROT_BIGNUM_CAN_BIGINT
return bignum_get_bigint(INTERP, SELF);
#else
- Parrot_ex_throw_from_c_args(interp, NULL, EXCEPTION_LIBRARY_ERROR,
+ Parrot_ex_throw_from_c_args(INTERP, NULL, EXCEPTION_LIBRARY_ERROR,
"no bigint support in bignum");
#endif
}
@@ -1488,27 +1488,27 @@ appended.
VTABLE STRING *get_string() {
char *s = bignum_get_string(INTERP, SELF, 10);
STRING *ps = Parrot_str_new(INTERP, s, 0);
- mem_gc_free(interp, s);
+ mem_gc_free(INTERP, s);
return ps;
}
VTABLE STRING *get_string_keyed_int(INTVAL base) {
char *s = bignum_get_string(INTERP, SELF, base);
STRING *ps = Parrot_str_new(INTERP, s, 0);
- mem_gc_free(interp, s);
+ mem_gc_free(INTERP, s);
return ps;
}
VTABLE STRING *get_string_keyed_int_int(INTVAL base, INTVAL digits) {
char *s = bignum_get_string_size(INTERP, SELF, base, digits);
STRING *ps = Parrot_str_new(INTERP, s, 0);
- mem_gc_free(interp, s);
+ mem_gc_free(INTERP, s);
return ps;
}
VTABLE STRING *get_repr() {
STRING *s = SELF.get_string();
- return Parrot_str_concat(INTERP, s, Parrot_str_new(interp, "N", 1));
+ return Parrot_str_concat(INTERP, s, Parrot_str_new(INTERP, "N", 1));
}
/*
@@ -1556,15 +1556,15 @@ Decrement the BigNum by 1.0.
MULTI PMC *add(Integer value, PMC *dest) {
dest = Parrot_pmc_new(INTERP, SELF->vtable->base_type);
- bignum_add_bignum_int(INTERP, SELF, VTABLE_get_integer(interp, value), dest);
+ bignum_add_bignum_int(INTERP, SELF, VTABLE_get_integer(INTERP, value), dest);
return dest;
}
MULTI PMC *add(DEFAULT value, PMC *dest) {
Parrot_ex_throw_from_c_args(INTERP, NULL,
EXCEPTION_INTERNAL_NOT_IMPLEMENTED,
"BigNum: no multiple dispatch variant 'add' for %Ss",
- VTABLE_name(interp, value));
+ VTABLE_name(INTERP, value));
}
VTABLE PMC *add_int(INTVAL value, PMC *dest) {
@@ -1590,7 +1590,7 @@ Decrement the BigNum by 1.0.
Parrot_ex_throw_from_c_args(INTERP, NULL,
EXCEPTION_INTERNAL_NOT_IMPLEMENTED,
"BigNum: no multiple dispatch variant 'i_add' for %Ss",
- VTABLE_name(interp, value));
+ VTABLE_name(INTERP, value));
}
VTABLE void i_add_int(INTVAL value) {
@@ -1619,15 +1619,15 @@ Decrement the BigNum by 1.0.
MULTI PMC *subtract(Integer value, PMC *dest) {
dest = Parrot_pmc_new(INTERP, VTABLE_type(INTERP, SELF));
- bignum_sub_bignum_int(INTERP, SELF, VTABLE_get_integer(interp, value), dest);
+ bignum_sub_bignum_int(INTERP, SELF, VTABLE_get_integer(INTERP, value), dest);
return dest;
}
MULTI PMC *subtract(DEFAULT value, PMC *dest) {
Parrot_ex_throw_from_c_args(INTERP, NULL,
EXCEPTION_INTERNAL_NOT_IMPLEMENTED,
"BigNum: no multiple dispatch variant 'subtract' for %Ss",
- VTABLE_name(interp, value));
+ VTABLE_name(INTERP, value));
}
VTABLE PMC *subtract_int(INTVAL value, PMC *dest) {
@@ -1653,7 +1653,7 @@ Decrement the BigNum by 1.0.
Parrot_ex_throw_from_c_args(INTERP, NULL,
EXCEPTION_INTERNAL_NOT_IMPLEMENTED,
"BigNum: no multiple dispatch variant 'i_subtract' for %Ss",
- VTABLE_name(interp, value));
+ VTABLE_name(INTERP, value));
}
VTABLE void i_subtract_int(INTVAL value) {
@@ -1682,15 +1682,15 @@ Decrement the BigNum by 1.0.
MULTI PMC *multiply(Integer value, PMC *dest) {
dest = Parrot_pmc_new(INTERP, SELF->vtable->base_type);
- bignum_mul_bignum_int(INTERP, SELF, VTABLE_get_integer(interp, value), dest);
+ bignum_mul_bignum_int(INTERP, SELF, VTABLE_get_integer(INTERP, value), dest);
return dest;
}
MULTI PMC *multiply(DEFAULT value, PMC *dest) {
Parrot_ex_throw_from_c_args(INTERP, NULL,
EXCEPTION_INTERNAL_NOT_IMPLEMENTED,
"BigNum: no multiple dispatch variant 'multiply' for %Ss",
- VTABLE_name(interp, value));
+ VTABLE_name(INTERP, value));
}
VTABLE PMC *multiply_int(INTVAL value, PMC *dest) {
@@ -1709,14 +1709,14 @@ Decrement the BigNum by 1.0.
}
MULTI void i_multiply(Integer value) {
- bignum_mul_bignum_int(INTERP, SELF, VTABLE_get_integer(interp, value), SELF);
+ bignum_mul_bignum_int(INTERP, SELF, VTABLE_get_integer(INTERP, value), SELF);
}
MULTI void i_multiply(DEFAULT value) {
Parrot_ex_throw_from_c_args(INTERP, NULL,
EXCEPTION_INTERNAL_NOT_IMPLEMENTED,
"BigNum: no multiple dispatch variant 'i_multiply' for %Ss",
- VTABLE_name(interp, value));
+ VTABLE_name(INTERP, value));
}
VTABLE void i_multiply_int(INTVAL value) {
@@ -1768,15 +1768,15 @@ TODO: Only supports Integer values for now.
MULTI PMC *divide(Integer value, PMC *dest) {
dest = Parrot_pmc_new(INTERP, VTABLE_type(INTERP, SELF));
- bignum_div_bignum_int(INTERP, SELF, VTABLE_get_integer(interp, value), dest);
+ bignum_div_bignum_int(INTERP, SELF, VTABLE_get_integer(INTERP, value), dest);
return dest;
}
MULTI PMC *divide(DEFAULT value, PMC *dest) {
Parrot_ex_throw_from_c_args(INTERP, NULL,
EXCEPTION_INTERNAL_NOT_IMPLEMENTED,
"BigNum: no multiple dispatch variant 'divide' for %Ss",
- VTABLE_name(interp, value));
+ VTABLE_name(INTERP, value));
}
VTABLE PMC *divide_int(INTVAL value, PMC *dest) {
@@ -1797,16 +1797,16 @@ TODO: Only supports Integer values for now.
bignum_div_bignum(INTERP, SELF, value, SELF);
}
MULTI void i_divide(Integer value) {
- bignum_div_bignum_int(INTERP, SELF, VTABLE_get_integer(interp, value), SELF);
+ bignum_div_bignum_int(INTERP, SELF, VTABLE_get_integer(INTERP, value), SELF);
}
MULTI void i_divide(Float value) {
- bignum_div_bignum_float(INTERP, SELF, VTABLE_get_integer(interp, value), SELF);
+ bignum_div_bignum_float(INTERP, SELF, VTABLE_get_integer(INTERP, value), SELF);
}
MULTI void i_divide(DEFAULT value) {
Parrot_ex_throw_from_c_args(INTERP, NULL,
EXCEPTION_INTERNAL_NOT_IMPLEMENTED,
"BigNum: no multiple dispatch variant 'i_divide' for %Ss",
- VTABLE_name(interp, value));
+ VTABLE_name(INTERP, value));
}
VTABLE void i_divide_int(INTVAL value) {
@@ -1831,15 +1831,15 @@ TODO: Only supports Integer values for now.
MULTI PMC *floor_divide(Integer value, PMC *dest) {
dest = Parrot_pmc_new(INTERP, VTABLE_type(INTERP, SELF));
- bignum_fdiv_bignum_int(INTERP, SELF, VTABLE_get_integer(interp, value), dest);
+ bignum_fdiv_bignum_int(INTERP, SELF, VTABLE_get_integer(INTERP, value), dest);
return dest;
}
MULTI PMC *floor_divide(DEFAULT value, PMC *dest) {
Parrot_ex_throw_from_c_args(INTERP, NULL,
EXCEPTION_INTERNAL_NOT_IMPLEMENTED,
"BigNum: no multiple dispatch variant 'floor_divide' for %Ss",
- VTABLE_name(interp, value));
+ VTABLE_name(INTERP, value));
}
VTABLE PMC *floor_divide_int(INTVAL value, PMC *dest) {
@@ -1854,14 +1854,14 @@ TODO: Only supports Integer values for now.
}
MULTI void i_floor_divide(Integer value) {
- bignum_fdiv_bignum_int(INTERP, SELF, VTABLE_get_integer(interp, value), SELF);
+ bignum_fdiv_bignum_int(INTERP, SELF, VTABLE_get_integer(INTERP, value), SELF);
}
MULTI void i_floor_divide(DEFAULT value) {
Parrot_ex_throw_from_c_args(INTERP, NULL,
EXCEPTION_INTERNAL_NOT_IMPLEMENTED,
"BigNum: no multiple dispatch variant 'i_floor_divide' for %Ss",
- VTABLE_name(interp, value));
+ VTABLE_name(INTERP, value));
}
VTABLE void i_floor_divide_int(INTVAL value) {
@@ -1881,14 +1881,14 @@ TODO: Only supports Integer values for now.
}
MULTI INTVAL cmp(Integer value) {
- return bignum_cmp_int(INTERP, SELF, VTABLE_get_integer(interp, value));
+ return bignum_cmp_int(INTERP, SELF, VTABLE_get_integer(INTERP, value));
}
MULTI INTVAL cmp(DEFAULT value) {
Parrot_ex_throw_from_c_args(INTERP, NULL,
EXCEPTION_INTERNAL_NOT_IMPLEMENTED,
"BigNum: no multiple dispatch variant 'cmp' for %Ss",
- VTABLE_name(interp, value));
+ VTABLE_name(INTERP, value));
}
/*
@@ -1904,14 +1904,14 @@ TODO: Only supports Integer values for now.
}
MULTI INTVAL is_equal(Integer value) {
- return bignum_cmp_int(INTERP, SELF, VTABLE_get_integer(interp, value)) == 0;
+ return bignum_cmp_int(INTERP, SELF, VTABLE_get_integer(INTERP, value)) == 0;
}
MULTI INTVAL is_equal(DEFAULT value) {
Parrot_ex_throw_from_c_args(INTERP, NULL,
EXCEPTION_INTERNAL_NOT_IMPLEMENTED,
"BigNum: no multiple dispatch variant 'is_equal' for %Ss",
- VTABLE_name(interp, value));
+ VTABLE_name(INTERP, value));
}
/*
View
46 src/pmc/callcontext.pmc
@@ -539,13 +539,13 @@ Mark any referenced strings and PMCs.
PMC * const p = bp_ps.regs_p[-1L-(i)];
/* Original code from CTX_REG_PMC */
if (p)
- Parrot_gc_mark_PMC_alive(interp, p);
+ Parrot_gc_mark_PMC_alive(INTERP, p);
}
for (i = 0; i < n_regs_used[REGNO_STR]; ++i) {
STRING * const s = bp_ps.regs_s[i];
if (s)
- Parrot_gc_mark_STRING_alive(interp, s);
+ Parrot_gc_mark_STRING_alive(INTERP, s);
}
}
@@ -589,7 +589,7 @@ stored.)
}
parrot_hash_destroy(INTERP, hash);
- SET_ATTR_hash(interp, SELF, NULL);
+ SET_ATTR_hash(INTERP, SELF, NULL);
}
}
@@ -736,7 +736,7 @@ CallContext.
GET_ATTR_positionals(INTERP, SELF, c);
GET_ATTR_num_positionals(INTERP, SELF, num_positionals);
- type_tuple = Parrot_pmc_new_init_int(interp,
+ type_tuple = Parrot_pmc_new_init_int(INTERP,
enum_class_FixedIntegerArray, num_positionals);
for (i = 0; i < num_positionals; ++i) {
@@ -749,15 +749,15 @@ CallContext.
case PMCCELL:
type = PMC_IS_NULL(c[i].u.p)
? (INTVAL) enum_type_PMC
- : VTABLE_type(interp, c[i].u.p);
+ : VTABLE_type(INTERP, c[i].u.p);
break;
default:
- Parrot_ex_throw_from_c_args(interp, NULL,
+ Parrot_ex_throw_from_c_args(INTERP, NULL,
EXCEPTION_INVALID_OPERATION,
"Multiple Dispatch: invalid argument type!");
}
- VTABLE_set_integer_keyed_int(interp, type_tuple, i, type);
+ VTABLE_set_integer_keyed_int(INTERP, type_tuple, i, type);
}
SET_ATTR_type_tuple(INTERP, SELF, type_tuple);
@@ -931,7 +931,7 @@ return current Namespace
INTVAL num_pos, allocated_positionals;
GET_ATTR_num_positionals(INTERP, SELF, num_pos);
- GET_ATTR_allocated_positionals(interp, SELF, allocated_positionals);
+ GET_ATTR_allocated_positionals(INTERP, SELF, allocated_positionals);
if (num_pos + 1 > allocated_positionals)
ensure_positionals_storage(INTERP, SELF, num_pos + 1);
@@ -973,7 +973,7 @@ return current Namespace
INTVAL num_pos, allocated_positionals;
GET_ATTR_num_positionals(INTERP, SELF, num_pos);
- GET_ATTR_allocated_positionals(interp, SELF, allocated_positionals);
+ GET_ATTR_allocated_positionals(INTERP, SELF, allocated_positionals);
if (num_pos + 1 > allocated_positionals)
ensure_positionals_storage(INTERP, SELF, num_pos + 1);
@@ -991,7 +991,7 @@ return current Namespace
VTABLE void unshift_pmc(PMC *value) {
Pcc_cell *cells;
- INTVAL size = STATICSELF.elements();
+ const INTVAL size = STATICSELF.elements();
INTVAL i;
ensure_positionals_storage(INTERP, SELF, size + 1);
@@ -1012,7 +1012,7 @@ return current Namespace
INTVAL i;
if (size < 1)
- Parrot_ex_throw_from_c_args(interp, NULL,
+ Parrot_ex_throw_from_c_args(INTERP, NULL,
EXCEPTION_INVALID_OPERATION,
"Cannot shift PMC from empty CallContext");
@@ -1033,7 +1033,7 @@ return current Namespace
INTVAL i;
if (size < 1)
- Parrot_ex_throw_from_c_args(interp, NULL,
+ Parrot_ex_throw_from_c_args(INTERP, NULL,
EXCEPTION_INVALID_OPERATION,
"Cannot shift PMC from empty CallContext");
@@ -1460,48 +1460,48 @@ sub, or for the point of the call a level deeper for the rest.
*/
METHOD backtrace(PMC *resume :optional, INTVAL has_resume :opt_flag) {
- PMC *result = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
+ PMC *result = Parrot_pmc_new(INTERP, enum_class_ResizablePMCArray);
PMC *cur_ctx = SELF;
Parrot_Continuation_attributes * const cont = has_resume ? PMC_cont(resume) : NULL;
/* Get starting context, then loop over them. */
while (cur_ctx) {
- PMC * const frame = Parrot_pmc_new(interp, enum_class_Hash);
+ PMC * const frame = Parrot_pmc_new(INTERP, enum_class_Hash);
PMC *annotations = NULL;
Parrot_Sub_attributes *sub;
/* Get sub and put it in the hash. */
- PMC *sub_pmc = Parrot_pcc_get_sub(interp, cur_ctx);
+ PMC *sub_pmc = Parrot_pcc_get_sub(INTERP, cur_ctx);
if (!sub_pmc)
sub_pmc = PMCNULL;
- VTABLE_set_pmc_keyed_str(interp, frame, CONST_STRING(interp, "sub"), sub_pmc);
+ VTABLE_set_pmc_keyed_str(INTERP, frame, CONST_STRING(INTERP, "sub"), sub_pmc);
/* Look up any annotations and put them in the hash. */
if (!PMC_IS_NULL(sub_pmc)) {
- PMC_get_sub(interp, sub_pmc, sub);
+ PMC_get_sub(INTERP, sub_pmc, sub);
if (sub->seg->annotations) {
PackFile_ByteCode *seg = sub->seg;
opcode_t *pc = cont && cur_ctx == cont->to_ctx
? cont->address
- : Parrot_pcc_get_pc(interp, cur_ctx);
+ : Parrot_pcc_get_pc(INTERP, cur_ctx);
- annotations = PackFile_Annotations_lookup(interp,
+ annotations = PackFile_Annotations_lookup(INTERP,
seg->annotations, pc - seg->base.data,
NULL);
}
}
if (!annotations)
- annotations = Parrot_pmc_new(interp, enum_class_Hash);
+ annotations = Parrot_pmc_new(INTERP, enum_class_Hash);
- VTABLE_set_pmc_keyed_str(interp, frame, CONST_STRING(interp, "annotations"), annotations);
+ VTABLE_set_pmc_keyed_str(INTERP, frame, CONST_STRING(INTERP, "annotations"), annotations);
/* Push frame and go to next caller. */
- VTABLE_push_pmc(interp, result, frame);
- cur_ctx = Parrot_pcc_get_caller_ctx(interp, cur_ctx);
+ VTABLE_push_pmc(INTERP, result, frame);
+ cur_ctx = Parrot_pcc_get_caller_ctx(INTERP, cur_ctx);
}
RETURN(PMC *result);
View
36 src/pmc/complex.pmc
@@ -309,31 +309,31 @@ Creates an identical copy of the complex number.
}
VTABLE void init_pmc(PMC *initializer) {
- const INTVAL arg_type = VTABLE_type(interp, initializer);
+ const INTVAL arg_type = VTABLE_type(INTERP, initializer);
SELF.init();
switch (arg_type) {
case enum_class_String:
- SELF.set_string_native(VTABLE_get_string(interp, initializer));
+ SELF.set_string_native(VTABLE_get_string(INTERP, initializer));
break;
case enum_class_FixedFloatArray:
case enum_class_ResizableFloatArray:
case enum_class_FixedIntegerArray:
case enum_class_ResizableIntegerArray:
- if (VTABLE_get_integer(interp, initializer) == 2) {
- const FLOATVAL re = VTABLE_get_number_keyed_int(interp, initializer, 0);
- const FLOATVAL im = VTABLE_get_number_keyed_int(interp, initializer, 1);
+ if (VTABLE_get_integer(INTERP, initializer) == 2) {
+ const FLOATVAL re = VTABLE_get_number_keyed_int(INTERP, initializer, 0);
+ const FLOATVAL im = VTABLE_get_number_keyed_int(INTERP, initializer, 1);
SET_ATTR_re(INTERP, SELF, re);
SET_ATTR_im(INTERP, SELF, im);
break;
}
/* else let it fall to default */
default:
- if (VTABLE_isa(interp, initializer, CONST_STRING(interp, "String"))) {
- STRING * const s = VTABLE_get_string(interp, initializer);
+ if (VTABLE_isa(INTERP, initializer, CONST_STRING(INTERP, "String"))) {
+ STRING * const s = VTABLE_get_string(INTERP, initializer);
SELF.set_string_native(s);
}
else {
- Parrot_ex_throw_from_c_args(interp, NULL,
+ Parrot_ex_throw_from_c_args(INTERP, NULL,
EXCEPTION_INVALID_OPERATION,
"Invalid Complex initializer");
}
@@ -480,14 +480,14 @@ Returns the requested number (real part for C<real> and imaginary for C<imag>).
GET_ATTR_im(INTERP, SELF, value);
}
else
- Parrot_ex_throw_from_c_args(interp, NULL,
+ Parrot_ex_throw_from_c_args(INTERP, NULL,
EXCEPTION_INVALID_OPERATION, "Complex: key is neither 'real' or 'imag'");
return value;
}
VTABLE PMC *get_pmc_keyed(PMC *key) {
- if (VTABLE_isa(interp, key, CONST_STRING(interp, "Integer"))) {
- const INTVAL i = VTABLE_get_integer(interp, key);
+ if (VTABLE_isa(INTERP, key, CONST_STRING(INTERP, "Integer"))) {
+ const INTVAL i = VTABLE_get_integer(INTERP, key);
return SELF.get_pmc_keyed_int(i);
}
else {
@@ -547,7 +547,7 @@ Set real or imag depending on key
GET_ATTR_im(INTERP, SELF, f);
break;
default:
- Parrot_ex_throw_from_c_args(interp, NULL,
+ Parrot_ex_throw_from_c_args(INTERP, NULL,
EXCEPTION_INVALID_OPERATION, "Complex: key must be 0 or 1");
}
return f;
@@ -562,7 +562,7 @@ Set real or imag depending on key
SET_ATTR_im(INTERP, SELF, v);
break;
default:
- Parrot_ex_throw_from_c_args(interp, NULL,
+ Parrot_ex_throw_from_c_args(INTERP, NULL,
EXCEPTION_INVALID_OPERATION, "Complex: key must be 0 or 1");
}
}
@@ -648,8 +648,8 @@ to C<value>.
}
VTABLE void set_number_keyed(PMC *key, FLOATVAL value) {
- if (VTABLE_isa(interp, key, CONST_STRING(interp, "Integer"))) {
- const INTVAL i = VTABLE_get_integer(interp, key);
+ if (VTABLE_isa(INTERP, key, CONST_STRING(INTERP, "Integer"))) {
+ const INTVAL i = VTABLE_get_integer(INTERP, key);
SELF.set_number_keyed_int(i, value);
}
else {
@@ -666,7 +666,7 @@ to C<value>.
SET_ATTR_im(INTERP, SELF, value);
}
else
- Parrot_ex_throw_from_c_args(interp, NULL,
+ Parrot_ex_throw_from_c_args(INTERP, NULL,
EXCEPTION_INVALID_OPERATION, "Complex: key is neither 'real' or 'imag'");
}
@@ -1861,12 +1861,12 @@ x ^ y = exp(y * ln x))
PMC *log;
PMC *dest = Parrot_pmc_new(INTERP, VTABLE_type(INTERP, SELF));
- Parrot_pcc_invoke_method_from_c_args(interp, SELF, CONST_STRING(interp, "ln"),
+ Parrot_pcc_invoke_method_from_c_args(INTERP, SELF, CONST_STRING(INTERP, "ln"),
"->P", &log);
l = VTABLE_multiply(INTERP, log, value, l);
- Parrot_pcc_invoke_method_from_c_args(interp, l, CONST_STRING(interp, "exp"),
+ Parrot_pcc_invoke_method_from_c_args(INTERP, l, CONST_STRING(INTERP, "exp"),
"->P", &dest);
RETURN(PMC *dest);
}
View
10 src/pmc/coroutine.pmc
@@ -152,8 +152,8 @@ Swaps the "context".
opcode_t *dest;
PackFile_ByteCode *wanted_seg;
opcode_t * const next_op = (opcode_t *)next;
- PMC * const signature = Parrot_pcc_get_signature(interp,
- CURRENT_CONTEXT(interp));
+ PMC * const signature = Parrot_pcc_get_signature(INTERP,
+ CURRENT_CONTEXT(INTERP));
if (Interp_trace_TEST(INTERP, PARROT_TRACE_SUB_CALL_FLAG))
print_sub_name(INTERP, SELF);
@@ -170,8 +170,8 @@ Swaps the "context".
PMC *ccont = INTERP->current_cont;
if (ccont == NEED_CONTINUATION) {
- ccont = pmc_new(interp, enum_class_Continuation);
- VTABLE_set_pointer(interp, ccont, next_op);
+ ccont = pmc_new(INTERP, enum_class_Continuation);
+ VTABLE_set_pointer(INTERP, ccont, next_op);
}
if (PObj_get_FLAGS(ccont) & SUB_FLAG_TAILCALL)
@@ -282,7 +282,7 @@ Swaps the "context".
CURRENT_CONTEXT(INTERP) = to_ctx;
}
- Parrot_pcc_set_signature(interp, CURRENT_CONTEXT(interp), signature);
+ Parrot_pcc_set_signature(INTERP, CURRENT_CONTEXT(INTERP), signature);
/* toggle address */
GET_ATTR_address(INTERP, SELF, dest);
View
154 src/pmc/default.pmc
@@ -356,9 +356,9 @@ With a null C<initializer>, calls C<init()>, else throws an exception.
if (PMC_IS_NULL(initializer))
SELF.init();
else
- Parrot_ex_throw_from_c_args(interp, NULL, EXCEPTION_ILL_INHERIT,
+ Parrot_ex_throw_from_c_args(INTERP, NULL, EXCEPTION_ILL_INHERIT,
"init_pmc() not implemented in class '%Ss'",
- caller(interp, SELF));
+ caller(INTERP, SELF));
}
/*
@@ -391,7 +391,7 @@ calls init().
/* Ensure no looping, as Parrot_pmc_new calls the instantiate vtable entry for
* classes. */
if (PObj_is_class_TEST(SELF))
- Parrot_ex_throw_from_c_args(interp, NULL, 1,
+ Parrot_ex_throw_from_c_args(INTERP, NULL, 1,
"All high-level classes should override instantiate");
if (!PMC_IS_NULL(init))
@@ -427,7 +427,7 @@ NULL PMC is returned.
VTABLE PMC *getprop(STRING *key) {
if (PMC_IS_NULL(PMC_metadata(SELF)))
- return check_get_std_props(interp, SELF, key);
+ return check_get_std_props(INTERP, SELF, key);
else
return VTABLE_get_pmc_keyed_str(INTERP, PMC_metadata(SELF), key);
}
@@ -688,7 +688,7 @@ Changes the PMC to a PMC of a new type
*/
VTABLE void morph(PMC* type) {
- Parrot_pmc_reuse(INTERP, SELF, VTABLE_get_integer(interp, type), 0);
+ Parrot_pmc_reuse(INTERP, SELF, VTABLE_get_integer(INTERP, type), 0);
}
/*
@@ -782,7 +782,7 @@ Default fallback. Performs a multiple dispatch call for 'is_equal'.
VTABLE INTVAL is_equal(PMC *value) {
INTVAL retval;
- Parrot_mmd_multi_dispatch_from_c_args(interp,
+ Parrot_mmd_multi_dispatch_from_c_args(INTERP,
"is_equal", "PP->I", SELF, value, &retval);
return retval;
@@ -800,7 +800,7 @@ Default fallback. Performs a multiple dispatch call for 'is_equal_num'.
VTABLE INTVAL is_equal_num(PMC *value) {
INTVAL retval;
- Parrot_mmd_multi_dispatch_from_c_args(interp,
+ Parrot_mmd_multi_dispatch_from_c_args(INTERP,
"is_equal_num", "PP->I", SELF, value, &retval);
return retval;
@@ -818,7 +818,7 @@ Default fallback. Performs a multiple dispatch call for 'is_equal'.
VTABLE INTVAL is_equal_string(PMC *value) {
INTVAL retval;
- Parrot_mmd_multi_dispatch_from_c_args(interp,
+ Parrot_mmd_multi_dispatch_from_c_args(INTERP,
"is_equal_string", "PP->I", SELF, value, &retval);
return retval;
@@ -952,10 +952,10 @@ true (1) is returned; otherwise, false (0) is returned.
if (PMC_IS_NULL(lookup))
return 0;
- pmc_name = VTABLE_get_string(interp, lookup);
+ pmc_name = VTABLE_get_string(INTERP, lookup);
if (!isa_hash)
- return Parrot_str_equal(interp, SELF->vtable->whoami, pmc_name);
+ return Parrot_str_equal(INTERP, SELF->vtable->whoami, pmc_name);
return parrot_hash_exists(INTERP, isa_hash, (void *)pmc_name);
}
@@ -975,7 +975,7 @@ true (1) is returned; otherwise, false (0) is returned.
VTABLE INTVAL isa(STRING *_class) {
const Hash * const isa_hash = SELF->vtable->isa_hash;
if (!isa_hash)
- return Parrot_str_equal(interp, SELF->vtable->whoami, _class);
+ return Parrot_str_equal(INTERP, SELF->vtable->whoami, _class);
return parrot_hash_exists(INTERP, isa_hash, (void *)_class);
}
@@ -991,16 +991,16 @@ Provides introspection of a specific piece of information about the PMC.
*/
VTABLE PMC *inspect_str(STRING *name) {
- if (Parrot_str_equal(interp, name, CONST_STRING(interp, "flags"))) {
- PMC *found = Parrot_pmc_new_init_int(interp, enum_class_Integer,
+ if (Parrot_str_equal(INTERP, name, CONST_STRING(INTERP, "flags"))) {
+ PMC *found = Parrot_pmc_new_init_int(INTERP, enum_class_Integer,
(INTVAL)PObj_get_FLAGS(SELF));
return found;
}
- else if (Parrot_str_equal(interp, name, CONST_STRING(interp, "mro"))) {
- return VTABLE_clone(interp, SELF->vtable->mro);
+ else if (Parrot_str_equal(INTERP, name, CONST_STRING(INTERP, "mro"))) {
+ return VTABLE_clone(INTERP, SELF->vtable->mro);
}
else
- Parrot_ex_throw_from_c_args(interp, NULL, EXCEPTION_INVALID_OPERATION,
+ Parrot_ex_throw_from_c_args(INTERP, NULL, EXCEPTION_INVALID_OPERATION,
"Unknown introspection value '%S'", name);
}
@@ -1015,11 +1015,11 @@ inspect_str.
*/
VTABLE PMC *inspect() {
- PMC * const metadata = Parrot_pmc_new(interp, enum_class_Hash);
- STRING * const flags_str = CONST_STRING(interp, "flags");
+ PMC * const metadata = Parrot_pmc_new(INTERP, enum_class_Hash);
+ STRING * const flags_str = CONST_STRING(INTERP, "flags");
- VTABLE_set_pmc_keyed_str(interp, metadata, flags_str,
- VTABLE_inspect_str(interp, SELF, flags_str));
+ VTABLE_set_pmc_keyed_str(INTERP, metadata, flags_str,
+ VTABLE_inspect_str(INTERP, SELF, flags_str));
return metadata;
}
@@ -1034,15 +1034,15 @@ Returns SELF. A PMC is its own class.
*/
VTABLE PMC *get_class() {
- PMC * const ns = VTABLE_get_namespace(interp, SELF);
+ PMC * const ns = VTABLE_get_namespace(INTERP, SELF);
PMC *_class = PMCNULL;
if (!PMC_IS_NULL(ns))
- _class = VTABLE_get_class(interp, ns);
+ _class = VTABLE_get_class(INTERP, ns);
if (PMC_IS_NULL(_class)) {
- const INTVAL type = VTABLE_type(interp, SELF);
- return Parrot_pmc_new_init_int(interp, enum_class_PMCProxy, type);
+ const INTVAL type = VTABLE_type(INTERP, SELF);
+ return Parrot_pmc_new_init_int(INTERP, enum_class_PMCProxy, type);
}
return _class;
@@ -1087,10 +1087,10 @@ Add class C<parent> to the list of our parents.
VTABLE void add_parent(PMC *parent) {
UNUSED(parent)
if (!PObj_is_class_TEST(SELF))
- Parrot_ex_throw_from_c_args(interp, NULL, 1,
+ Parrot_ex_throw_from_c_args(INTERP, NULL, 1,
"Only classes can be subclassed");
- Parrot_ex_throw_from_c_args(interp, NULL, 1,
+ Parrot_ex_throw_from_c_args(INTERP, NULL, 1,
"All classes should override add_parent");
}
@@ -1118,7 +1118,7 @@ Clones this PMC. By default, this just does a freeze and thaw.
*/
VTABLE PMC* clone() {
- return Parrot_thaw(interp, Parrot_freeze(interp, SELF));
+ return Parrot_thaw(INTERP, Parrot_freeze(INTERP, SELF));
}
/*
@@ -1178,7 +1178,7 @@ Default fallback. Performs a multiple dispatch call for 'add'.
VTABLE PMC *add(PMC *value, PMC *dest) {
PMC *result = PMCNULL;
- Parrot_mmd_multi_dispatch_from_c_args(interp,
+ Parrot_mmd_multi_dispatch_from_c_args(INTERP,
"add", "PPP->P", SELF, value, dest, &result);
return result;
}
@@ -1195,7 +1195,7 @@ Default fallback. Performs a multiple dispatch call for 'add_int'.
VTABLE PMC *add_int(INTVAL value, PMC *dest) {
PMC *result = PMCNULL;
- Parrot_mmd_multi_dispatch_from_c_args(interp,
+ Parrot_mmd_multi_dispatch_from_c_args(INTERP,
"add_int", "PIP->P", SELF, value, dest, &result);
return result;
}
@@ -1229,7 +1229,7 @@ Default fallback. Performs a multiple dispatch call for 'i_add'.
*/
VTABLE void i_add(PMC *value) {
- Parrot_mmd_multi_dispatch_from_c_args(interp,
+ Parrot_mmd_multi_dispatch_from_c_args(INTERP,
"i_add", "PP", SELF, value);
}
@@ -1244,7 +1244,7 @@ Default fallback. Performs a multiple dispatch call for 'i_add_int'.
*/
VTABLE void i_add_int(INTVAL value) {
- Parrot_mmd_multi_dispatch_from_c_args(interp,
+ Parrot_mmd_multi_dispatch_from_c_args(INTERP,
"i_add_int", "PI", SELF, value);
}
@@ -1259,7 +1259,7 @@ Default fallback. Performs a multiple dispatch call for 'i_add_float'.
*/
VTABLE void i_add_float(FLOATVAL value) {
- Parrot_mmd_multi_dispatch_from_c_args(interp,
+ Parrot_mmd_multi_dispatch_from_c_args(INTERP,
"i_add_float", "PN", SELF, value);
}
@@ -1275,7 +1275,7 @@ Default fallback. Performs a multiple dispatch call for 'subtract'.
VTABLE PMC *subtract(PMC *value, PMC *dest) {
PMC *result = PMCNULL;
- Parrot_mmd_multi_dispatch_from_c_args(interp,
+ Parrot_mmd_multi_dispatch_from_c_args(INTERP,
"subtract", "PPP->P", SELF, value, dest, &result);
return result;
}
@@ -1292,7 +1292,7 @@ Default fallback. Performs a multiple dispatch call for 'subtract_int'.
VTABLE PMC *subtract_int(INTVAL value, PMC *dest) {
PMC *result = PMCNULL;
- Parrot_mmd_multi_dispatch_from_c_args(interp,
+ Parrot_mmd_multi_dispatch_from_c_args(INTERP,
"subtract_int", "PIP->P", SELF, value, dest, &result);
return result;
}
@@ -1309,7 +1309,7 @@ Default fallback. Performs a multiple dispatch call for 'subtract_float'.
VTABLE PMC *subtract_float(FLOATVAL value, PMC *dest) {
PMC *result = PMCNULL;
- Parrot_mmd_multi_dispatch_from_c_args(interp,
+ Parrot_mmd_multi_dispatch_from_c_args(INTERP,
"subtract_float", "PNP->P", SELF, value, dest, &result);
return result;
}
@@ -1325,7 +1325,7 @@ Default fallback. Performs a multiple dispatch call for 'i_subtract'.
*/
VTABLE void i_subtract(PMC *value) {
- Parrot_mmd_multi_dispatch_from_c_args(interp,
+ Parrot_mmd_multi_dispatch_from_c_args(INTERP,
"i_subtract", "PP", SELF, value);
}
@@ -1340,7 +1340,7 @@ Default fallback. Performs a multiple dispatch call for 'i_subtract_int'.
*/
VTABLE void i_subtract_int(INTVAL value) {
- Parrot_mmd_multi_dispatch_from_c_args(interp,
+ Parrot_mmd_multi_dispatch_from_c_args(INTERP,
"i_subtract_int", "PI", SELF, value);
}
@@ -1355,7 +1355,7 @@ Default fallback. Performs a multiple dispatch call for 'i_subtract_float'.
*/
VTABLE void i_subtract_float(FLOATVAL value) {
- Parrot_mmd_multi_dispatch_from_c_args(interp,
+ Parrot_mmd_multi_dispatch_from_c_args(INTERP,
"i_subtract_float", "PN", SELF, value);
}
@@ -1371,7 +1371,7 @@ Default fallback. Performs a multiple dispatch call for 'multiply'.
VTABLE PMC *multiply(PMC *value, PMC *dest) {
PMC *result = PMCNULL;
- Parrot_mmd_multi_dispatch_from_c_args(interp,
+ Parrot_mmd_multi_dispatch_from_c_args(INTERP,
"multiply", "PPP->P", SELF, value, dest, &result);
return result;
}
@@ -1388,7 +1388,7 @@ Default fallback. Performs a multiple dispatch call for 'multiply_int'.
VTABLE PMC *multiply_int(INTVAL value, PMC *dest) {
PMC *result = PMCNULL;
- Parrot_mmd_multi_dispatch_from_c_args(interp,
+ Parrot_mmd_multi_dispatch_from_c_args(INTERP,
"multiply_int", "PIP->P", SELF, value, dest, &result);
return result;
}
@@ -1405,7 +1405,7 @@ Default fallback. Performs a multiple dispatch call for 'multiply_float'.
VTABLE PMC *multiply_float(FLOATVAL value, PMC *dest) {
PMC *result = PMCNULL;
- Parrot_mmd_multi_dispatch_from_c_args(interp,
+ Parrot_mmd_multi_dispatch_from_c_args(INTERP,
"multiply_float", "PNP->P", SELF, value, dest, &result);
return result;
}
@@ -1421,7 +1421,7 @@ Default fallback. Performs a multiple dispatch call for 'i_multiply'.
*/
VTABLE void i_multiply(PMC *value) {
- Parrot_mmd_multi_dispatch_from_c_args(interp,
+ Parrot_mmd_multi_dispatch_from_c_args(INTERP,
"i_multiply", "PP", SELF, value);
}
@@ -1436,7 +1436,7 @@ Default fallback. Performs a multiple dispatch call for 'i_multiply_int'.
*/
VTABLE void i_multiply_int(INTVAL value) {
- Parrot_mmd_multi_dispatch_from_c_args(interp,
+ Parrot_mmd_multi_dispatch_from_c_args(INTERP,
"i_multiply_int", "PI", SELF, value);
}
@@ -1451,7 +1451,7 @@ Default fallback. Performs a multiple dispatch call for 'i_multiply_float'.
*/
VTABLE void i_multiply_float(FLOATVAL value) {
- Parrot_mmd_multi_dispatch_from_c_args(interp,
+ Parrot_mmd_multi_dispatch_from_c_args(INTERP,
"i_multiply_float", "PN", SELF, value);
}
@@ -1467,7 +1467,7 @@ Default fallback. Performs a multiple dispatch call for 'divide'.
VTABLE PMC *divide(PMC *value, PMC *dest) {
PMC *result = PMCNULL;
- Parrot_mmd_multi_dispatch_from_c_args(interp,
+ Parrot_mmd_multi_dispatch_from_c_args(INTERP,
"divide", "PPP->P", SELF, value, dest, &result);
return result;
}
@@ -1484,7 +1484,7 @@ Default fallback. Performs a multiple dispatch call for 'divide_int'.
VTABLE PMC *divide_int(INTVAL value, PMC *dest) {
PMC *result = PMCNULL;
- Parrot_mmd_multi_dispatch_from_c_args(interp,
+ Parrot_mmd_multi_dispatch_from_c_args(INTERP,
"divide_int", "PIP->P", SELF, value, dest, &result);
return result;
}
@@ -1501,7 +1501,7 @@ Default fallback. Performs a multiple dispatch call for 'divide_float'.
VTABLE PMC *divide_float(FLOATVAL value, PMC *dest) {
PMC *result = PMCNULL;
- Parrot_mmd_multi_dispatch_from_c_args(interp,
+ Parrot_mmd_multi_dispatch_from_c_args(INTERP,
"divide_float", "PNP->P", SELF, value, dest, &result);
return result;
}
@@ -1517,7 +1517,7 @@ Default fallback. Performs a multiple dispatch call for 'i_divide'.
*/
VTABLE void i_divide(PMC *value) {
- Parrot_mmd_multi_dispatch_from_c_args(interp,
+ Parrot_mmd_multi_dispatch_from_c_args(INTERP,
"i_divide", "PP", SELF, value);
}
@@ -1532,7 +1532,7 @@ Default fallback. Performs a multiple dispatch call for 'i_divide_int'.
*/
VTABLE void i_divide_int(INTVAL value) {
- Parrot_mmd_multi_dispatch_from_c_args(interp,
+ Parrot_mmd_multi_dispatch_from_c_args(INTERP,
"i_divide_int", "PI", SELF, value);
}
@@ -1547,7 +1547,7 @@ Default fallback. Performs a multiple dispatch call for 'i_divide_float'.
*/
VTABLE void i_divide_float(FLOATVAL value) {
- Parrot_mmd_multi_dispatch_from_c_args(interp,
+ Parrot_mmd_multi_dispatch_from_c_args(INTERP,
"i_divide_float", "PN", SELF, value);
}
@@ -1563,7 +1563,7 @@ Default fallback. Performs a multiple dispatch call for 'floor_divide'.
VTABLE PMC *floor_divide(PMC *value, PMC *dest) {
PMC *result = PMCNULL;
- Parrot_mmd_multi_dispatch_from_c_args(interp,
+ Parrot_mmd_multi_dispatch_from_c_args(INTERP,
"floor_divide", "PPP->P", SELF, value, dest, &result);
return result;
}
@@ -1580,7 +1580,7 @@ Default fallback. Performs a multiple dispatch call for 'floor_divide_int'.
VTABLE PMC *floor_divide_int(INTVAL value, PMC *dest) {
PMC *result = PMCNULL;
- Parrot_mmd_multi_dispatch_from_c_args(interp,
+ Parrot_mmd_multi_dispatch_from_c_args(INTERP,
"floor_divide_int", "PIP->P", SELF, value, dest, &result);
return result;
}
@@ -1597,7 +1597,7 @@ Default fallback. Performs a multiple dispatch call for 'floor_divide_float'.
VTABLE PMC *floor_divide_float(FLOATVAL value, PMC *dest) {
PMC *result = PMCNULL;
- Parrot_mmd_multi_dispatch_from_c_args(interp,
+ Parrot_mmd_multi_dispatch_from_c_args(INTERP,
"floor_divide_float", "PNP->P", SELF, value, dest, &result);
return result;
}
@@ -1613,7 +1613,7 @@ Default fallback. Performs a multiple dispatch call for 'i_floor_divide'.
*/
VTABLE void i_floor_divide(PMC *value) {
- Parrot_mmd_multi_dispatch_from_c_args(interp,
+ Parrot_mmd_multi_dispatch_from_c_args(INTERP,
"i_floor_divide", "PP", SELF, value);
}
@@ -1628,7 +1628,7 @@ Default fallback. Performs a multiple dispatch call for 'i_floor_divide_int'.
*/
VTABLE void i_floor_divide_int(INTVAL value) {
- Parrot_mmd_multi_dispatch_from_c_args(interp,
+ Parrot_mmd_multi_dispatch_from_c_args(INTERP,
"i_floor_divide_int", "PI", SELF, value);
}
@@ -1643,7 +1643,7 @@ Default fallback. Performs a multiple dispatch call for 'i_floor_divide_float'.
*/
VTABLE void i_floor_divide_float(FLOATVAL value) {
- Parrot_mmd_multi_dispatch_from_c_args(interp,
+ Parrot_mmd_multi_dispatch_from_c_args(INTERP,
"i_floor_divide_float", "PN", SELF, value);
}
@@ -1659,7 +1659,7 @@ Default fallback. Performs a multiple dispatch call for 'modulus'.
VTABLE PMC *modulus(PMC *value, PMC *dest) {
PMC *result = PMCNULL;
- Parrot_mmd_multi_dispatch_from_c_args(interp,
+ Parrot_mmd_multi_dispatch_from_c_args(INTERP,
"modulus", "PPP->P", SELF, value, dest, &result);
return result;
}
@@ -1676,7 +1676,7 @@ Default fallback. Performs a multiple dispatch call for 'modulus_int'.
VTABLE PMC *modulus_int(INTVAL value, PMC *dest) {
PMC *result = PMCNULL;
- Parrot_mmd_multi_dispatch_from_c_args(interp,
+ Parrot_mmd_multi_dispatch_from_c_args(INTERP,
"modulus_int", "PIP->P", SELF, value, dest, &result);
return result;
}
@@ -1693,7 +1693,7 @@ Default fallback. Performs a multiple dispatch call for 'modulus_float'.
VTABLE PMC *modulus_float(FLOATVAL value, PMC *dest) {
PMC *result = PMCNULL;
- Parrot_mmd_multi_dispatch_from_c_args(interp,
+ Parrot_mmd_multi_dispatch_from_c_args(INTERP,
"modulus_float", "PNP->P", SELF, value, dest, &result);
return result;
}
@@ -1709,7 +1709,7 @@ Default fallback. Performs a multiple dispatch call for 'i_modulus'.
*/
VTABLE void i_modulus(PMC *value) {
- Parrot_mmd_multi_dispatch_from_c_args(interp,
+ Parrot_mmd_multi_dispatch_from_c_args(INTERP,
"i_modulus", "PP", SELF, value);
}
@@ -1724,7 +1724,7 @@ Default fallback. Performs a multiple dispatch call for 'i_modulus_int'.
*/
VTABLE void i_modulus_int(INTVAL value) {
- Parrot_mmd_multi_dispatch_from_c_args(interp,
+ Parrot_mmd_multi_dispatch_from_c_args(INTERP,
"i_modulus_int", "PI", SELF, value);
}
@@ -1739,7 +1739,7 @@ Default fallback. Performs a multiple dispatch call for 'i_modulus_float'.
*/
VTABLE void i_modulus_float(FLOATVAL value) {
- Parrot_mmd_multi_dispatch_from_c_args(interp,
+ Parrot_mmd_multi_dispatch_from_c_args(INTERP,
"i_modulus_float", "PN", SELF, value);
}
@@ -1761,7 +1761,7 @@ Default fallback. Performs a multiple dispatch call for 'cmp'.
if (SELF == value)
return 0;
- Parrot_mmd_multi_dispatch_from_c_args(interp,
+ Parrot_mmd_multi_dispatch_from_c_args(INTERP,
"cmp", "PP->I", SELF, value, &retval);
return retval;
@@ -1779,7 +1779,7 @@ Default fallback. Performs a multiple dispatch call for 'cmp_num'.
VTABLE INTVAL cmp_num(PMC *value) {
INTVAL retval;
- Parrot_mmd_multi_dispatch_from_c_args(interp,
+ Parrot_mmd_multi_dispatch_from_c_args(INTERP,
"cmp_num", "PP->I", SELF, value, &retval);
return retval;
@@ -1797,7 +1797,7 @@ Default fallback. Performs a multiple dispatch call for 'cmp_string'.
VTABLE INTVAL cmp_string(PMC *value) {
INTVAL retval;
- Parrot_mmd_multi_dispatch_from_c_args(interp,
+ Parrot_mmd_multi_dispatch_from_c_args(INTERP,
"cmp_string", "PP->I", SELF, value, &retval);
return retval;
@@ -1821,7 +1821,7 @@ Default fallback. Performs a multiple dispatch call for 'cmp_pmc'.
if (SELF == value)
return NULL;
- Parrot_mmd_multi_dispatch_from_c_args(interp,
+ Parrot_mmd_multi_dispatch_from_c_args(INTERP,
"cmp_pmc", "PP->P", SELF, value, &retval);
return retval;
@@ -1838,7 +1838,7 @@ Default fallback. Performs a multiple dispatch call for 'logical_or'.
VTABLE PMC *logical_or(PMC *value, PMC *dest) {
PMC *result = PMCNULL;
- Parrot_mmd_multi_dispatch_from_c_args(interp,
+ Parrot_mmd_multi_dispatch_from_c_args(INTERP,
"logical_or", "PPP->P", SELF, value, dest, &result);
return result;
}
@@ -1855,7 +1855,7 @@ Default fallback. Performs a multiple dispatch call for 'logical_and'.
VTABLE PMC *logical_and(PMC *value, PMC *dest) {
PMC *result = PMCNULL;
- Parrot_mmd_multi_dispatch_from_c_args(interp,
+ Parrot_mmd_multi_dispatch_from_c_args(INTERP,
"logical_and", "PPP->P", SELF, value, dest, &result);
return result;
}
@@ -1872,7 +1872,7 @@ Default fallback. Performs a multiple dispatch call for 'logical_xor'.
VTABLE PMC *logical_xor(PMC *value, PMC *dest) {
PMC *result = PMCNULL;
- Parrot_mmd_multi_dispatch_from_c_args(interp,
+ Parrot_mmd_multi_dispatch_from_c_args(INTERP,
"logical_xor", "PPP->P", SELF, value, dest, &result);
return result;
}
@@ -1889,7 +1889,7 @@ Default fallback. Performs a multiple dispatch call for 'concatenate'.
VTABLE PMC *concatenate(PMC *value, PMC *dest) {
PMC *result = PMCNULL;
- Parrot_mmd_multi_dispatch_from_c_args(interp,
+ Parrot_mmd_multi_dispatch_from_c_args(INTERP,
"concatenate", "PPP->P", SELF, value, dest, &result);
return result;
}