#ifndef SRL_COMMON_H_
#define SRL_COMMON_H_
#include "srl_inline.h"
/* inspired by JSON::XS code */
#if __GNUC__ >= 3
# define expect(expr,value) __builtin_expect((expr), (value))
#else
# define exp
gle sample, since it is small. But, if you are compressing
* many similar files, like a bunch of JSON records that share the same
* structure, you can train a dictionary on ahead of time on some sam
rman E<lt>eric@freesa.orgE<gt>
Some inspiration and code was taken from Marc Lehmann's
excellent JSON::XS module due to obvious overlap in
problem domain.
=head1 ACKNOWLEDGMENT
This module was orig
y
it under the same terms as Perl itself.
Except portions taken from Marc Lehmann's code for the JSON::XS
module, which is licensed under the same terms as this module.
(Many thanks to Marc for inspi
$jsonxs, $msgpack, $dd_noindent, $dd_indent, $cbor
);
my $storable_tag= "strbl";
my $sereal_tag= "srl";
my %meta= (
jxs => {
enc => '$::jsonxs->encode($data);',
dec => '$::jsonx
);',
name => 'JSON::XS OO',
init => sub {
$jsonxs= JSON::XS->new()->allow_nonref();
},
use => 'use JSON::XS qw(decode_json encode_json);',
},
ddl =>
. " - " . $x;
},
} );
}
my %names= (
"JSON::XS" => 'json xs',
"Data::Dumper::Limited" => 'ddl',
"Data::MessagePack"
support and bugfixes)
Zefram
Some inspiration and code was taken from Marc Lehmann's
excellent JSON::XS module due to obvious overlap in
problem domain.
=head1 ACKNOWLEDGMENT
This module was orig
y
it under the same terms as Perl itself.
Except portions taken from Marc Lehmann's code for the JSON::XS
module, which is licensed under the same terms as this module.
(Many thanks to Marc for inspi
do not modify directly!
{
"comment" => "SvIsBOOL() == PL_No, 5.36 and later only (json false)",
"name" => "NO",
"type_name" => "NO",
"type_value" => 52,
do not modify directly!
{
"comment" => "SvIsBOOL() == PL_Yes, 5.36 and later only (json true)",
"name" => "YES",
"type_name" => "YES",
"type_value" => 53,
vIsBOOL() == PL_No, 5.36 and later only (json false)
YES | "5" | 53 | 0x35 | 0b00110101 | SvIsBOOL() == PL_Yes, 5.36 and later only (json true)
RESERVED_0 | "6" | 54
* SvIsBOOL() == PL_No, 5.36 and later only (json false) */
#define SRL_HDR_YES ((U8)53) /* SvIsBOOL() == PL_Yes, 5.36 and later only (json true)*/
/* Note: Can do reserved check with