line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
#include "EXTERN.h" |
2
|
|
|
|
|
|
|
#include "perl.h" |
3
|
|
|
|
|
|
|
#include "XSUB.h" |
4
|
|
|
|
|
|
|
|
5
|
|
|
|
|
|
|
#define NEED_SvRX |
6
|
|
|
|
|
|
|
#include "ppport.h" |
7
|
|
|
|
|
|
|
|
8
|
|
|
|
|
|
|
#include "mop.h" |
9
|
|
|
|
|
|
|
|
10
|
|
|
|
|
|
|
#ifndef MGf_COPY |
11
|
|
|
|
|
|
|
# define MGf_COPY 0 |
12
|
|
|
|
|
|
|
#endif |
13
|
|
|
|
|
|
|
|
14
|
|
|
|
|
|
|
#ifndef MGf_DUP |
15
|
|
|
|
|
|
|
# define MGf_DUP 0 |
16
|
|
|
|
|
|
|
#endif |
17
|
|
|
|
|
|
|
|
18
|
|
|
|
|
|
|
#ifndef MGf_LOCAL |
19
|
|
|
|
|
|
|
# define MGf_LOCAL 0 |
20
|
|
|
|
|
|
|
#endif |
21
|
|
|
|
|
|
|
|
22
|
|
|
|
|
|
|
STATIC int unset_export_flag (pTHX_ SV *sv, MAGIC *mg); |
23
|
|
|
|
|
|
|
|
24
|
|
|
|
|
|
|
STATIC MGVTBL export_flag_vtbl = { |
25
|
|
|
|
|
|
|
NULL, /* get */ |
26
|
|
|
|
|
|
|
unset_export_flag, /* set */ |
27
|
|
|
|
|
|
|
NULL, /* len */ |
28
|
|
|
|
|
|
|
NULL, /* clear */ |
29
|
|
|
|
|
|
|
NULL, /* free */ |
30
|
|
|
|
|
|
|
#if MGf_COPY |
31
|
|
|
|
|
|
|
NULL, /* copy */ |
32
|
|
|
|
|
|
|
#endif |
33
|
|
|
|
|
|
|
#if MGf_DUP |
34
|
|
|
|
|
|
|
NULL, /* dup */ |
35
|
|
|
|
|
|
|
#endif |
36
|
|
|
|
|
|
|
#if MGf_LOCAL |
37
|
|
|
|
|
|
|
NULL, /* local */ |
38
|
|
|
|
|
|
|
#endif |
39
|
|
|
|
|
|
|
}; |
40
|
|
|
|
|
|
|
|
41
|
|
|
|
|
|
|
STATIC bool |
42
|
1125
|
|
|
|
|
|
export_flag_is_set (pTHX_ SV *sv) |
43
|
|
|
|
|
|
|
{ |
44
|
|
|
|
|
|
|
MAGIC *mg, *moremagic; |
45
|
|
|
|
|
|
|
|
46
|
1125
|
50
|
|
|
|
|
if (SvTYPE(SvRV(sv)) != SVt_PVGV) { |
47
|
0
|
|
|
|
|
|
return 0; |
48
|
|
|
|
|
|
|
} |
49
|
|
|
|
|
|
|
|
50
|
1125
|
100
|
|
|
|
|
for (mg = SvMAGIC(SvRV(sv)); mg; mg = moremagic) { |
51
|
1026
|
|
|
|
|
|
moremagic = mg->mg_moremagic; |
52
|
|
|
|
|
|
|
|
53
|
1026
|
50
|
|
|
|
|
if (mg->mg_type == PERL_MAGIC_ext && mg->mg_virtual == &export_flag_vtbl) { |
|
|
50
|
|
|
|
|
|
54
|
1026
|
|
|
|
|
|
break; |
55
|
|
|
|
|
|
|
} |
56
|
|
|
|
|
|
|
} |
57
|
|
|
|
|
|
|
|
58
|
1125
|
|
|
|
|
|
return !!mg; |
59
|
|
|
|
|
|
|
} |
60
|
|
|
|
|
|
|
|
61
|
|
|
|
|
|
|
STATIC int |
62
|
22
|
|
|
|
|
|
unset_export_flag (pTHX_ SV *sv, MAGIC *mymg) |
63
|
|
|
|
|
|
|
{ |
64
|
22
|
|
|
|
|
|
MAGIC *mg, *prevmagic = NULL, *moremagic = NULL; |
65
|
|
|
|
|
|
|
|
66
|
22
|
50
|
|
|
|
|
for (mg = SvMAGIC(sv); mg; prevmagic = mg, mg = moremagic) { |
67
|
22
|
|
|
|
|
|
moremagic = mg->mg_moremagic; |
68
|
|
|
|
|
|
|
|
69
|
22
|
50
|
|
|
|
|
if (mg == mymg) { |
70
|
22
|
|
|
|
|
|
break; |
71
|
|
|
|
|
|
|
} |
72
|
|
|
|
|
|
|
} |
73
|
|
|
|
|
|
|
|
74
|
22
|
50
|
|
|
|
|
if (!mg) { |
75
|
0
|
|
|
|
|
|
return 0; |
76
|
|
|
|
|
|
|
} |
77
|
|
|
|
|
|
|
|
78
|
22
|
50
|
|
|
|
|
if (prevmagic) { |
79
|
0
|
|
|
|
|
|
prevmagic->mg_moremagic = moremagic; |
80
|
|
|
|
|
|
|
} |
81
|
|
|
|
|
|
|
else { |
82
|
22
|
|
|
|
|
|
SvMAGIC_set(sv, moremagic); |
83
|
|
|
|
|
|
|
} |
84
|
|
|
|
|
|
|
|
85
|
22
|
|
|
|
|
|
mg->mg_moremagic = NULL; |
86
|
|
|
|
|
|
|
|
87
|
22
|
|
|
|
|
|
Safefree (mg); |
88
|
|
|
|
|
|
|
|
89
|
22
|
|
|
|
|
|
return 0; |
90
|
|
|
|
|
|
|
} |
91
|
|
|
|
|
|
|
|
92
|
|
|
|
|
|
|
XS_EXTERNAL(boot_Class__MOP); |
93
|
|
|
|
|
|
|
XS_EXTERNAL(boot_Class__MOP__Mixin__HasAttributes); |
94
|
|
|
|
|
|
|
XS_EXTERNAL(boot_Class__MOP__Mixin__HasMethods); |
95
|
|
|
|
|
|
|
XS_EXTERNAL(boot_Class__MOP__Package); |
96
|
|
|
|
|
|
|
XS_EXTERNAL(boot_Class__MOP__Mixin__AttributeCore); |
97
|
|
|
|
|
|
|
XS_EXTERNAL(boot_Class__MOP__Method); |
98
|
|
|
|
|
|
|
XS_EXTERNAL(boot_Class__MOP__Method__Inlined); |
99
|
|
|
|
|
|
|
XS_EXTERNAL(boot_Class__MOP__Method__Generated); |
100
|
|
|
|
|
|
|
XS_EXTERNAL(boot_Class__MOP__Class); |
101
|
|
|
|
|
|
|
XS_EXTERNAL(boot_Class__MOP__Attribute); |
102
|
|
|
|
|
|
|
XS_EXTERNAL(boot_Class__MOP__Instance); |
103
|
|
|
|
|
|
|
XS_EXTERNAL(boot_Moose__Meta__Role__Application__ToInstance); |
104
|
|
|
|
|
|
|
|
105
|
|
|
|
|
|
|
MODULE = Moose PACKAGE = Moose::Exporter |
106
|
|
|
|
|
|
|
|
107
|
|
|
|
|
|
|
PROTOTYPES: DISABLE |
108
|
|
|
|
|
|
|
|
109
|
|
|
|
|
|
|
BOOT: |
110
|
451
|
|
|
|
|
|
mop_prehash_keys(); |
111
|
|
|
|
|
|
|
|
112
|
451
|
|
|
|
|
|
MOP_CALL_BOOT (boot_Class__MOP); |
113
|
451
|
|
|
|
|
|
MOP_CALL_BOOT (boot_Class__MOP__Mixin__HasAttributes); |
114
|
451
|
|
|
|
|
|
MOP_CALL_BOOT (boot_Class__MOP__Mixin__HasMethods); |
115
|
451
|
|
|
|
|
|
MOP_CALL_BOOT (boot_Class__MOP__Package); |
116
|
451
|
|
|
|
|
|
MOP_CALL_BOOT (boot_Class__MOP__Mixin__AttributeCore); |
117
|
451
|
|
|
|
|
|
MOP_CALL_BOOT (boot_Class__MOP__Method); |
118
|
451
|
|
|
|
|
|
MOP_CALL_BOOT (boot_Class__MOP__Method__Inlined); |
119
|
451
|
|
|
|
|
|
MOP_CALL_BOOT (boot_Class__MOP__Method__Generated); |
120
|
451
|
|
|
|
|
|
MOP_CALL_BOOT (boot_Class__MOP__Class); |
121
|
451
|
|
|
|
|
|
MOP_CALL_BOOT (boot_Class__MOP__Attribute); |
122
|
451
|
|
|
|
|
|
MOP_CALL_BOOT (boot_Class__MOP__Instance); |
123
|
451
|
|
|
|
|
|
MOP_CALL_BOOT (boot_Moose__Meta__Role__Application__ToInstance); |
124
|
|
|
|
|
|
|
|
125
|
|
|
|
|
|
|
void |
126
|
|
|
|
|
|
|
_flag_as_reexport (SV *sv) |
127
|
|
|
|
|
|
|
CODE: |
128
|
5383
|
|
|
|
|
|
sv_magicext(SvRV(sv), NULL, PERL_MAGIC_ext, &export_flag_vtbl, NULL, 0); |
129
|
|
|
|
|
|
|
|
130
|
|
|
|
|
|
|
bool |
131
|
|
|
|
|
|
|
_export_is_flagged (SV *sv) |
132
|
|
|
|
|
|
|
CODE: |
133
|
1125
|
|
|
|
|
|
RETVAL = export_flag_is_set(aTHX_ sv); |
134
|
|
|
|
|
|
|
OUTPUT: |
135
|
|
|
|
|
|
|
RETVAL |
136
|
|
|
|
|
|
|
|
137
|
|
|
|
|
|
|
MODULE = Moose PACKAGE = Moose::Util::TypeConstraints::Builtins |
138
|
|
|
|
|
|
|
|
139
|
|
|
|
|
|
|
bool |
140
|
|
|
|
|
|
|
_RegexpRef (SV *sv=NULL) |
141
|
|
|
|
|
|
|
INIT: |
142
|
368
|
100
|
|
|
|
|
if (!items) { |
143
|
3
|
50
|
|
|
|
|
sv = DEFSV; |
144
|
|
|
|
|
|
|
} |
145
|
|
|
|
|
|
|
CODE: |
146
|
368
|
|
|
|
|
|
RETVAL = SvRXOK(sv); |
147
|
|
|
|
|
|
|
OUTPUT: |
148
|
|
|
|
|
|
|
RETVAL |