File Coverage

ext/B/const-xs.inc
Criterion Covered Total %
statement 11 11 100.0
branch n/a
condition n/a
subroutine n/a
total 11 11 100.0


line stmt bran cond sub time code
1           BOOT:
2           {
3           #ifdef dTHX
4           dTHX;
5           #endif
6 5096         HV *symbol_table = get_hv("B::", GV_ADD);
7 5096         AV *push = get_av("B::EXPORT_OK", GV_ADD);
8           HE *he;
9            
10           static const struct iv_s values_for_iv[] =
11           {
12           { "HEf_SVKEY", 9, HEf_SVKEY },
13           { NULL, 0, 0 } };
14           const struct iv_s *value_for_iv = values_for_iv;
15            
16           static const struct uv_s values_for_uv[] =
17           {
18           { "SVTYPEMASK", 10, SVTYPEMASK },
19           { "SVt_PVGV", 8, SVt_PVGV },
20           { "SVt_PVHV", 8, SVt_PVHV },
21           { "PAD_FAKELEX_ANON", 16, PAD_FAKELEX_ANON },
22           { "PAD_FAKELEX_MULTI", 17, PAD_FAKELEX_MULTI },
23           { "CXt_NULL", 8, CXt_NULL },
24           { "CXt_WHEN", 8, CXt_WHEN },
25           { "CXt_BLOCK", 9, CXt_BLOCK },
26           { "CXt_GIVEN", 9, CXt_GIVEN },
27           { "CXt_LOOP_FOR", 12, CXt_LOOP_FOR },
28           { "CXt_LOOP_PLAIN", 14, CXt_LOOP_PLAIN },
29           { "CXt_LOOP_LAZYSV", 15, CXt_LOOP_LAZYSV },
30           { "CXt_LOOP_LAZYIV", 15, CXt_LOOP_LAZYIV },
31           { "CXt_SUB", 7, CXt_SUB },
32           { "CXt_FORMAT", 10, CXt_FORMAT },
33           { "CXt_EVAL", 8, CXt_EVAL },
34           { "CXt_SUBST", 9, CXt_SUBST },
35           { "CXp_MULTICALL", 13, CXp_MULTICALL },
36           { "CXp_HASARGS", 11, CXp_HASARGS },
37           { "CXp_SUB_RE", 10, CXp_SUB_RE },
38           { "CXp_SUB_RE_FAKE", 15, CXp_SUB_RE_FAKE },
39           { "CXp_REAL", 8, CXp_REAL },
40           { "CXp_TRYBLOCK", 12, CXp_TRYBLOCK },
41           { "CXp_FOR_DEF", 11, CXp_FOR_DEF },
42           { "CXp_ONCE", 8, CXp_ONCE },
43           { "G_SCALAR", 8, G_SCALAR },
44           { "G_ARRAY", 7, G_ARRAY },
45           { "G_VOID", 6, G_VOID },
46           { "G_WANT", 6, G_WANT },
47           { "G_DISCARD", 9, G_DISCARD },
48           { "G_EVAL", 6, G_EVAL },
49           { "G_NOARGS", 8, G_NOARGS },
50           { "G_KEEPERR", 9, G_KEEPERR },
51           { "G_NODEBUG", 9, G_NODEBUG },
52           { "G_METHOD", 8, G_METHOD },
53           { "G_FAKINGEVAL", 12, G_FAKINGEVAL },
54           { "G_UNDEF_FILL", 12, G_UNDEF_FILL },
55           { "G_WRITING_TO_STDERR", 19, G_WRITING_TO_STDERR },
56           { "G_RE_REPARSING", 14, G_RE_REPARSING },
57           { "G_METHOD_NAMED", 14, G_METHOD_NAMED },
58           { "EVAL_NULL", 9, EVAL_NULL },
59           { "EVAL_INEVAL", 11, EVAL_INEVAL },
60           { "EVAL_WARNONLY", 13, EVAL_WARNONLY },
61           { "EVAL_KEEPERR", 12, EVAL_KEEPERR },
62           { "EVAL_INREQUIRE", 14, EVAL_INREQUIRE },
63           { "EVAL_RE_REPARSING", 17, EVAL_RE_REPARSING },
64           { "PERLSI_UNDEF", 12, PERLSI_UNDEF },
65           { "PERLSI_MAIN", 11, PERLSI_MAIN },
66           { "PERLSI_MAGIC", 12, PERLSI_MAGIC },
67           { "PERLSI_SORT", 11, PERLSI_SORT },
68           { "PERLSI_SIGNAL", 13, PERLSI_SIGNAL },
69           { "PERLSI_OVERLOAD", 15, PERLSI_OVERLOAD },
70           { "PERLSI_DESTROY", 14, PERLSI_DESTROY },
71           { "PERLSI_WARNHOOK", 15, PERLSI_WARNHOOK },
72           { "PERLSI_DIEHOOK", 14, PERLSI_DIEHOOK },
73           { "PERLSI_REQUIRE", 14, PERLSI_REQUIRE },
74           { "CVf_METHOD", 10, CVf_METHOD },
75           { "CVf_LVALUE", 10, CVf_LVALUE },
76           { "CVf_CONST", 9, CVf_CONST },
77           { "CVf_ISXSUB", 10, CVf_ISXSUB },
78           { "CVf_WEAKOUTSIDE", 15, CVf_WEAKOUTSIDE },
79           { "CVf_CLONE", 9, CVf_CLONE },
80           { "CVf_CLONED", 10, CVf_CLONED },
81           { "CVf_ANON", 8, CVf_ANON },
82           { "CVf_UNIQUE", 10, CVf_UNIQUE },
83           { "CVf_NODEBUG", 11, CVf_NODEBUG },
84           { "CVf_CVGV_RC", 11, CVf_CVGV_RC },
85           { "CVf_DYNFILE", 11, CVf_DYNFILE },
86           { "CVf_AUTOLOAD", 12, CVf_AUTOLOAD },
87           { "CVf_HASEVAL", 11, CVf_HASEVAL },
88           { "CVf_NAMED", 9, CVf_NAMED },
89           { "GVf_INTRO", 9, GVf_INTRO },
90           { "GVf_MULTI", 9, GVf_MULTI },
91           { "GVf_ASSUMECV", 12, GVf_ASSUMECV },
92           { "GVf_IN_PAD", 10, GVf_IN_PAD },
93           { "GVf_IMPORTED_SV", 15, GVf_IMPORTED_SV },
94           { "GVf_IMPORTED_AV", 15, GVf_IMPORTED_AV },
95           { "GVf_IMPORTED_HV", 15, GVf_IMPORTED_HV },
96           { "GVf_IMPORTED_CV", 15, GVf_IMPORTED_CV },
97           { "OPf_WANT", 8, OPf_WANT },
98           { "OPf_WANT_VOID", 13, OPf_WANT_VOID },
99           { "OPf_WANT_SCALAR", 15, OPf_WANT_SCALAR },
100           { "OPf_WANT_LIST", 13, OPf_WANT_LIST },
101           { "OPf_KIDS", 8, OPf_KIDS },
102           { "OPf_PARENS", 10, OPf_PARENS },
103           { "OPf_REF", 7, OPf_REF },
104           { "OPf_MOD", 7, OPf_MOD },
105           { "OPf_STACKED", 11, OPf_STACKED },
106           { "OPf_SPECIAL", 11, OPf_SPECIAL },
107           { "OPpLVAL_INTRO", 13, OPpLVAL_INTRO },
108           { "OPpTARGET_MY", 12, OPpTARGET_MY },
109           { "OPpREFCOUNTED", 13, OPpREFCOUNTED },
110           { "OPpASSIGN_COMMON", 16, OPpASSIGN_COMMON },
111           { "OPpASSIGN_BACKWARDS", 19, OPpASSIGN_BACKWARDS },
112           { "OPpASSIGN_CV_TO_GV", 18, OPpASSIGN_CV_TO_GV },
113           { "OPpRUNTIME", 10, OPpRUNTIME },
114           { "OPpTRANS_FROM_UTF", 17, OPpTRANS_FROM_UTF },
115           { "OPpTRANS_TO_UTF", 15, OPpTRANS_TO_UTF },
116           { "OPpTRANS_IDENTICAL", 18, OPpTRANS_IDENTICAL },
117           { "OPpTRANS_SQUASH", 15, OPpTRANS_SQUASH },
118           { "OPpTRANS_COMPLEMENT", 19, OPpTRANS_COMPLEMENT },
119           { "OPpTRANS_GROWS", 14, OPpTRANS_GROWS },
120           { "OPpTRANS_DELETE", 15, OPpTRANS_DELETE },
121           { "OPpREPEAT_DOLIST", 16, OPpREPEAT_DOLIST },
122           { "OPpDEREF", 8, OPpDEREF },
123           { "OPpDEREF_AV", 11, OPpDEREF_AV },
124           { "OPpDEREF_HV", 11, OPpDEREF_HV },
125           { "OPpDEREF_SV", 11, OPpDEREF_SV },
126           { "OPpENTERSUB_DB", 14, OPpENTERSUB_DB },
127           { "OPpENTERSUB_HASTARG", 19, OPpENTERSUB_HASTARG },
128           { "OPpENTERSUB_INARGS", 18, OPpENTERSUB_INARGS },
129           { "OPpENTERSUB_AMPER", 17, OPpENTERSUB_AMPER },
130           { "OPpENTERSUB_NOPAREN", 19, OPpENTERSUB_NOPAREN },
131           { "OPpMAY_RETURN_CONSTANT", 22, OPpMAY_RETURN_CONSTANT },
132           { "OPpEARLY_CV", 11, OPpEARLY_CV },
133           { "OPpLVAL_DEFER", 13, OPpLVAL_DEFER },
134           { "OPpOUR_INTRO", 12, OPpOUR_INTRO },
135           { "OPpMAYBE_LVSUB", 14, OPpMAYBE_LVSUB },
136           { "OPpTRUEBOOL", 11, OPpTRUEBOOL },
137           { "OPpMAYBE_TRUEBOOL", 17, OPpMAYBE_TRUEBOOL },
138           { "OPpSUBSTR_REPL_FIRST", 20, OPpSUBSTR_REPL_FIRST },
139           { "OPpPAD_STATE", 12, OPpPAD_STATE },
140           { "OPpPADRANGE_COUNTMASK", 21, OPpPADRANGE_COUNTMASK },
141           { "OPpPADRANGE_COUNTSHIFT", 22, OPpPADRANGE_COUNTSHIFT },
142           { "OPpDONT_INIT_GV", 15, OPpDONT_INIT_GV },
143           { "OPpALLOW_FAKE", 13, OPpALLOW_FAKE },
144           { "OPpITER_REVERSED", 16, OPpITER_REVERSED },
145           { "OPpITER_DEF", 11, OPpITER_DEF },
146           { "OPpCONST_NOVER", 14, OPpCONST_NOVER },
147           { "OPpCONST_SHORTCIRCUIT", 21, OPpCONST_SHORTCIRCUIT },
148           { "OPpCONST_STRICT", 15, OPpCONST_STRICT },
149           { "OPpCONST_ENTERED", 16, OPpCONST_ENTERED },
150           { "OPpCONST_BARE", 13, OPpCONST_BARE },
151           { "OPpCONST_FOLDED", 15, OPpCONST_FOLDED },
152           { "OPpFLIP_LINENUM", 15, OPpFLIP_LINENUM },
153           { "OPpLIST_GUESSED", 15, OPpLIST_GUESSED },
154           { "OPpSLICE", 8, OPpSLICE },
155           { "OPpEXISTS_SUB", 13, OPpEXISTS_SUB },
156           { "OPpSORT_NUMERIC", 15, OPpSORT_NUMERIC },
157           { "OPpSORT_INTEGER", 15, OPpSORT_INTEGER },
158           { "OPpSORT_REVERSE", 15, OPpSORT_REVERSE },
159           { "OPpSORT_INPLACE", 15, OPpSORT_INPLACE },
160           { "OPpSORT_DESCEND", 15, OPpSORT_DESCEND },
161           { "OPpSORT_QSORT", 13, OPpSORT_QSORT },
162           { "OPpSORT_STABLE", 14, OPpSORT_STABLE },
163           { "OPpREVERSE_INPLACE", 18, OPpREVERSE_INPLACE },
164           { "OPpOPEN_IN_RAW", 14, OPpOPEN_IN_RAW },
165           { "OPpOPEN_IN_CRLF", 15, OPpOPEN_IN_CRLF },
166           { "OPpOPEN_OUT_RAW", 15, OPpOPEN_OUT_RAW },
167           { "OPpOPEN_OUT_CRLF", 16, OPpOPEN_OUT_CRLF },
168           { "OPpHUSH_VMSISH", 14, OPpHUSH_VMSISH },
169           { "OPpEXIT_VMSISH", 14, OPpEXIT_VMSISH },
170           { "OPpFT_ACCESS", 12, OPpFT_ACCESS },
171           { "OPpFT_STACKED", 13, OPpFT_STACKED },
172           { "OPpFT_STACKING", 14, OPpFT_STACKING },
173           { "OPpFT_AFTER_t", 13, OPpFT_AFTER_t },
174           { "OPpGREP_LEX", 11, OPpGREP_LEX },
175           { "OPpEVAL_HAS_HH", 14, OPpEVAL_HAS_HH },
176           { "OPpEVAL_UNICODE", 15, OPpEVAL_UNICODE },
177           { "OPpEVAL_BYTES", 13, OPpEVAL_BYTES },
178           { "OPpEVAL_COPHH", 13, OPpEVAL_COPHH },
179           { "OPpEVAL_RE_REPARSING", 20, OPpEVAL_RE_REPARSING },
180           { "OPpOFFBYONE", 11, OPpOFFBYONE },
181           { "OPpCOREARGS_DEREF1", 18, OPpCOREARGS_DEREF1 },
182           { "OPpCOREARGS_DEREF2", 18, OPpCOREARGS_DEREF2 },
183           { "OPpCOREARGS_SCALARMOD", 21, OPpCOREARGS_SCALARMOD },
184           { "OPpCOREARGS_PUSHMARK", 20, OPpCOREARGS_PUSHMARK },
185           { "OPpPV_IS_UTF8", 13, OPpPV_IS_UTF8 },
186           { "OPpSPLIT_IMPLIM", 15, OPpSPLIT_IMPLIM },
187           { "PMf_RETAINT", 11, PMf_RETAINT },
188           { "PMf_ONCE", 8, PMf_ONCE },
189           { "PMf_USED", 8, PMf_USED },
190           { "PMf_CONST", 9, PMf_CONST },
191           { "PMf_KEEP", 8, PMf_KEEP },
192           { "PMf_GLOBAL", 10, PMf_GLOBAL },
193           { "PMf_CONTINUE", 12, PMf_CONTINUE },
194           { "PMf_EVAL", 8, PMf_EVAL },
195           { "PMf_NONDESTRUCT", 15, PMf_NONDESTRUCT },
196           { "PMf_HAS_CV", 10, PMf_HAS_CV },
197           { "PMf_CODELIST_PRIVATE", 20, PMf_CODELIST_PRIVATE },
198           { "PMf_IS_QR", 9, PMf_IS_QR },
199           { "PMf_USE_RE_EVAL", 15, PMf_USE_RE_EVAL },
200           { "OA_MARK", 7, OA_MARK },
201           { "OA_FOLDCONST", 12, OA_FOLDCONST },
202           { "OA_RETSCALAR", 12, OA_RETSCALAR },
203           { "OA_TARGET", 9, OA_TARGET },
204           { "OA_TARGLEX", 10, OA_TARGLEX },
205           { "OA_OTHERINT", 11, OA_OTHERINT },
206           { "OA_DANGEROUS", 12, OA_DANGEROUS },
207           { "OA_DEFGV", 8, OA_DEFGV },
208           { "OCSHIFT", 7, OCSHIFT },
209           { "OA_CLASS_MASK", 13, OA_CLASS_MASK },
210           { "OA_BASEOP", 9, OA_BASEOP },
211           { "OA_UNOP", 7, OA_UNOP },
212           { "OA_BINOP", 8, OA_BINOP },
213           { "OA_LOGOP", 8, OA_LOGOP },
214           { "OA_LISTOP", 9, OA_LISTOP },
215           { "OA_PMOP", 7, OA_PMOP },
216           { "OA_SVOP", 7, OA_SVOP },
217           { "OA_PADOP", 8, OA_PADOP },
218           { "OA_PVOP_OR_SVOP", 15, OA_PVOP_OR_SVOP },
219           { "OA_LOOP", 7, OA_LOOP },
220           { "OA_COP", 6, OA_COP },
221           { "OA_BASEOP_OR_UNOP", 17, OA_BASEOP_OR_UNOP },
222           { "OA_FILESTATOP", 13, OA_FILESTATOP },
223           { "OA_LOOPEXOP", 11, OA_LOOPEXOP },
224           { "OASHIFT", 7, OASHIFT },
225           { "OA_SCALAR", 9, OA_SCALAR },
226           { "OA_LIST", 7, OA_LIST },
227           { "OA_AVREF", 8, OA_AVREF },
228           { "OA_HVREF", 8, OA_HVREF },
229           { "OA_CVREF", 8, OA_CVREF },
230           { "OA_FILEREF", 10, OA_FILEREF },
231           { "OA_SCALARREF", 12, OA_SCALARREF },
232           { "OA_OPTIONAL", 11, OA_OPTIONAL },
233           { "PERL_LOADMOD_DENY", 17, PERL_LOADMOD_DENY },
234           { "PERL_LOADMOD_NOIMPORT", 21, PERL_LOADMOD_NOIMPORT },
235           { "PERL_LOADMOD_IMPORT_OPS", 23, PERL_LOADMOD_IMPORT_OPS },
236           { "BHKf_bhk_start", 14, BHKf_bhk_start },
237           { "BHKf_bhk_pre_end", 16, BHKf_bhk_pre_end },
238           { "BHKf_bhk_post_end", 17, BHKf_bhk_post_end },
239           { "BHKf_bhk_eval", 13, BHKf_bhk_eval },
240           { "RV2CVOPCV_MARK_EARLY", 20, RV2CVOPCV_MARK_EARLY },
241           { "RV2CVOPCV_RETURN_NAME_GV", 24, RV2CVOPCV_RETURN_NAME_GV },
242           { "OP_LVALUE_NO_CROAK", 18, OP_LVALUE_NO_CROAK },
243           { "XOPf_xop_name", 13, XOPf_xop_name },
244           { "XOPf_xop_desc", 13, XOPf_xop_desc },
245           { "XOPf_xop_class", 14, XOPf_xop_class },
246           { "XOPf_xop_peep", 13, XOPf_xop_peep },
247           { "RXf_PMf_STD_PMMOD_SHIFT", 23, RXf_PMf_STD_PMMOD_SHIFT },
248           { "RXf_PMf_MULTILINE", 17, RXf_PMf_MULTILINE },
249           { "RXf_PMf_SINGLELINE", 18, RXf_PMf_SINGLELINE },
250           { "RXf_PMf_FOLD", 12, RXf_PMf_FOLD },
251           { "RXf_PMf_EXTENDED", 16, RXf_PMf_EXTENDED },
252           { "RXf_PMf_KEEPCOPY", 16, RXf_PMf_KEEPCOPY },
253           { "RXf_PMf_CHARSET", 15, RXf_PMf_CHARSET },
254           { "RXf_PMf_SPLIT", 13, RXf_PMf_SPLIT },
255           { "PMf_MULTILINE", 13, PMf_MULTILINE },
256           { "PMf_SINGLELINE", 14, PMf_SINGLELINE },
257           { "PMf_FOLD", 8, PMf_FOLD },
258           { "PMf_EXTENDED", 12, PMf_EXTENDED },
259           { "PMf_KEEPCOPY", 12, PMf_KEEPCOPY },
260           { "PMf_CHARSET", 11, PMf_CHARSET },
261           { "PMf_SPLIT", 9, PMf_SPLIT },
262           { "RXf_SPLIT", 9, RXf_SPLIT },
263           { "RXf_ANCH_BOL", 12, RXf_ANCH_BOL },
264           { "RXf_ANCH_MBOL", 13, RXf_ANCH_MBOL },
265           { "RXf_ANCH_SBOL", 13, RXf_ANCH_SBOL },
266           { "RXf_ANCH_GPOS", 13, RXf_ANCH_GPOS },
267           { "RXf_GPOS_SEEN", 13, RXf_GPOS_SEEN },
268           { "RXf_GPOS_FLOAT", 14, RXf_GPOS_FLOAT },
269           { "RXf_NO_INPLACE_SUBST", 20, RXf_NO_INPLACE_SUBST },
270           { "RXf_EVAL_SEEN", 13, RXf_EVAL_SEEN },
271           { "RXf_CANY_SEEN", 13, RXf_CANY_SEEN },
272           { "RXf_NOSCAN", 10, RXf_NOSCAN },
273           { "RXf_CHECK_ALL", 13, RXf_CHECK_ALL },
274           { "RXf_MATCH_UTF8", 14, RXf_MATCH_UTF8 },
275           { "RXf_USE_INTUIT_NOML", 19, RXf_USE_INTUIT_NOML },
276           { "RXf_USE_INTUIT_ML", 17, RXf_USE_INTUIT_ML },
277           { "RXf_INTUIT_TAIL", 15, RXf_INTUIT_TAIL },
278           { "RXf_COPY_DONE", 13, RXf_COPY_DONE },
279           { "RXf_TAINTED_SEEN", 16, RXf_TAINTED_SEEN },
280           { "RXf_TAINTED", 11, RXf_TAINTED },
281           { "RXf_START_ONLY", 14, RXf_START_ONLY },
282           { "RXf_SKIPWHITE", 13, RXf_SKIPWHITE },
283           { "RXf_WHITE", 9, RXf_WHITE },
284           { "SVf_IOK", 7, SVf_IOK },
285           { "SVf_NOK", 7, SVf_NOK },
286           { "SVf_POK", 7, SVf_POK },
287           { "SVf_ROK", 7, SVf_ROK },
288           { "SVp_IOK", 7, SVp_IOK },
289           { "SVp_NOK", 7, SVp_NOK },
290           { "SVp_POK", 7, SVp_POK },
291           { "SVp_SCREAM", 10, SVp_SCREAM },
292           { "SVf_IsCOW", 9, SVf_IsCOW },
293           { "SVs_PADTMP", 10, SVs_PADTMP },
294           { "SVs_PADSTALE", 12, SVs_PADSTALE },
295           { "SVpad_TYPED", 11, SVpad_TYPED },
296           { "SVs_PADMY", 9, SVs_PADMY },
297           { "SVpad_OUR", 9, SVpad_OUR },
298           { "SVs_TEMP", 8, SVs_TEMP },
299           { "SVs_OBJECT", 10, SVs_OBJECT },
300           { "SVs_GMG", 7, SVs_GMG },
301           { "SVs_SMG", 7, SVs_SMG },
302           { "SVs_RMG", 7, SVs_RMG },
303           { "SVf_FAKE", 8, SVf_FAKE },
304           { "SVf_OOK", 7, SVf_OOK },
305           { "SVf_BREAK", 9, SVf_BREAK },
306           { "SVf_READONLY", 12, SVf_READONLY },
307           { "SVf_AMAGIC", 10, SVf_AMAGIC },
308           { "SVf_UTF8", 8, SVf_UTF8 },
309           { "SVf_IVisUV", 10, SVf_IVisUV },
310           { "SVpad_STATE", 11, SVpad_STATE },
311           { NULL, 0, 0 } };
312           const struct uv_s *value_for_uv = values_for_uv;
313 15288         while (value_for_iv->name) {
314 5096         he = _add_symbol(aTHX_ symbol_table, value_for_iv->name,
315           value_for_iv->namelen, newSViv(value_for_iv->value));
316 5096         av_push(push, newSVhek(HeKEY_hek(he)));
317 5096         ++value_for_iv;
318           }
319 1498224         while (value_for_uv->name) {
320 1493128         he = _add_symbol(aTHX_ symbol_table, value_for_uv->name,
321           value_for_uv->namelen, newSVuv(value_for_uv->value));
322 1493128         av_push(push, newSVhek(HeKEY_hek(he)));
323 1493128         ++value_for_uv;
324           }
325           if (C_ARRAY_LENGTH(values_for_notfound) > 1) {
326           #ifndef SYMBIAN
327           HV *const _missing = get_missing_hash(aTHX);
328           #endif
329           const struct notfound_s *value_for_notfound = values_for_notfound;
330           do {
331            
332           /* Need to add prototypes, else parsing will vary by platform. */
333           HE *he = (HE*) hv_common_key_len(symbol_table,
334           value_for_notfound->name,
335           value_for_notfound->namelen,
336           HV_FETCH_LVALUE, NULL, 0);
337           SV *sv;
338           #ifndef SYMBIAN
339           HEK *hek;
340           #endif
341           if (!he) {
342           Perl_croak(aTHX_
343           "Couldn't add key '%s' to %%B::",
344           value_for_notfound->name);
345           }
346           sv = HeVAL(he);
347           if (!SvOK(sv) && SvTYPE(sv) != SVt_PVGV) {
348           /* Nothing was here before, so mark a prototype of "" */
349           sv_setpvn(sv, "", 0);
350           } else if (SvPOK(sv) && SvCUR(sv) == 0) {
351           /* There is already a prototype of "" - do nothing */
352           } else {
353           /* Someone has been here before us - have to make a real
354           typeglob. */
355           /* It turns out to be incredibly hard to deal with all the
356           corner cases of sub foo (); and reporting errors correctly,
357           so lets cheat a bit. Start with a constant subroutine */
358           CV *cv = newCONSTSUB(symbol_table,
359           value_for_notfound->name,
360           &PL_sv_yes);
361           /* and then turn it into a non constant declaration only. */
362           SvREFCNT_dec(CvXSUBANY(cv).any_ptr);
363           CvCONST_off(cv);
364           CvXSUB(cv) = NULL;
365           CvXSUBANY(cv).any_ptr = NULL;
366           }
367           #ifndef SYMBIAN
368           hek = HeKEY_hek(he);
369           if (!hv_common(_missing, NULL, HEK_KEY(hek),
370           HEK_LEN(hek), HEK_FLAGS(hek), HV_FETCH_ISSTORE,
371           &PL_sv_yes, HEK_HASH(hek)))
372           Perl_croak(aTHX_ "Couldn't add key '%s' to missing_hash",
373           value_for_notfound->name);
374           #endif
375           av_push(push, newSVhek(hek));
376           } while ((++value_for_notfound)->name);
377           }
378           /* As we've been creating subroutines, we better invalidate any cached
379           methods */
380 5096         mro_method_changed_in(symbol_table);
381           }