Branch Coverage

/usr/local/lib/perl5/site_perl/5.26.1/x86_64-linux/XS/Framework.x/i/xs/Hash.h
Criterion Covered Total %
branch 18 34 52.9


line true false branch
26 3 0 Hash (SV* sv, bool policy = INCREMENT) : Sv(sv, policy) { _validate(); }
111 0 0 void clear () { if (sv) hv_clear((HV*)sv); }
117 0 3 if (HvUSEDKEYS(hv)) operator++();
3 0 if (HvUSEDKEYS(hv)) operator++();
123 7 3 if (cur) {
125 0 7 if (cur) return *this;
127 27 7 while (!cur && arr != end) cur = *arr++;
24 3 while (!cur && arr != end) cur = *arr++;
24 10 while (!cur && arr != end) cur = *arr++;
166 3 0 iterator begin () { return sv ? iterator((HV*)sv) : iterator(); }
173 0 3 if (!sv) return;
174 0 3 if (SvTYPE(sv) == SVt_PVHV) return;
175 3 0 if (SvROK(sv)) { // reference to hash?
177 3 0 if (SvTYPE(val) == SVt_PVHV) {
178 3 0 Sv::operator=(val);
182 0 0 if (is_undef()) return reset();
184 0 0 throw std::invalid_argument("SV is not a Hash or Hash reference");