Skip to content
This repository
Newer
Older
100644 363 lines (253 sloc) 9.542 kb
9255c820 » paultcochrane
2007-03-26 [src] Set svn:keywords and svn:eol-style properties appropriately
1 /*
48311a58 » petdance
2009-05-20 teeny consting
2 Copyright (C) 2007-2009, Parrot Foundation.
9255c820 » paultcochrane
2007-03-26 [src] Set svn:keywords and svn:eol-style properties appropriately
3
4 =head1 NAME
5
6 src/pmc/exporter.pmc - Export globals from one namespace to another
7
abc4db2c » particle
2007-05-14 [pmc]: exporter api changes
8 =head1 SYNOPSIS
9
10 You can use Exporter in PIR to import subs from a library. At its simplest:
11
12 .sub main :main
13 load_bytecode 'Test/More.pir'
f6d5c3e9 » chromatic
2007-09-04 [PMC] More minor cleanups and reformattings.
14
bdc07b99 » chromatic
2007-10-13 [PMC] Add Exporter documentation into POD (Pabellon, RT #44487).
15 .local pmc exporter, src_ns, dest_ns
16 src_ns = get_namespace [ 'Test'; 'More' ]
abc4db2c » particle
2007-05-14 [pmc]: exporter api changes
17 exporter = new 'Exporter'
f6d5c3e9 » chromatic
2007-09-04 [PMC] More minor cleanups and reformattings.
18
bdc07b99 » chromatic
2007-10-13 [PMC] Add Exporter documentation into POD (Pabellon, RT #44487).
19 exporter.'import'( src_ns :named('source') 'plan ok' :named('globals') )
abc4db2c » particle
2007-05-14 [pmc]: exporter api changes
20 plan(1)
21 ok(1, 'exporter has imported the requested functions')
22 .end
23
bdc07b99 » chromatic
2007-10-13 [PMC] Add Exporter documentation into POD (Pabellon, RT #44487).
24 You can also specify the exporter attributes before making the import call,
25 for example to import into the alternate namespace 'Foo' you could use the
26 following code:
27
28 src_ns = get_namespace [ 'Test'; 'More' ]
29 dest_ns = get_namespace [ 'Foo' ]
30 exporter.'source'(src_ns)
31 exporter.'destination'(dest_ns)
32 exporter.'import'('plan ok' :named('globals'))
33
34 You can even import subroutines under different names if globals is a hash:
35
36 globals = new 'Hash'
37 globals['plan'] = 'steps'
38 globals['ok'] = 'passed'
39 exporter.'import'(globals :named('globals'))
40 steps(1)
41 passed(1)
42
abc4db2c » particle
2007-05-14 [pmc]: exporter api changes
43
9255c820 » paultcochrane
2007-03-26 [src] Set svn:keywords and svn:eol-style properties appropriately
44 =head1 DESCRIPTION
45
b29ad29d » particle
2007-04-03 [pmc] Exporter updates
46 Exports globals from one namespace to another. Exporter always uses
6498378a » particle
2007-04-05 [pmc]: update Exporter documentation based on draft guidelines
47 the typed namespace interface, as outlined in
48 F<docs/pdds/pdd21_namespaces.pod>.
9255c820 » paultcochrane
2007-03-26 [src] Set svn:keywords and svn:eol-style properties appropriately
49
eae5b2f6 » particle
2007-03-30 [pmc]: documentation overhaul for Exporter
50 Exporter is not derived from any other PMC, and does not provide any
1df1b754 » coke
2010-03-30 Eliminate 'vtable method'. It's a vtable, or a vtable function.
51 vtable interface--its interface consists solely of methods, not
52 vtable functions.
eae5b2f6 » particle
2007-03-30 [pmc]: documentation overhaul for Exporter
53
54 =head2 Structure
55
56 The Exporter PMC structure (C<Parrot_Exporter>) consists of three items:
9255c820 » paultcochrane
2007-03-26 [src] Set svn:keywords and svn:eol-style properties appropriately
57
58 =over 4
59
eae5b2f6 » particle
2007-03-30 [pmc]: documentation overhaul for Exporter
60 =item C<ns_src>
61
62 The source namespace -- a NameSpace PMC.
5b556ee8 » particle
2007-04-10 [pmc]: Exporter is complete
63 A Null PMC is allocated during initialization.
eae5b2f6 » particle
2007-03-30 [pmc]: documentation overhaul for Exporter
64
65 =item C<ns_dest>
66
67 The destination namespace -- a NameSpace PMC.
4b47d4cf » particle
2007-04-05 [pmc]: Exporter
68 A PMC representing the current namespace is allocated upon initialization.
eae5b2f6 » particle
2007-03-30 [pmc]: documentation overhaul for Exporter
69
70 =item C<globals>
71
bdc07b99 » chromatic
2007-10-13 [PMC] Add Exporter documentation into POD (Pabellon, RT #44487).
72 The globals to export -- a PMC that implements a hash, an array, a String
73 containing a list of space-separated subroutine names or Null.
74
b29ad29d » particle
2007-04-03 [pmc] Exporter updates
75 A Null PMC is allocated during initialization.
eae5b2f6 » particle
2007-03-30 [pmc]: documentation overhaul for Exporter
76
9255c820 » paultcochrane
2007-03-26 [src] Set svn:keywords and svn:eol-style properties appropriately
77 =cut
78
79 */
80
eae5b2f6 » particle
2007-03-30 [pmc]: documentation overhaul for Exporter
81 /*
82
83 =back
84
85 =head2 Functions
86
87 =over 4
88
89 =cut
90
91 */
92
6bdd5f99 » petdance
2010-03-28 headerizer now runs on PMC files
93 /* HEADERIZER HFILE: none */
94 /* HEADERIZER BEGIN: static */
95 /* HEADERIZER END: static */
96
6b817608 » Whiteknight
2009-08-23 [pmc] we don't need need_ext anymore, so BALEETED
97 pmclass Exporter auto_attrs {
9255c820 » paultcochrane
2007-03-26 [src] Set svn:keywords and svn:eol-style properties appropriately
98
59661f18 » allisonrandal
2008-03-11 [pdd17pmc] Merging the pdd17pmc branch into trunk (r24435 to r26307).
99 ATTR PMC *ns_src;
100 ATTR PMC *ns_dest;
101 ATTR PMC *globals;
9255c820 » paultcochrane
2007-03-26 [src] Set svn:keywords and svn:eol-style properties appropriately
102
103 /*
104
105 =item C<void init()>
106
b54e3d58 » particle
2007-04-13 [pmc]: documentation updates
107 Initializes an Exporter PMC.
9255c820 » paultcochrane
2007-03-26 [src] Set svn:keywords and svn:eol-style properties appropriately
108
109 =cut
110
111 */
112
59661f18 » allisonrandal
2008-03-11 [pdd17pmc] Merging the pdd17pmc branch into trunk (r24435 to r26307).
113 VTABLE void init() {
9255c820 » paultcochrane
2007-03-26 [src] Set svn:keywords and svn:eol-style properties appropriately
114 /* Set up the object. */
ac99f44a » NotFound
2009-08-06 [cage] full use of SET/GET ATTR in exporter PMC
115 SET_ATTR_ns_src(INTERP, SELF, PMCNULL);
540d4c31 » bacek
2009-09-03 Merge context_pmc3 branch into trunk.
116 SET_ATTR_ns_dest(INTERP, SELF, Parrot_pcc_get_namespace(INTERP, CURRENT_CONTEXT(INTERP)));
ac99f44a » NotFound
2009-08-06 [cage] full use of SET/GET ATTR in exporter PMC
117 SET_ATTR_globals(INTERP, SELF, PMCNULL);
366638e3 » particle
2007-07-20 [pmc]: set pmc flags after anchoring to prevent accidental collection…
118
1997c49c » cotto
2009-02-12 [gc] remove/replace DOD references in core PMCs
119 /* Set flags for custom GC mark and destroy. */
366638e3 » particle
2007-07-20 [pmc]: set pmc flags after anchoring to prevent accidental collection…
120 PObj_custom_mark_SET(SELF);
9255c820 » paultcochrane
2007-03-26 [src] Set svn:keywords and svn:eol-style properties appropriately
121 }
122
eae5b2f6 » particle
2007-03-30 [pmc]: documentation overhaul for Exporter
123 /*
124
125 =item C<void mark()>
126
127 Mark referenced strings and PMCs in the structure as live.
128
129 =cut
130
131 */
132
59661f18 » allisonrandal
2008-03-11 [pdd17pmc] Merging the pdd17pmc branch into trunk (r24435 to r26307).
133 VTABLE void mark() {
ac99f44a » NotFound
2009-08-06 [cage] full use of SET/GET ATTR in exporter PMC
134 PMC *ns_src;
135 PMC *ns_dest;
136 PMC *globals;
e8c12900 » NotFound
2009-08-06 [cage] codingstd hard tabs, mikehh++
137 GET_ATTR_ns_src(INTERP, SELF, ns_src);
138 GET_ATTR_ns_dest(INTERP, SELF, ns_dest);
139 GET_ATTR_globals(INTERP, SELF, globals);
ac99f44a » NotFound
2009-08-06 [cage] full use of SET/GET ATTR in exporter PMC
140
26914e12 » Jimmy Zhuo
2010-05-05 changed interp in pmc class to INTERP for unification
141 Parrot_gc_mark_PMC_alive(INTERP, ns_src);
142 Parrot_gc_mark_PMC_alive(INTERP, ns_dest);
143 Parrot_gc_mark_PMC_alive(INTERP, globals);
eae5b2f6 » particle
2007-03-30 [pmc]: documentation overhaul for Exporter
144 }
145
146
147 /*
148
149 =back
150
151 =head2 Methods
152
153 =over 4
154
59661f18 » allisonrandal
2008-03-11 [pdd17pmc] Merging the pdd17pmc branch into trunk (r24435 to r26307).
155 =item C<METHOD
f6d5c3e9 » chromatic
2007-09-04 [PMC] More minor cleanups and reformattings.
156 source(PMC *src :optional, int got_src :opt_flag)>
eae5b2f6 » particle
2007-03-30 [pmc]: documentation overhaul for Exporter
157
158 Accessor for the source NameSpace object (C<ns_src>.)
159 Sets the value if C<src> is passed, otherwise returns the value.
160 Throws an exception if a non-NameSpace PMC is passed.
9255c820 » paultcochrane
2007-03-26 [src] Set svn:keywords and svn:eol-style properties appropriately
161
162 =cut
163
164 */
165
59661f18 » allisonrandal
2008-03-11 [pdd17pmc] Merging the pdd17pmc branch into trunk (r24435 to r26307).
166 METHOD source(PMC *src :optional, int got_src :opt_flag) {
9255c820 » paultcochrane
2007-03-26 [src] Set svn:keywords and svn:eol-style properties appropriately
167 if (got_src) {
2255840f » allisonrandal
2008-08-02 [pdd17pmc] Merging the pdd25cx branch into trunk for r26555 to r29949.
168 if (src->vtable->base_type != enum_class_NameSpace)
26914e12 » Jimmy Zhuo
2010-05-05 changed interp in pmc class to INTERP for unification
169 Parrot_ex_throw_from_c_args(INTERP, NULL, 0,
ac3ceb69 » particle
2007-03-28 [pmc] finish Exporter's 'source' and 'destination' methods
170 "source must be a NameSpace PMC");
2255840f » allisonrandal
2008-08-02 [pdd17pmc] Merging the pdd25cx branch into trunk for r26555 to r29949.
171
26914e12 » Jimmy Zhuo
2010-05-05 changed interp in pmc class to INTERP for unification
172 SET_ATTR_ns_src(INTERP, SELF, src);
9255c820 » paultcochrane
2007-03-26 [src] Set svn:keywords and svn:eol-style properties appropriately
173 }
174 else {
59661f18 » allisonrandal
2008-03-11 [pdd17pmc] Merging the pdd17pmc branch into trunk (r24435 to r26307).
175 PMC *tmp_ns_src;
26914e12 » Jimmy Zhuo
2010-05-05 changed interp in pmc class to INTERP for unification
176 GET_ATTR_ns_src(INTERP, SELF, tmp_ns_src);
59661f18 » allisonrandal
2008-03-11 [pdd17pmc] Merging the pdd17pmc branch into trunk (r24435 to r26307).
177 RETURN(PMC *tmp_ns_src);
9255c820 » paultcochrane
2007-03-26 [src] Set svn:keywords and svn:eol-style properties appropriately
178 }
179 }
180
181
182 /*
183
59661f18 » allisonrandal
2008-03-11 [pdd17pmc] Merging the pdd17pmc branch into trunk (r24435 to r26307).
184 =item C<METHOD
eae5b2f6 » particle
2007-03-30 [pmc]: documentation overhaul for Exporter
185 destination(PMC *dest :optional, int got_dest :opt_flag)>
9318910f » particle
2007-03-26 [pmc] Exporter updates
186
eae5b2f6 » particle
2007-03-30 [pmc]: documentation overhaul for Exporter
187 Accessor for the destination NameSpace object (C<ns_dest>.)
188 Sets the value if C<dest> is passed, otherwise returns the value.
189 Throws an exception if a non-NameSpace PMC is passed.
9318910f » particle
2007-03-26 [pmc] Exporter updates
190
191 =cut
192
193 */
194
59661f18 » allisonrandal
2008-03-11 [pdd17pmc] Merging the pdd17pmc branch into trunk (r24435 to r26307).
195 METHOD destination(PMC *dest :optional, int got_dest :opt_flag) {
9318910f » particle
2007-03-26 [pmc] Exporter updates
196 if (got_dest) {
2255840f » allisonrandal
2008-08-02 [pdd17pmc] Merging the pdd25cx branch into trunk for r26555 to r29949.
197
198 if (dest->vtable->base_type != enum_class_NameSpace)
26914e12 » Jimmy Zhuo
2010-05-05 changed interp in pmc class to INTERP for unification
199 Parrot_ex_throw_from_c_args(INTERP, NULL, 0,
2255840f » allisonrandal
2008-08-02 [pdd17pmc] Merging the pdd25cx branch into trunk for r26555 to r29949.
200 "destination must be a NameSpace PMC");
201
26914e12 » Jimmy Zhuo
2010-05-05 changed interp in pmc class to INTERP for unification
202 SET_ATTR_ns_dest(INTERP, SELF, dest);
9318910f » particle
2007-03-26 [pmc] Exporter updates
203 }
204 else {
59661f18 » allisonrandal
2008-03-11 [pdd17pmc] Merging the pdd17pmc branch into trunk (r24435 to r26307).
205 PMC *tmp_ns_dest;
26914e12 » Jimmy Zhuo
2010-05-05 changed interp in pmc class to INTERP for unification
206 GET_ATTR_ns_dest(INTERP, SELF, tmp_ns_dest);
59661f18 » allisonrandal
2008-03-11 [pdd17pmc] Merging the pdd17pmc branch into trunk (r24435 to r26307).
207 RETURN(PMC *tmp_ns_dest);
9318910f » particle
2007-03-26 [pmc] Exporter updates
208 }
209 }
210
211
212 /*
213
59661f18 » allisonrandal
2008-03-11 [pdd17pmc] Merging the pdd17pmc branch into trunk (r24435 to r26307).
214 =item C<METHOD
b29ad29d » particle
2007-04-03 [pmc] Exporter updates
215 globals(PMC *glb :optional, int got_glb :opt_flag)>
eae5b2f6 » particle
2007-03-30 [pmc]: documentation overhaul for Exporter
216
abc4db2c » particle
2007-05-14 [pmc]: exporter api changes
217 Accessor for the globals to export (C<globals>.)
218 Sets the value if C<glb> is passed, otherwise returns the value.
219 If C<glb> is a String, it is split on ascii whitespace, and each array member
220 is added as a hash key.
221 If C<glb> implements the array interface, each member is added as a hash key.
222 if C<glb> implements the hash interface, it is assigned to Exporter's
223 C<globals> attribute.
224 Throws an exception if an unknown PMC type is passed.
eae5b2f6 » particle
2007-03-30 [pmc]: documentation overhaul for Exporter
225
9255c820 » paultcochrane
2007-03-26 [src] Set svn:keywords and svn:eol-style properties appropriately
226 =cut
227
228 */
229
59661f18 » allisonrandal
2008-03-11 [pdd17pmc] Merging the pdd17pmc branch into trunk (r24435 to r26307).
230 METHOD globals(PMC *glb :optional, int got_glb :opt_flag) {
26914e12 » Jimmy Zhuo
2010-05-05 changed interp in pmc class to INTERP for unification
231 STRING * const s_str = CONST_STRING(INTERP, "String");
232 STRING * const s_arr = CONST_STRING(INTERP, "array");
233 STRING * const s_hash = CONST_STRING(INTERP, "hash");
234 STRING * const s_space = CONST_STRING(INTERP, " ");
9318910f » particle
2007-03-26 [pmc] Exporter updates
235
b29ad29d » particle
2007-04-03 [pmc] Exporter updates
236 if (got_glb) {
26914e12 » Jimmy Zhuo
2010-05-05 changed interp in pmc class to INTERP for unification
237 STRING * const s_empty = CONST_STRING(INTERP, "");
238 PMC *temp_globals = Parrot_pmc_new(INTERP, enum_class_Hash);
abc4db2c » particle
2007-05-14 [pmc]: exporter api changes
239
240 if (PMC_IS_NULL(glb)) {
241 temp_globals = PMCNULL;
242 }
26914e12 » Jimmy Zhuo
2010-05-05 changed interp in pmc class to INTERP for unification
243 else if (VTABLE_isa(INTERP, glb, s_str) || (VTABLE_does(INTERP, glb, s_arr))) {
abc4db2c » particle
2007-05-14 [pmc]: exporter api changes
244 PMC *glb_array;
245 INTVAL n, i;
246
26914e12 » Jimmy Zhuo
2010-05-05 changed interp in pmc class to INTERP for unification
247 if (VTABLE_isa(INTERP, glb, s_str))
248 glb_array = Parrot_str_split(INTERP, s_space,
249 VTABLE_get_string(INTERP, glb));
abc4db2c » particle
2007-05-14 [pmc]: exporter api changes
250 else
251 glb_array = glb;
252
26914e12 » Jimmy Zhuo
2010-05-05 changed interp in pmc class to INTERP for unification
253 n = VTABLE_elements(INTERP, glb_array);
abc4db2c » particle
2007-05-14 [pmc]: exporter api changes
254
255 if (n == 0)
256 temp_globals = PMCNULL;
257
40e294a8 » Jimmy Zhuo
2010-04-30 manual optimization for old compiler
258 for (i = 0; i < n; ++i) {
26914e12 » Jimmy Zhuo
2010-05-05 changed interp in pmc class to INTERP for unification
259 STRING * const item = VTABLE_get_string_keyed_int(INTERP, glb_array, i);
260 VTABLE_set_string_keyed_str(INTERP, temp_globals, item, s_empty);
abc4db2c » particle
2007-05-14 [pmc]: exporter api changes
261 }
262 }
26914e12 » Jimmy Zhuo
2010-05-05 changed interp in pmc class to INTERP for unification
263 else if (VTABLE_does(INTERP, glb, s_hash)) {
264 if (VTABLE_elements(INTERP, glb) == 0)
abc4db2c » particle
2007-05-14 [pmc]: exporter api changes
265 temp_globals = PMCNULL;
266 else
267 temp_globals = glb;
268 }
269 else {
26914e12 » Jimmy Zhuo
2010-05-05 changed interp in pmc class to INTERP for unification
270 Parrot_ex_throw_from_c_args(INTERP, NULL, 0,
abc4db2c » particle
2007-05-14 [pmc]: exporter api changes
271 "Invalid type %d in globals()", glb->vtable->base_type);
272 }
273
26914e12 » Jimmy Zhuo
2010-05-05 changed interp in pmc class to INTERP for unification
274 SET_ATTR_globals(INTERP, SELF, temp_globals);
b29ad29d » particle
2007-04-03 [pmc] Exporter updates
275 }
276 else {
59661f18 » allisonrandal
2008-03-11 [pdd17pmc] Merging the pdd17pmc branch into trunk (r24435 to r26307).
277 PMC *tmp_globals;
26914e12 » Jimmy Zhuo
2010-05-05 changed interp in pmc class to INTERP for unification
278 GET_ATTR_globals(INTERP, SELF, tmp_globals);
59661f18 » allisonrandal
2008-03-11 [pdd17pmc] Merging the pdd17pmc branch into trunk (r24435 to r26307).
279 if (PMC_IS_NULL(tmp_globals)) {
280 RETURN(PMC *PMCNULL);
b29ad29d » particle
2007-04-03 [pmc] Exporter updates
281 }
59661f18 » allisonrandal
2008-03-11 [pdd17pmc] Merging the pdd17pmc branch into trunk (r24435 to r26307).
282 else
283 RETURN(PMC *tmp_globals);
9318910f » particle
2007-03-26 [pmc] Exporter updates
284 }
9255c820 » paultcochrane
2007-03-26 [src] Set svn:keywords and svn:eol-style properties appropriately
285 }
286
287
288 /*
289
59661f18 » allisonrandal
2008-03-11 [pdd17pmc] Merging the pdd17pmc branch into trunk (r24435 to r26307).
290 =item C<METHOD
37922cf3 » chromatic
2008-03-15 [lib/PMC] Modified :named parameter syntax in METHODs to match PDD03,…
291 import(PMC *dest :optional :named("destination"), int got_dest :opt_flag,
292 PMC *src :optional :named("source"), int got_src :opt_flag,
293 PMC *globals :optional :named("globals"), int got_globals :opt_flag)>
9255c820 » paultcochrane
2007-03-26 [src] Set svn:keywords and svn:eol-style properties appropriately
294
295 Import C<globals> from the C<src> namespace to the C<dest> namespace.
abc4db2c » particle
2007-05-14 [pmc]: exporter api changes
296 If C<src>, C<dest>, or C<globals> are passed, they override the current value.
b29ad29d » particle
2007-04-03 [pmc] Exporter updates
297 C<import> follows the semantics of the C<export_to> method
298 of the C<NameSpace> PMC. in particular, if a NULL value is passed
299 for C<globals>, the default set of items will be imported.
eae5b2f6 » particle
2007-03-30 [pmc]: documentation overhaul for Exporter
300 Throws an exception upon error.
9255c820 » paultcochrane
2007-03-26 [src] Set svn:keywords and svn:eol-style properties appropriately
301
302 =cut
303
304 */
305
37922cf3 » chromatic
2008-03-15 [lib/PMC] Modified :named parameter syntax in METHODs to match PDD03,…
306 METHOD import(PMC *dest :optional :named("destination"),
307 int got_dest :opt_flag,
308 PMC *src :optional :named("source"),
309 int got_src :opt_flag,
310 PMC *globals :optional :named("globals"),
311 int got_globals :opt_flag) {
2f8fa823 » particle
2007-03-28 [pmc]: Exporter beginning 'import' method
312
b29ad29d » particle
2007-04-03 [pmc] Exporter updates
313 PMC *ns_src, *ns_dest, *ns_globals;
2f8fa823 » particle
2007-03-28 [pmc]: Exporter beginning 'import' method
314
315 if (got_src)
26914e12 » Jimmy Zhuo
2010-05-05 changed interp in pmc class to INTERP for unification
316 PCCINVOKE(INTERP, SELF, "source", PMC *src);
f6d5c3e9 » chromatic
2007-09-04 [PMC] More minor cleanups and reformattings.
317
2f8fa823 » particle
2007-03-28 [pmc]: Exporter beginning 'import' method
318 if (got_dest)
26914e12 » Jimmy Zhuo
2010-05-05 changed interp in pmc class to INTERP for unification
319 PCCINVOKE(INTERP, SELF, "destination", PMC *dest);
f6d5c3e9 » chromatic
2007-09-04 [PMC] More minor cleanups and reformattings.
320
2f8fa823 » particle
2007-03-28 [pmc]: Exporter beginning 'import' method
321 if (got_globals)
26914e12 » Jimmy Zhuo
2010-05-05 changed interp in pmc class to INTERP for unification
322 PCCINVOKE(INTERP, SELF, "globals", PMC *globals);
9318910f » particle
2007-03-26 [pmc] Exporter updates
323
26914e12 » Jimmy Zhuo
2010-05-05 changed interp in pmc class to INTERP for unification
324 GET_ATTR_ns_src(INTERP, SELF, ns_src);
59661f18 » allisonrandal
2008-03-11 [pdd17pmc] Merging the pdd17pmc branch into trunk (r24435 to r26307).
325 if (PMC_IS_NULL(ns_src))
26914e12 » Jimmy Zhuo
2010-05-05 changed interp in pmc class to INTERP for unification
326 Parrot_ex_throw_from_c_args(INTERP, NULL, 0, "source namespace not set");
f6d5c3e9 » chromatic
2007-09-04 [PMC] More minor cleanups and reformattings.
327
26914e12 » Jimmy Zhuo
2010-05-05 changed interp in pmc class to INTERP for unification
328 GET_ATTR_ns_dest(INTERP, SELF, ns_dest);
59661f18 » allisonrandal
2008-03-11 [pdd17pmc] Merging the pdd17pmc branch into trunk (r24435 to r26307).
329 if (PMC_IS_NULL(ns_dest))
26914e12 » Jimmy Zhuo
2010-05-05 changed interp in pmc class to INTERP for unification
330 Parrot_ex_throw_from_c_args(INTERP, NULL, 0,
2255840f » allisonrandal
2008-08-02 [pdd17pmc] Merging the pdd25cx branch into trunk for r26555 to r29949.
331 "destination namespace not set");
2f8fa823 » particle
2007-03-28 [pmc]: Exporter beginning 'import' method
332
26914e12 » Jimmy Zhuo
2010-05-05 changed interp in pmc class to INTERP for unification
333 GET_ATTR_globals(INTERP, SELF, ns_globals);
b29ad29d » particle
2007-04-03 [pmc] Exporter updates
334
26914e12 » Jimmy Zhuo
2010-05-05 changed interp in pmc class to INTERP for unification
335 PCCINVOKE(INTERP, ns_src, "export_to", PMC *ns_dest, PMC *ns_globals);
9255c820 » paultcochrane
2007-03-26 [src] Set svn:keywords and svn:eol-style properties appropriately
336 }
337
338
b29ad29d » particle
2007-04-03 [pmc] Exporter updates
339 } /* end pmclass Exporter */
9255c820 » paultcochrane
2007-03-26 [src] Set svn:keywords and svn:eol-style properties appropriately
340
341 /*
342
343 =back
344
6498378a » particle
2007-04-05 [pmc]: update Exporter documentation based on draft guidelines
345 =head1 STABILITY
346
347 Unstable. This PMC is under active development; major portions of the
348 interface have not yet been completed.
349
9255c820 » paultcochrane
2007-03-26 [src] Set svn:keywords and svn:eol-style properties appropriately
350 =head1 SEE ALSO
351
eae5b2f6 » particle
2007-03-30 [pmc]: documentation overhaul for Exporter
352 F<docs/pdds/pdd17_basic_types.pod>, F<docs/pdds/pdd21_namespaces.pod>.
9255c820 » paultcochrane
2007-03-26 [src] Set svn:keywords and svn:eol-style properties appropriately
353
354 =cut
355
356 */
357
358 /*
359 * Local variables:
360 * c-file-style: "parrot"
361 * End:
1d7dded8 » plobsing
2010-11-29 update C file vim modelines
362 * vim: expandtab shiftwidth=4 cinoptions='\:2=2' :
9255c820 » paultcochrane
2007-03-26 [src] Set svn:keywords and svn:eol-style properties appropriately
363 */
Something went wrong with that request. Please try again.