sv_undef;
}
PUTBACK;
FREETMPS;
LEAVE;
return ret;
}
static inline SV* _get_json_pointer_sv (pTHX_ SV** stack, unsigned stack_idx) {
AV* pointer = newAV();
for (unsigned
ointer_ar = newRV_noinc( (SV*) pointer );
return _call_pv_scalar_1_1(aTHX_ "TOML::XS::_BUILD_JSON_POINTER", pointer_ar);
}
toml_table_t* _get_toml_table_from_sv(pTHX_ SV *self_sv) {
SV *refe
len-1) {
SV* jsonpointer = _get_json_pointer_sv(aTHX_ stack, stack_idx);
SV* errsv = newSVpvf("Cannot descend into non-container! (JSON pointer: %" SVf ")", jsonpointer);
cro
racter> strings.
As of now thrown exceptions are simple character strings
that include, where relevant, a
L<JSON pointer|https://tools.ietf.org/html/rfc6901> to the problematic
data point.
=cut
1;
.
=back
=head1 NOTE ON CHARACTER DECODING
This library mimics the default behaviour of popular JSON modules:
the TOML input to the parser is expected to be a byte string, while the
strings that the
ointer {
my ($msg, $path_ar) = @_;
die sprintf( "%s (JSON pointer: %s)", $msg, _BUILD_JSON_POINTER($path_ar) );
}
sub _BUILD_JSON_POINTER {
my $pieces_ar = shift;
my @pieces = @$pi