[svn:parrot] r45733 - trunk/t/src
dukeleto at svn.parrot.org
dukeleto at svn.parrot.org
Sat Apr 17 04:08:31 UTC 2010
Author: dukeleto
Date: Sat Apr 17 04:08:31 2010
New Revision: 45733
URL: https://trac.parrot.org/parrot/changeset/45733
Log:
[t][cage] Convert STRING to Parrot_String in the embed/extend interface
Modified:
trunk/t/src/embed.t
trunk/t/src/extend.t
Modified: trunk/t/src/embed.t
==============================================================================
--- trunk/t/src/embed.t Sat Apr 17 03:43:32 2010 (r45732)
+++ trunk/t/src/embed.t Sat Apr 17 04:08:31 2010 (r45733)
@@ -312,16 +312,16 @@
{
const char *c_src = ".sub main :main\n" " print \"ok\\n\"\n" ".end\n";
- STRING *src, *smain;
+ Parrot_String *src, *smain;
PMC *prog, *entry;
opcode_t *dest;
- STRING *error;
+ Parrot_String *error;
/* get PIR compiler - TODO API */
PMC *compreg = Parrot_PMC_get_pmc_keyed_int(interp,
interp->iglobals,
IGLOBALS_COMPREG_HASH);
- STRING *pir = Parrot_str_new_constant(interp, "PIR");
+ Parrot_String *pir = Parrot_str_new_constant(interp, "PIR");
PMC *comp = Parrot_PMC_get_pmc_keyed_str(interp, compreg, pir);
if (PMC_IS_NULL(comp) || !Parrot_PMC_defined(interp, comp)) {
@@ -388,12 +388,12 @@
#include "parrot/embed.h"
static void
-compile_run(PARROT_INTERP, const char *src, STRING *type, int argc,
+compile_run(PARROT_INTERP, const char *src, Parrot_String *type, int argc,
char *argv[])
{
- STRING *smain;
+ Parrot_String *smain;
PMC *entry;
- STRING *error;
+ Parrot_String *error;
opcode_t *dest;
PMC *prog = Parrot_compile_string(interp, type, src, &error);
@@ -428,13 +428,13 @@
const char *c2_src =
".sub main :main\n" " print \"hola\\n\"\n" ".end\n";
- STRING *src, *smain;
+ Parrot_String *src, *smain;
/* get PIR compiler - TODO API */
PMC *compreg = Parrot_PMC_get_pmc_keyed_int(interp,
interp->iglobals,
IGLOBALS_COMPREG_HASH);
- STRING *pir = Parrot_str_new_constant(interp, "PIR");
+ Parrot_String *pir = Parrot_str_new_constant(interp, "PIR");
PMC *comp = Parrot_PMC_get_pmc_keyed_str(interp, compreg, pir);
if (PMC_IS_NULL(comp) || !Parrot_PMC_defined(interp, comp)) {
@@ -479,12 +479,12 @@
#include "parrot/embed.h"
static void
-compile_run(PARROT_INTERP, const char *src, STRING *type, int argc,
+compile_run(PARROT_INTERP, const char *src, Parrot_String *type, int argc,
char *argv[])
{
- STRING *smain;
+ Parrot_String *smain;
PMC *entry;
- STRING *error;
+ Parrot_String *error;
opcode_t *dest;
PMC *prog = Parrot_compile_string(interp, type, src, &error);
@@ -519,13 +519,13 @@
const char *c2_src =
".sub main :main\n" " print \"hola\\n\"\n" ".end\n";
- STRING *src, *smain;
+ Parrot_String *src, *smain;
/* get PIR compiler - TODO API */
PMC *compreg = Parrot_PMC_get_pmc_keyed_int(interp,
interp->iglobals,
IGLOBALS_COMPREG_HASH);
- STRING *pir = Parrot_str_new_constant(interp, "PIR");
+ Parrot_String *pir = Parrot_str_new_constant(interp, "PIR");
PMC *comp = Parrot_PMC_get_pmc_keyed_str(interp, compreg, pir);
if (PMC_IS_NULL(comp) || !Parrot_PMC_defined(interp, comp)) {
@@ -570,12 +570,12 @@
#include "parrot/embed.h"
static void
-compile_run(PARROT_INTERP, const char *src, STRING *type, int argc,
+compile_run(PARROT_INTERP, const char *src, Parrot_String *type, int argc,
char *argv[])
{
- STRING *smain;
+ Parrot_String *smain;
PMC *entry;
- STRING *error;
+ Parrot_String *error;
opcode_t *dest;
PMC *prog = Parrot_compile_string(interp, type, src, &error);
@@ -610,12 +610,12 @@
const char *c2_src =
".sub main :main\n" " print \"hola\\n\"\n" ".end\n";
- STRING *src, *smain;
+ Parrot_String *src, *smain;
/* get PIR compiler - TODO API */
PMC *compreg = Parrot_PMC_get_pmc_keyed_int(interp,
interp->iglobals,
IGLOBALS_COMPREG_HASH);
- STRING *pir = Parrot_str_new_constant(interp, "PIR");
+ Parrot_String *pir = Parrot_str_new_constant(interp, "PIR");
PMC *comp = Parrot_PMC_get_pmc_keyed_str(interp, compreg, pir);
if (PMC_IS_NULL(comp) || !Parrot_PMC_defined(interp, comp)) {
@@ -660,12 +660,12 @@
#include "parrot/embed.h"
static void
-compile_run(PARROT_INTERP, const char *src, STRING *type, int argc,
+compile_run(PARROT_INTERP, const char *src, Parrot_String *type, int argc,
char *argv[])
{
- STRING *smain;
+ Parrot_String *smain;
PMC *entry;
- STRING *error;
+ Parrot_String *error;
opcode_t *dest;
PMC *prog = Parrot_compile_string(interp, type, src, &error);
@@ -699,12 +699,12 @@
const char *c2_src = ".sub main :main\n" " print hola\\n\"\n" ".end\n";
- STRING *src, *smain;
+ Parrot_String *src, *smain;
/* get PIR compiler - TODO API */
PMC *compreg = Parrot_PMC_get_pmc_keyed_int(interp,
interp->iglobals,
IGLOBALS_COMPREG_HASH);
- STRING *pir = Parrot_str_new_constant(interp, "PIR");
+ Parrot_String *pir = Parrot_str_new_constant(interp, "PIR");
PMC *comp = Parrot_PMC_get_pmc_keyed_str(interp, compreg, pir);
if (PMC_IS_NULL(comp) || !Parrot_PMC_defined(interp, comp)) {
Modified: trunk/t/src/extend.t
==============================================================================
--- trunk/t/src/extend.t Sat Apr 17 03:43:32 2010 (r45732)
+++ trunk/t/src/extend.t Sat Apr 17 04:08:31 2010 (r45733)
@@ -441,7 +441,7 @@
the_test(PARROT_INTERP, opcode_t *cur_op, opcode_t *start)
{
PackFile *pf = Parrot_pbc_read(interp, "$temp_pbc", 0);
- STRING *name = Parrot_str_new_constant(interp, "_sub1");
+ Parrot_String *name = Parrot_str_new_constant(interp, "_sub1");
PMC *sub, *arg;
Parrot_pbc_load(interp, pf);
@@ -499,7 +499,7 @@
the_test(PARROT_INTERP, opcode_t *cur_op, opcode_t *start)
{
PackFile *pf = Parrot_pbc_read(interp, "$temp_pbc", 0);
- STRING *name = Parrot_str_new_constant(interp, "_sub1");
+ Parrot_String *name = Parrot_str_new_constant(interp, "_sub1");
PMC *sub, *arg;
Parrot_pbc_load(interp, pf);
@@ -575,7 +575,7 @@
the_test(PARROT_INTERP, opcode_t *cur_op, opcode_t *start)
{
PackFile *pf = Parrot_pbc_read(interp, "$temp_pbc", 0);
- STRING *name = Parrot_str_new_constant(interp, "foo");
+ Parrot_String *name = Parrot_str_new_constant(interp, "foo");
PMC *sub, *arg;
Parrot_Int result;
@@ -642,7 +642,7 @@
the_test(PARROT_INTERP, opcode_t *cur_op, opcode_t *start)
{
PackFile *pf = Parrot_pbc_read(interp, "$temp_pbc", 0);
- STRING *name = Parrot_str_new_constant(interp, "_sub1");
+ Parrot_String *name = Parrot_str_new_constant(interp, "_sub1");
PMC *sub;
Parrot_runloop jump_point;
@@ -761,9 +761,9 @@
const char *code = ".sub foo\nprint\"Hello from foo!\\n\"\n.end\n";
Parrot_PMC retval;
Parrot_PMC sub;
- STRING *code_type;
- STRING *error;
- STRING *foo_name;
+ Parrot_String *code_type;
+ Parrot_String *error;
+ Parrot_String *foo_name;
if (!interp) {
printf( "Hiss\n" );
More information about the parrot-commits
mailing list