[svn:parrot] r49691 - branches/embed_api/src
whiteknight at svn.parrot.org
whiteknight at svn.parrot.org
Tue Oct 26 23:47:58 UTC 2010
Author: whiteknight
Date: Tue Oct 26 23:47:57 2010
New Revision: 49691
URL: https://trac.parrot.org/parrot/changeset/49691
Log:
move the load_bytecode_file function into the new API. Rename it to match
Modified:
branches/embed_api/src/embed.c
branches/embed_api/src/embed_api.c
Modified: branches/embed_api/src/embed.c
==============================================================================
--- branches/embed_api/src/embed.c Tue Oct 26 23:45:28 2010 (r49690)
+++ branches/embed_api/src/embed.c Tue Oct 26 23:47:57 2010 (r49691)
@@ -614,30 +614,6 @@
/*
-=item C<int Parrot_load_bytecode_file(PARROT_INTERP, const char *filename)>
-
-Load a bytecode file into the interpreter by name. Returns C<0> on failure,
-Success otherwise. Writes error information to the interpreter's error file
-stream.
-
-=cut
-
-*/
-
-PARROT_EXPORT
-int
-Parrot_load_bytecode_file(PARROT_INTERP, ARGIN(const char *filename))
-{
- PackFile * const pf = Parrot_pbc_read(interp, filename, 0);
-
- if (!pf)
- return 0;
- Parrot_pbc_load(interp, pf);
- return 1;
-}
-
-/*
-
=item C<void Parrot_pbc_fixup_loaded(PARROT_INTERP)>
Fixups after pbc loading
Modified: branches/embed_api/src/embed_api.c
==============================================================================
--- branches/embed_api/src/embed_api.c Tue Oct 26 23:45:28 2010 (r49690)
+++ branches/embed_api/src/embed_api.c Tue Oct 26 23:47:57 2010 (r49691)
@@ -58,3 +58,26 @@
Parrot_destroy(interp);
}
+/*
+
+=item C<int Parrot_api_load_bytecode_file(PARROT_INTERP, const char *filename)>
+
+Load a bytecode file into the interpreter by name. Returns C<0> on failure,
+Success otherwise. Writes error information to the interpreter's error file
+stream.
+
+=cut
+
+*/
+
+PARROT_EXPORT
+int
+Parrot_api_load_bytecode_file(PARROT_INTERP, ARGIN(const char *filename))
+{
+ PackFile * const pf = Parrot_pbc_read(interp, filename, 0);
+
+ if (!pf)
+ return 0;
+ Parrot_pbc_load(interp, pf);
+ return 1;
+}
More information about the parrot-commits
mailing list