PathrockNetwork Gno Explorer
HomeBlocksTransactionsTokensRealmsPackagesValidatorsAnalytics

PathrockNetwork Gno Explorer — an independent explorer for Gno.land Mainnet (gnoland-1), operated by PathrockNetwork. Not an official Gno.land service.

gnowebarchive RPC

gno.land/p/onbloc/json/v0

Package
Open in gnoweb ↗

Overview

Kind
Pure package
Name
v0
Namespace
onbloc / json
Files
24 (README)(gnomod.toml)
Exported functions
n/a — not supported for pure packages by the node (vm/qfuncs)
Module
gno.land/p/onbloc/json/v0
gno
0.9

Files (24)

  • README.mdmarkdown
  • gnomod.tomltoml
  • buffer.gnogno
  • builder.gnogno
  • decode.gnogno
  • encode.gnogno
  • errors.gnogno
  • escape.gnogno
  • indent.gnogno
  • internal.gnogno
  • node.gnogno
  • parser.gnogno
  • path.gnogno
  • token.gnogno
  • buffer_test.gnogno
  • builder_test.gnogno
  • decode_test.gnogno
  • encode_test.gnogno
  • escape_test.gnogno
  • indent_test.gnogno
  • node_test.gnogno
  • parser_test.gnogno
  • path_test.gnogno
  • LICENSEother
  • parser.gnogno
    1package json23import (4	"bytes"5)67const (8	unescapeStackBufSize = 649	absMinInt64          = 1 << 6310	maxInt64             = absMinInt64 - 111	maxUint64            = 1<<64 - 112)1314// PaseStringLiteral parses a string from the given byte slice.15func ParseStringLiteral(data []byte) (string, error) {16	var buf [unescapeStackBufSize]byte1718	bf, err := Unescape(data, buf[:])19	if err != nil {20		return "", errInvalidStringInput21	}2223	return string(bf), nil24}2526// ParseBoolLiteral parses a boolean value from the given byte slice.27func ParseBoolLiteral(data []byte) (bool, error) {28	switch {29	case bytes.Equal(data, trueLiteral):30		return true, nil31	case bytes.Equal(data, falseLiteral):32		return false, nil33	default:34		return false, errMalformedBooleanValue35	}36}37

    Functions

    not supported for pure packages by the node (vm/qfuncs)

    Signatures reconstructed verbatim from vm/qfuncs — interface params keep their inline definitions.