… | … | ||
---|---|---|---|
39 | 777 | 39 | 777 |
40 | } | 40 | } |
41 | 41 | ||
42 | $obj = bless { k => 1 }, CBOR::XS::freeze::; | 42 | $obj = bless { k => 1 }, CBOR::XS::freeze::; |
43 | $enc = encode_cbor $obj; | 43 | $enc = encode_cbor $obj; |
44 | print $enc eq (pack "H*", "d818845043424f523a3a58533a3a667265657a65030102") ? "" : "not ", "ok 12 ", (unpack "H*", $enc), "\n"; | 44 | print $enc eq (pack "H*", "d81a845043424f523a3a58533a3a667265657a65030102") ? "" : "not ", "ok 12 ", (unpack "H*", $enc), "\n"; |
45 | 45 | ||
46 | $dec = decode_cbor $enc; | 46 | $dec = decode_cbor $enc; |
47 | print $dec eq 777 ? "" : "not ", "ok 19\n"; | 47 | print $dec eq 777 ? "" : "not ", "ok 19\n"; |
48 | 48 | ||
49 | print "ok 20\n"; | 49 | print "ok 20\n"; |
– | Removed lines |
+ | Added lines |
< | Changed lines |
> | Changed lines |