31 Commits
Author SHA1 Message Date
andrew 2a52162d7f Add stack chk symbols to aarch64 imports 2026-06-14 20:47:28 -04:00
andrew e8f51eff53 Guard --nobranchprotection behind a version check
Older versions of hardening-check (as shipped by some Ubuntu releases)
don't support --nobranchprotection and error out. Probe --help at
configure time and only add the flag when it's available; old versions
that lack the flag also don't check for branch protection, so omitting
it is safe.
2026-06-14 20:34:29 -04:00
andrew 9ea798dba4 Fix aarch64 multi-byte UTF-8 parsing and add symbol imports file
On aarch64, char is unsigned by default, so *buf < 0x20 never held for
bytes >= 0x80, causing strDfa.scan to be skipped for multi-byte UTF-8
sequences in batch mode. Cast to int8_t to get the same signed comparison
used by the SIMD path.

Also add aarch64-symbol-imports.txt with the GLIBC 2.17 versioned symbols
imported by the library on that platform.
2026-06-14 19:42:41 -04:00
andrew 12c976a62c Fix make build by depending on target name instead of TARGET_OBJECTS in custom command
The Makefile generator does not create a rule for individual object files
when $<TARGET_OBJECTS:...> is used in DEPENDS of add_custom_command. Depending
on the target name instead establishes a proper target-level dependency.
2026-06-14 19:28:47 -04:00
andrew b079b293f7 Include <cstdlib> for malloc and free in lib.cpp 2026-06-14 19:22:32 -04:00
andrew d48fe618ac Add CI 2026-06-14 19:18:31 -04:00
andrew 470564a5df Improve coverage 2026-06-14 18:03:30 -04:00
andrew b9142bf36a Avoid some unnecessary string destruction in bench 2026-06-14 17:53:29 -04:00
andrew 97f1d3d352 Skip string and go directly to string2 from object3 2026-06-14 17:16:45 -04:00
andrew d8c9491eb3 Add fuzz test that finds previously missed coverage 2026-06-14 16:50:36 -04:00
andrew b4144298bb Update doctest.h to 2.5.2 2026-06-14 16:35:53 -04:00
andrew b894ae7a80 Fix arch-specific hardening_check ignore flags
hardening-check tests both CET (x86-only) and branch protection
(arm64-only). Pass the ignore flag for whichever doesn't apply to the
build arch so the test passes on all supported architectures.
2026-06-14 16:31:08 -04:00
andrew eb9925ffec Only pass -pie when linking executables
Passing -pie globally made the driver link Scrt1.o into shared
libraries, which fails with an undefined reference to main.
2026-06-14 16:20:48 -04:00
andrew 995ddf329f Fixes for gcc 15 2025-11-06 12:49:38 -05:00
andrew 5fc823b392 This didn't belong here and isn't really necessary 2025-08-25 16:50:43 -04:00
andrew 490b49e55d Remove redundancy 2025-08-25 16:49:21 -04:00
andrew 6fc263074e Simplify flowchart 2025-08-25 16:46:46 -04:00
andrew befb464619 More README tinkers 2025-08-25 16:39:01 -04:00
andrew f2bb72b3dc More clarifications in README 2025-08-25 16:19:34 -04:00
andrew 81814fa590 Simplify flow chart 2025-08-25 16:00:58 -04:00
andrew 611bccfb9b Update README 2025-08-25 15:57:07 -04:00
andrew e8d2855b36 Add maintainer notice 2025-08-25 15:43:37 -04:00
andrew 1f540a436a Tailor readme to prospective users 2025-08-25 15:34:29 -04:00
andrew c303478ad7 Avoid Utf8Dfa scan if there's no non-ascii 2025-08-15 19:45:00 -04:00
andrew 0b24636c4f Update corpus 2025-08-04 14:42:50 -04:00
andrew bcb5a20f27 Distinguish on_string_data and on_key_data 2025-08-04 14:15:49 -04:00
andrew 39fe9be4dc Clarify header comments 2025-08-04 12:44:00 -04:00
andrew 7801dbe6d7 Add missing files 2025-08-04 12:43:45 -04:00
andrew 0ed07e454a Merge remote-tracking branch 'origin/flags' 2025-08-04 12:36:20 -04:00
andrew 18a66009e1 Clarify memory usage comment in readme 2025-08-04 12:35:48 -04:00
andrew 6e244d1318 Add packaging and symbol visibility tests
Only tested on x86 linux so far
2025-08-04 12:35:26 -04:00
102 changed files with 10236 additions and 7176 deletions
+83
View File
@@ -0,0 +1,83 @@
name: CI
on: [push, pull_request]
jobs:
pre-commit:
runs-on: ubuntu-latest-amd64
steps:
- uses: actions/checkout@v4
- name: Install pre-commit
run: pipx install pre-commit
- name: Run pre-commit
run: ~/.local/bin/pre-commit run --all-files --show-diff-on-failure
build:
strategy:
fail-fast: false
matrix:
include:
- name: clang-amd64
runner: ubuntu-latest-amd64
cmake_args: -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++
upload: true
- name: clang-arm64
runner: ubuntu-latest-arm64
cmake_args: -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++
upload: true
- name: gcc-amd64
runner: ubuntu-latest-amd64
cmake_args: -DCMAKE_C_COMPILER=gcc -DCMAKE_CXX_COMPILER=g++
upload: false
- name: gcc-arm64
runner: ubuntu-latest-arm64
cmake_args: -DCMAKE_C_COMPILER=gcc -DCMAKE_CXX_COMPILER=g++
upload: false
runs-on: ${{ matrix.runner }}
steps:
- uses: actions/checkout@v4
- name: Install deps
run: |
sudo apt-get update
sudo apt-get install -y \
build-essential \
clang \
cmake \
devscripts \
rpm
- name: Build
run: |
cmake -S . -B build ${{ matrix.cmake_args }}
make -C build -j "$(nproc)"
- name: Test
run: |
cd build
ctest --output-on-failure -j "$(nproc)" --timeout 90
- name: Package
if: matrix.upload
run: |
cd build
cpack -G DEB
cpack -G RPM
- name: Upload packages to MinIO
if: matrix.upload
env:
MINIO_ACCESS_KEY: ${{ secrets.MINIO_ACCESS_KEY }}
MC_HOST_minio: https://${{ secrets.MINIO_ACCESS_KEY }}:${{ secrets.MINIO_SECRET_KEY }}@minio.weaselab.dev
run: |
if [ -z "$MINIO_ACCESS_KEY" ]; then
echo "MinIO credentials not configured; skipping upload"
exit 0
fi
curl -Ls "https://dl.min.io/client/mc/release/linux-$(dpkg --print-architecture)/mc" \
-o /tmp/mc && chmod +x /tmp/mc
dest="minio/jenkins/weaseljson/${{ gitea.run_number }}/${{ matrix.name }}/"
/tmp/mc cp build/*.deb "$dest"
/tmp/mc cp build/*.rpm "$dest"
+130 -3
View File
@@ -51,12 +51,16 @@ if(CMAKE_CXX_COMPILER_ID STREQUAL "GNU")
add_compile_options("-Wno-maybe-uninitialized")
endif()
set(full_relro_flags "-pie;LINKER:-z,relro,-z,now,-z,noexecstack")
set(relro_flags "LINKER:-z,relro,-z,now,-z,noexecstack")
set(full_relro_flags "-pie;${relro_flags}")
cmake_push_check_state()
list(APPEND CMAKE_REQUIRED_LINK_OPTIONS ${full_relro_flags})
check_cxx_source_compiles("int main(){}" HAS_FULL_RELRO FAIL_REGEX "warning:")
if(HAS_FULL_RELRO)
add_link_options(${full_relro_flags})
# -pie only applies to executables; passing it when linking a shared library
# makes the driver pull in Scrt1.o, which requires main.
add_link_options("$<$<STREQUAL:$<TARGET_PROPERTY:TYPE>,EXECUTABLE>:-pie>"
${relro_flags})
endif()
cmake_pop_check_state()
@@ -115,7 +119,7 @@ add_custom_command(
OUTPUT ${CMAKE_BINARY_DIR}/${PROJECT_NAME}.o
COMMAND ${LD_EXE} -r $<TARGET_OBJECTS:${PROJECT_NAME}-object> -o
${CMAKE_BINARY_DIR}/${PROJECT_NAME}.o
DEPENDS $<TARGET_OBJECTS:${PROJECT_NAME}-object>
DEPENDS ${PROJECT_NAME}-object
COMMAND_EXPAND_LISTS)
add_library(${PROJECT_NAME} SHARED ${CMAKE_BINARY_DIR}/${PROJECT_NAME}.o)
@@ -174,3 +178,126 @@ endif()
add_executable(validate src/validate.cpp)
target_link_libraries(validate ${PROJECT_NAME}-static)
target_include_directories(validate PRIVATE include)
# symbol visibility tests
if(NOT CMAKE_BUILD_TYPE STREQUAL Debug)
if(APPLE)
set(symbol_exports ${CMAKE_CURRENT_SOURCE_DIR}/apple-symbol-exports.txt)
set(symbol_imports ${CMAKE_CURRENT_SOURCE_DIR}/apple-symbol-imports.txt)
else()
set(symbol_exports ${CMAKE_CURRENT_SOURCE_DIR}/symbol-exports.txt)
if(CMAKE_SYSTEM_PROCESSOR STREQUAL aarch64)
set(symbol_imports ${CMAKE_CURRENT_SOURCE_DIR}/aarch64-symbol-imports.txt)
else()
set(symbol_imports ${CMAKE_CURRENT_SOURCE_DIR}/symbol-imports.txt)
endif()
endif()
add_test(
NAME conflict_set_shared_symbols
COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/test_symbols.sh
$<TARGET_FILE:${PROJECT_NAME}> ${symbol_exports} ${symbol_imports})
add_test(
NAME conflict_set_static_symbols
COMMAND
${CMAKE_CURRENT_SOURCE_DIR}/test_symbols.sh
$<TARGET_FILE:${PROJECT_NAME}-static> ${symbol_exports} ${symbol_imports})
endif()
if(NOT CMAKE_CROSSCOMPILING)
find_program(HARDENING_CHECK hardening-check)
if(HARDENING_CHECK)
# Control flow integrity (CET) is x86-only and branch protection (PAC/BTI)
# is arm64-only, so ignore whichever doesn't apply.
if(CMAKE_SYSTEM_PROCESSOR STREQUAL aarch64 OR CMAKE_SYSTEM_PROCESSOR
STREQUAL arm64)
set(hardening_check_arch_flags --nocfprotection)
else()
# --nobranchprotection was added in a newer version of hardening-check;
# older versions don't check for it either, so omitting the flag is safe.
execute_process(
COMMAND ${HARDENING_CHECK} --help
OUTPUT_VARIABLE _hardening_check_help
ERROR_VARIABLE _hardening_check_help)
if(_hardening_check_help MATCHES "nobranchprotection")
set(hardening_check_arch_flags --nobranchprotection)
else()
set(hardening_check_arch_flags "")
endif()
endif()
add_test(
NAME hardening_check
COMMAND ${HARDENING_CHECK} $<TARGET_FILE:${PROJECT_NAME}> --nofortify
--nostackprotector ${hardening_check_arch_flags})
endif()
endif()
# packaging
set(CPACK_PACKAGE_CONTACT andrew@weaselab.dev)
set(CMAKE_INSTALL_DEFAULT_COMPONENT_NAME all)
set(CPACK_PACKAGE_VENDOR "Weaselab")
set(CPACK_RESOURCE_FILE_LICENSE "${CMAKE_CURRENT_SOURCE_DIR}/LICENSE")
set(CPACK_RESOURCE_FILE_README "${CMAKE_CURRENT_SOURCE_DIR}/README.md")
# rpm
set(CPACK_RPM_PACKAGE_ARCHITECTURE ${CMAKE_SYSTEM_PROCESSOR})
set(CPACK_RPM_SPEC_INSTALL_POST "/bin/true") # avoid stripping
set(CPACK_RPM_PACKAGE_LICENSE "Apache 2.0")
set(CPACK_RPM_FILE_NAME RPM-DEFAULT)
# deb
set(CPACK_DEBIAN_FILE_NAME DEB-DEFAULT)
# see *-imports.txt - dependency versions need to be synced with symbol versions
if(CMAKE_SYSTEM_PROCESSOR STREQUAL aarch64)
set(CPACK_DEBIAN_PACKAGE_DEPENDS "libc6 (>= 2.17)")
else()
set(CPACK_DEBIAN_PACKAGE_DEPENDS "libc6 (>= 2.14)")
endif()
# macos
set(CMAKE_OSX_DEPLOYMENT_TARGET 11.0)
if(APPLE)
find_program(PANDOC_EXE pandoc)
if(PANDOC_EXE)
execute_process(COMMAND ${PANDOC_EXE} ${CMAKE_CURRENT_SOURCE_DIR}/README.md
-o ${CMAKE_CURRENT_BINARY_DIR}/README.txt)
set(CPACK_RESOURCE_FILE_README ${CMAKE_CURRENT_BINARY_DIR}/README.txt)
endif()
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/LICENSE
${CMAKE_CURRENT_BINARY_DIR}/LICENSE.txt COPYONLY)
set(CPACK_RESOURCE_FILE_LICENSE ${CMAKE_CURRENT_BINARY_DIR}/LICENSE.txt)
endif()
include(CPack)
include(GNUInstallDirs)
target_include_directories(
${PROJECT_NAME}
PUBLIC $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>
$<INSTALL_INTERFACE:${CMAKE_INSTALL_INCLUDEDIR}/${PROJECT_NAME}>)
target_include_directories(
${PROJECT_NAME}-static
PUBLIC $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>
$<INSTALL_INTERFACE:${CMAKE_INSTALL_INCLUDEDIR}/${PROJECT_NAME}>)
set_target_properties(
${PROJECT_NAME} PROPERTIES VERSION ${PROJECT_VERSION}
SOVERSION ${PROJECT_VERSION_MAJOR})
install(
TARGETS ${PROJECT_NAME} ${PROJECT_NAME}-static
EXPORT ${PROJECT_NAME}Config
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}
RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR})
install(DIRECTORY include/
DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/${PROJECT_NAME})
install(EXPORT ${PROJECT_NAME}Config
DESTINATION ${CMAKE_INSTALL_DATAROOTDIR}/${PROJECT_NAME}/cmake)
cpack_add_component(all)
+203
View File
@@ -0,0 +1,203 @@
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
1. Definitions.
"License" shall mean the terms and conditions for use, reproduction,
and distribution as defined by Sections 1 through 9 of this document.
"Licensor" shall mean the copyright owner or entity authorized by
the copyright owner that is granting the License.
"Legal Entity" shall mean the union of the acting entity and all
other entities that control, are controlled by, or are under common
control with that entity. For the purposes of this definition,
"control" means (i) the power, direct or indirect, to cause the
direction or management of such entity, whether by contract or
otherwise, or (ii) ownership of fifty percent (50%) or more of the
outstanding shares, or (iii) beneficial ownership of such entity.
"You" (or "Your") shall mean an individual or Legal Entity
exercising permissions granted by this License.
"Source" form shall mean the preferred form for making modifications,
including but not limited to software source code, documentation
source, and configuration files.
"Object" form shall mean any form resulting from mechanical
transformation or translation of a Source form, including but
not limited to compiled object code, generated documentation,
and conversions to other media types.
"Work" shall mean the work of authorship, whether in Source or
Object form, made available under the License, as indicated by a
copyright notice that is included in or attached to the work
(an example is provided in the Appendix below).
"Derivative Works" shall mean any work, whether in Source or Object
form, that is based on (or derived from) the Work and for which the
editorial revisions, annotations, elaborations, or other modifications
represent, as a whole, an original work of authorship. For the purposes
of this License, Derivative Works shall not include works that remain
separable from, or merely link (or bind by name) to the interfaces of,
the Work and Derivative Works thereof.
"Contribution" shall mean any work of authorship, including
the original version of the Work and any modifications or additions
to that Work or Derivative Works thereof, that is intentionally
submitted to Licensor for inclusion in the Work by the copyright owner
or by an individual or Legal Entity authorized to submit on behalf of
the copyright owner. For the purposes of this definition, "submitted"
means any form of electronic, verbal, or written communication sent
to the Licensor or its representatives, including but not limited to
communication on electronic mailing lists, source code control systems,
and issue tracking systems that are managed by, or on behalf of, the
Licensor for the purpose of discussing and improving the Work, but
excluding communication that is conspicuously marked or otherwise
designated in writing by the copyright owner as "Not a Contribution."
"Contributor" shall mean Licensor and any individual or Legal Entity
on behalf of whom a Contribution has been received by Licensor and
subsequently incorporated within the Work.
2. Grant of Copyright License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
copyright license to reproduce, prepare Derivative Works of,
publicly display, publicly perform, sublicense, and distribute the
Work and such Derivative Works in Source or Object form.
3. Grant of Patent License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
(except as stated in this section) patent license to make, have made,
use, offer to sell, sell, import, and otherwise transfer the Work,
where such license applies only to those patent claims licensable
by such Contributor that are necessarily infringed by their
Contribution(s) alone or by combination of their Contribution(s)
with the Work to which such Contribution(s) was submitted. If You
institute patent litigation against any entity (including a
cross-claim or counterclaim in a lawsuit) alleging that the Work
or a Contribution incorporated within the Work constitutes direct
or contributory patent infringement, then any patent licenses
granted to You under this License for that Work shall terminate
as of the date such litigation is filed.
4. Redistribution. You may reproduce and distribute copies of the
Work or Derivative Works thereof in any medium, with or without
modifications, and in Source or Object form, provided that You
meet the following conditions:
(a) You must give any other recipients of the Work or
Derivative Works a copy of this License; and
(b) You must cause any modified files to carry prominent notices
stating that You changed the files; and
(c) You must retain, in the Source form of any Derivative Works
that You distribute, all copyright, patent, trademark, and
attribution notices from the Source form of the Work,
excluding those notices that do not pertain to any part of
the Derivative Works; and
(d) If the Work includes a "NOTICE" text file as part of its
distribution, then any Derivative Works that You distribute must
include a readable copy of the attribution notices contained
within such NOTICE file, excluding those notices that do not
pertain to any part of the Derivative Works, in at least one
of the following places: within a NOTICE text file distributed
as part of the Derivative Works; within the Source form or
documentation, if provided along with the Derivative Works; or,
within a display generated by the Derivative Works, if and
wherever such third-party notices normally appear. The contents
of the NOTICE file are for informational purposes only and
do not modify the License. You may add Your own attribution
notices within Derivative Works that You distribute, alongside
or as an addendum to the NOTICE text from the Work, provided
that such additional attribution notices cannot be construed
as modifying the License.
You may add Your own copyright statement to Your modifications and
may provide additional or different license terms and conditions
for use, reproduction, or distribution of Your modifications, or
for any such Derivative Works as a whole, provided Your use,
reproduction, and distribution of the Work otherwise complies with
the conditions stated in this License.
5. Submission of Contributions. Unless You explicitly state otherwise,
any Contribution intentionally submitted for inclusion in the Work
by You to the Licensor shall be under the terms and conditions of
this License, without any additional terms or conditions.
Notwithstanding the above, nothing herein shall supersede or modify
the terms of any separate license agreement you may have executed
with Licensor regarding such Contributions.
6. Trademarks. This License does not grant permission to use the trade
names, trademarks, service marks, or product names of the Licensor,
except as required for reasonable and customary use in describing the
origin of the Work and reproducing the content of the NOTICE file.
7. Disclaimer of Warranty. Unless required by applicable law or
agreed to in writing, Licensor provides the Work (and each
Contributor provides its Contributions) on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
implied, including, without limitation, any warranties or conditions
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
PARTICULAR PURPOSE. You are solely responsible for determining the
appropriateness of using or redistributing the Work and assume any
risks associated with Your exercise of permissions under this License.
8. Limitation of Liability. In no event and under no legal theory,
whether in tort (including negligence), contract, or otherwise,
unless required by applicable law (such as deliberate and grossly
negligent acts) or agreed to in writing, shall any Contributor be
liable to You for damages, including any direct, indirect, special,
incidental, or consequential damages of any character arising as a
result of this License or out of the use or inability to use the
Work (including but not limited to damages for loss of goodwill,
work stoppage, computer failure or malfunction, or any and all
other commercial damages or losses), even if such Contributor
has been advised of the possibility of such damages.
9. Accepting Warranty or Additional Liability. While redistributing
the Work or Derivative Works thereof, You may choose to offer,
and charge a fee for, acceptance of support, warranty, indemnity,
or other liability obligations and/or rights consistent with this
License. However, in accepting such obligations, You may act only
on Your own behalf and on Your sole responsibility, not on behalf
of any other Contributor, and only if You agree to indemnify,
defend, and hold each Contributor harmless for any liability
incurred by, or claims asserted against, such Contributor by reason
of your accepting any such warranty or additional liability.
END OF TERMS AND CONDITIONS
APPENDIX: How to apply the Apache License to your work.
To apply the Apache License to your work, attach the following
boilerplate notice, with the fields enclosed by brackets "[]"
replaced with your own identifying information. (Don't include
the brackets!) The text should be enclosed in the appropriate
comment syntax for the file format. We also recommend that a
file or class name and description of purpose be included on the
same "printed page" as the copyright notice for easier
identification within third-party archives.
Copyright [yyyy] [name of copyright owner]
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
+86 -14
View File
@@ -1,26 +1,98 @@
# Weaseljson
# WeaselJSON: A Streaming JSON Parser
An rfc8259-compliant streaming json parser
## What is WeaselJSON?
# Features
WeaselJSON is a high-performance, streaming JSON parser that uses callbacks instead of building an object tree in memory. It's optimized with SIMD instructions and designed for situations where you either can't or don't want to load entire JSON files into memory.
- SAX-style api
## Key Characteristics
**What's good:**
- Uses constant memory regardless of input size
- Fast parsing with SIMD optimizations
- Follows JSON spec properly with good security practices
- You can't accidentally make it O(n²) (unlike the simdjson ondemand api)
- Enables weird use cases like parsing just the beginning of huge JSON files
**What's not good:**
- The callback API is a pain to use correctly
- Requires a lot of boilerplate for simple tasks
- Most people don't actually need streaming JSON parsing
## JSON Parser Decision Guide
```mermaid
flowchart TD
A[Need to parse JSON?] --> B{Memory or size constraints?}
B -->|Yes| C[WeaselJSON<br/>Streaming parser]
B -->|No| D{Need maximum speed?}
D -->|No| E[SimdJSON DOM<br/>Easy to use]
D -->|Yes| F[SimdJSON On-Demand<br/>Fastest option]
```
## When to Use What
### Use **SimdJSON DOM API** when:
- You want to write `obj["key"]` and have it just work
- JSON files are reasonably sized (but you still want decent performance)
- You care about getting things done
- You need full document validation upfront
### Use **SimdJSON On-Demand** when:
- Performance is critical and your data fits in memory
- You can work with forward-only traversal (no random access or backtracking)
- You need maximum speed but still want a usable API
- You're okay with partial validation (only validates parts you actually access)
- Your JSON keys don't contain escape sequences (OnDemand matches raw keys without unescaping)
### Use **WeaselJSON** when:
- You want to parse just part of a JSON file without reading the rest
- You need to convert JSON into some other format as you parse it
- You need predictable performance characteristics
- Writing stateful callbacks is your idea of fun
## The Reality
WeaselJSON solves real problems that other parsers can't handle, but most people don't have those problems. The callback API is legitimately difficult to use correctly, which pushes most developers toward easier alternatives.
The parser represents excellent engineering work and occupies a useful niche. It's the kind of tool you're very glad exists when you actually need it, but most people will never need it.
## Technical Reference
### Features
- SAX-style callback API
- No memory allocations during parsing
- O(1) stack memory usage
- Streaming api - no need to buffer the entire document in memory. Parsing is resumed when more data is available
- Strings are unescaped in place before they're presented. No unicode normalization is performed
- O(1) memory usage regardless of input size
- Streaming API - no need to buffer the entire document in memory. Parsing is resumed when more data is available
- By default, strings are unescaped in place before they're presented (modifies your input buffer). No unicode normalization is performed
- Robust to crashes with untrusted input
- SIMD optimizations for string scanning and validation
# Rfc8259 conformance notes
### RFC 8259 Conformance
- There are no limits on number precision. Numbers are only validated syntactically and are presented as is
- Only utf-8 is accepted
- Invalid utf-8 is rejected
- Only UTF-8 is accepted
- Invalid UTF-8 is rejected
- Byte order markers are rejected
- Invalid escaped utf16 surrogate pairs are rejected
- Invalid escaped UTF-16 surrogate pairs are rejected
- Documents that are too deeply nested are rejected to control memory usage
- Duplicate keys are presented
# Caveats
### Caveats
- Users should be prepared to discard work done during SAX callbacks if the document is ultimately rejected
- Requires manual state management in callback functions
- API is more complex than DOM-style parsers
## Maintainer Notice
⚠️ **Important**: This is a hobby project by a single maintainer. Please be aware that:
- I'm doing this for fun and learning, not as a professional obligation
- Don't rely on this for mission-critical applications without understanding these limitations
- Feel free to email me, but I may not respond promptly
---
*Note: This document was written by AI (Claude) in collaboration with the author.*
+5
View File
@@ -0,0 +1,5 @@
__stack_chk_fail@GLIBC_2.17
__stack_chk_guard@GLIBC_2.17
free@GLIBC_2.17
malloc@GLIBC_2.17
memmove@GLIBC_2.17
@@ -0,0 +1 @@
[[[0,0,[12011111111112111111110,4,">>>>>>>>>>>>>>>>>>>>>>>>>>>>>>[],[[],[[],],[[[3>>>>>>>>>>>->>>>>>3344,4244>1>;":Z{}-
@@ -0,0 +1,19 @@
{"7":"k7", "6":
"{7", "6":
"{7", "7":"k7", "6":
"{7", "7":
"{7", "":"{9991990.-97", "7":"{7", "7":
false, "7":
"{w", "7":"k7", "6":
"{7", "6":
"{7", "7":"k7", "6":
"{7", "7":
"{7", "":"{9991990.-97", "7":"{7", "7":
false, "7":
"{7", "":"{9991990.597", "7":"{7", "7":
false, "6":
"{7", "7":
"{7", "":"{9991990.-97", "7":"{7", "7":
false, "7":
"{7", "\u "":"{999199", "77", "7":
false, ""
@@ -0,0 +1 @@
"fa\udafa\udffa2fqfa\udafa\udffa2fa2@@@ffa2fqfa\udafa\udffa2fffa\udafa\udffa2ffa\udafa\udfa2fffa\udafa\udffa2ffa\udafa\udffadffa4fa2@@@@@a2@@@Aa2@2fqfa\udafa\udffa2fffa\udafa\udffa2ffa\udafa\udfa2fffa\udafa\udffa2ffa\udafa\udffadffa2fa2@@@@@a2@2@fa\udafa\udffa2fqfa\udafa\udffa2fffa\udafa\udffa2ffa\udafa\udfa2fffa\udafa\udffa2ffa\ud2fffa\udafa\udffa2ffa\udafa\udfa2ff!!!!!%!!!!!!!!!!!!!!!!!!fa\udafa\udffa2ffa\udafa\udffadfa\udafa\udffa2ffa\udafa\udfa2fffa\udafa\udffa2ffa\udafa\udffa2@@@Aaa\udafa\udffa2fffa\udafa\udffa2ffa\udafa\udfa2fffa\udafa\udffa2ffa\udafa\udffadffa2fa2@@@@@a2@2@fa\udafa\udffa2fqfa\udafa\udffa2fffa\udafa\udffa2ffa\udafa\udfa2fffa\udafa\udffa2ffa\ud2fffa\udafadfa2ff!!!@@a2@@@@AA
@@ -0,0 +1,61 @@
[[5,[5,7.75,5,7.777E-5,[5,7E-575,775,[5,775,[5,7E-5,7.777E-5,[5,775,[5,7E-5,7.777E-5,[5,7.5,7.75,775,[5,7E-5,7.777E-5,[5,7.75,775,[5,7E-575,775,[5,775,[5,7E-5,7.777E-5,[[[5,7.75,775,[5,7E-575,775,[5,775,[5,7E-5,7.777E-5,[5,7.5,7.75,775,775,[5,7E-575,77.75,775,[5,7E-575,775.75,775,[5,7E-575,775,[5,775,[5,7E-5,7.777E-5,[5,7.5,7.75,775,775,[5,7E-575,77.75,7757E-5,[5,7.5,7.75,[5,7E-575,77.75,775,[5,7E-575,775.75,775,[5,7E-575,5,7.5,7.75,[false, [[false, [[[{},8,[-41.8,[8,[8,[[[[[-41.8,[8,[8,[[[[ [[[ [[-41.8,[3,[8,[[[[ [[[
[[-418,[8,[[[
[[-41.8,[8,[8,
[[-41.8,[-41.8,[8,[8,[[[[[-41.8,[8,[
[[-418,[8,[[[[[[-41.8,[8,[8,[[[[ [[[
[[-41,{},[[[[{},{}, [[[{},{},[[false, [[false, [[[{},8,[-41.8,[8,[8,[[[[[-20.8,[8,[8,[[1.8,[3,[8,[[[[ [[[
[[-418,[8,[[[
[[-41,{},[[false, [[false, [[[{},8,[-41.8,[8,[8,[[[[[-41.8,[8,[8,[[[[ [[[ [[-41.8,[3,[8,[[[[ [[[
[[-418,[7,[[[
[[-41.8,[8,[8,
[[-41.8,[-41.8,[8,[8,[[[[[-41.8,[8,[
[[-418,[8,[[[[[[-41.8,[8,[8,[[[[41.8,[[-418,[8,[[[[[[-41.8,[8,[8,[[[[ [[[
[[-41,{},[[[[{} ,{}, [[[{},{},[[false, [[false, [[[{},8,[-41.8,[8,[8.8,[8,[[[{},{}, [[[{},{},[[false, [[false, [[[{},8, [[[
[[-41,{},[[[[{},{}, [[[{},{},[[false, [[false, [[[{},8,[-41.8,[8,[8.8,[8,[[[{},{}, [[[{},{},[[false, [[false, [[[{},8,[-41.8,[8,[8,[[[[[-41.8,[8,[8,[[[[ [[[ [[-41.8,[3,[8,[[[[ [[[
[[-418,[8,[[[
[[-3,[8,[[41.8,[8,[8,[[[[[-20.8,[8,[8,[[1.8,[3,[8,[[[[ [[[
[[-418,[8,[[[
[[-41,{},[[false, [[false, [[[{},8,[-41.8,[8,[8,[[[[[-41.8,[8,[8,[[[[ [[-41.8,[8,[8,[[[[ [[[ [[-41.8,[3,[8,[[[[ [[[
[[-418,[8,[[[
[[-41.8,[8,[8,
[[-41.8,[-41.8,[8,[8,[[[[[-41.8,[8,[
[[-418,[8,[[[[[[-41.8,[8,[8,[[[[41.8,[8,[8,[[[[ [[[ [[-41.8,[3,[8,[[[[ [[[
[[-418,[8,[[[
[[-41.8,[8,[8,
[[-41.8,[-41.8,[8,[8,[[[[[-41.8,[8,[
[[-418,[8,[[[[[[-41.8,[8,[8,[[[[ [[[
[[-41,{},[[[[{},{}, [[[{},{},[[false, [[false, [[[{},8,[-41.8,[8,[8,[[[[[-20.8,[8,[8,[[1.8,[3,[8,[[[[ [[[
[[-418,[8,[[[
[[-41,{},[[false, [[false, [[[{},8,[-41.8,[8,[8,[[[[[-41.8,[8,[8,[[[[ [[[ [[-41.8,[3,[8,[[[[ [[[
[[-418,[8,[[[
[[-41.8,[8,[8,
[[-41.8,[-41.8,[8,[8,[[[[[-41.8,[8,[
[[-418,[8,[[[[[[-41.8,[8,[8,[[[[ [[[
[[
[[-41.8,[8,[8,
[[-41.8,[-41.8,[8,[8,[[[[[-41.8,[8,[
[[-418,[8,[[[[[[-41.8,[8,[8,[[[[ [[[
[[-41,{},[[[[{},{}, [[[{},{},[[false, [[false, [[[{},8,[-41.8,[8,[8,[[[[[-20.8,[8,[8,[[1.8,[3,[8,[[[[ [[[
[[-418,[8,[[[
[[-41,{},[[false, [[false, [[[{},8,[-41.8,[8,[8,[[[[[-41.8,[8,[8,[[[[ [[[ [[-41.8,[3,[8,[[[[ [[[
[[-418,[7,[[[
[[-41.8,[8,[8,
[[-41.8,[-41.8,[8,[8,[[[[[-41.8,[8,[
[[-418,[8,[[[[[[-41.8,[8,[8,[[[[41.8,[[-418,[8,[[[[[[-41.8,[8,[8,[[[[ [[[
[[-41,{},[[[[{} ,{}, [[[{},{},[[false, [[false, [[[{},8,[-41.8,[8,[8.8,[8,[[[{},{}, [[[{},{},[[false, [[false, [[[{},8, [[[
[[-41,{},[[[[{},{}, [[[{},{},[[false, [[8,[8.8,[8,[[[{},{}, [[[{},{},[[false, [[false, [[[{},8,[-41.8,[8,[8,[[[[[-41.8,[8,[8,[[[[ [[[ [[-41.8,[3,[8,[[[[ [[[
[[-418,[8,[[[
[[-3,[8,[[41.8,[8,[8,[[[[[-20.8,[8,[8,[[1.8,[ [[false, [[[{},8,[-41.8,[8,[8,[[[[[-41.8,[8,[8,[[[[ [[-41.8,[8,[8,[[[[ [[[ [[-41.8,[3,[8,[[[[ [[[
[[-418,[8,[[[
[[-41.8,[8,[8,
[[-41.8,[-41.8,[8,[8,[[[[[-41.8,[8,[
[[-418,[8,[[[[[[-41.8,[8,[8,[[[[41.8,[8,[8,[[[[ [[[ [[-41.8,[3,[8,[[5,7E-5,7.7,[
-611111110,0,[
-61111112111111110,[
[true,
f61
@@ -0,0 +1,2 @@
{"6,..\udafa\udffaXX4,[[Xg018
@@ -0,0 +1 @@
["\r\/\f\r\1\b
@@ -0,0 +1 @@
{"1f\u043e\u043b\u0441]u043e\u0440\u041f\u043e\u043budd9d41d\ud82d\udd9c8\ud5de39\ud41d41d\ud82d\udd9c;8\uÛÛÛÛÛÛÛÛÛÛÛÛd0de39\u2d\udd43f0\u0430 \u0417\u0982dd9c8u\2d8d435\u04\u43\u0982dd9c]u\04ƒ35\u043a
Binary file not shown.
@@ -0,0 +1 @@
["\uDA9D\uDDDDux\uDA9D\uDDDdux\uDA9D\uDDA9D\uDA9D\uDDDduxux\uDA9D\uDDDdDDDux\uDA9D\uDDDdu|\uDA4D\uDDA9D\uDA9D\uDDDDDDux\uDA9D\uDDDdDDA9D\uDA9D\uDDDDDDux9D\uDA9D\uDDDDDDux\uDA9D\uDDDduxux\uDA9D\uDDDdDDDux\uDA9D\uDDDdu\uDA9D\uDDA9D\uDA9D\uDDDDD-2Dux\uDA9D\uDDDdDDduxux\uDA9D\uDDDdDDDux\uDA9D\uDDDdu|\uDA9D\uDDADdux\uDA9D\uDDA9D\uDA9D\uDDDDDDux\uDA9D\uDDDduxux\uDA9D\uDDDdDDDux\uDA9D\uDDDdu|\uDA4D\uDDA9D\uDA9D\uDDDDDDux\uDA9D\uDDDdDDA9D\uDA9D\uDDDDDDux9D\uDA9D\uDDDDDDux\uDA9D\uDDDduxux\uDA9D\uDDDdDDDux\uDA9D\uDDDdu|\uDA9D\uDDA9D\uDA9D\uDDDD\¬ \b\b\fDDDux\uDA9D\uDDDdDDA0
@@ -0,0 +1,49 @@
[2,
2,2,2,2,2,2,2,
[[2,2,2,2,2,2,
2,
2,
[2,2,22,2,
2,2,2,2,2,2,2,2,
[[2,2,
2,2,
2,
2,2,
2,2,[2,
2,2,2,2,2,2,2,[2,2,
2,2,2,2,
2,
2,
2,2,22,2,2,2,2,2,2,2,2,2,
[2,2,
2,2,
2,
[2,2,
2,2,2,2,
2,2,2,
2,[2,2,22,2,
2,2,2,2,
2,
[2,2,22,2,
2,2,2,2,2,2,2,2,
[[2,2,
2,2,
2,
[2,2,
2,2,2,2,
2,2,2,
2,
[2,2,22,2,
2,[2,
22,2,
2,2,2,
2,
[2,2,22,2,
2,2,2,2,
2,
[2,2,22,2,
2,2,2,2,2,22,2,2,
2,
[2,2,22,2,
2,[2,
2@
@@ -0,0 +1,13 @@
[[
[[
5,[
425,"и-
Binary file not shown.
@@ -0,0 +1 @@
[[[ true,[[[[true, true,true,true,[ true,[[[[[["\"\b\b\f[\n\"\\!\/\b\\50\"\"&\\u30af\u0061-u6\u0030\\u30af\u0061-u6\u000af\u0061-u6\"6\u003061-u6\"\\u30af\u0061-u@:6\u0030\\u30af61-u6\"6\u003061-u6\"\\u30af\u0061-u:6\u0030\\u30af\u0061-u6\u0030\u30af\u0061-u6\"630\u30af\u0061-u6\"\u30af\u0061-u6\"\\u30af\u0061-u6\u0030\\\\u60ar]\/\6f\\/][99\f",8,9999
@@ -0,0 +1,7 @@
[[[{},{}, [[[[[-41.8,[8,[8,
[[-41.8,[-41.8,[8,[8,[[[[[-41.8,[8,[
[[-418,[8,[[[[[[-41.8,[8,[8,[[[[ [[[
[[-41,{},[[[[{},{}, [[[{},{},[[false, [[false, [[[{},8,[-41.8,[8,[8,[[[[[-20.8,[8,[8,[[[[ true,[[[[true, true,true,true,[ true,[[[[[["\"\b\b\f[\n\"\\!\/\b\\50\"\"&\\u30af\u0061-u6\u0030\\u30af\u0061-u6\u000af\u0061-u6\"6\u003061-u6\"\\u30af\u0060af61-u6\"6\u003061-u6\"\\u30af\u0061-u:2\u0030\\u30af\u0061-u6\u0030\u30af\u0061-u6\"630\u30af\u0061-u6\"\u30af\u0061-u6\"\\u30af\u0061-u6\u0030\\\\u60af\u0061-u6\u0030\u30a0061-q6\u000af\u0061-u6\"6\u000af\u0061-u2\u0030\\u30061-u6\"6\u00306Y1-u6\"\\u30af\u0061-u@:6\u0030\\u30af61-u6\"6\u003061-u6\"\\u30af\u0061-u:6\u0030\\u30af\u0061-u6\u0030\u30af\u0061-u6\"630\u30af\u0061-u6\"\u30af\u0061-u\"\u30af\u0061-u6\"\\u30afÿÿÿÿÿÿÿÿÿu6\"6\u000af\u0061-u2\u0030\\u30061999[[-41.8,[-41.8,[8,[8,Ä[[[[-41.3345,3352234e5,334.e55,334 -3,5,[-" : 8,"" : -8"8[[ [[[
[
[[-41.8,[8,[8,[[[
[8{},[-[
Binary file not shown.
Binary file not shown.
@@ -0,0 +1 @@
{"":"_________________________________@@@@ffa\udafa\udffa2fa[-401.
@@ -0,0 +1 @@
[null,[0,null,null,null,null,null,[1,[1,[null,1,null,null,null,null,null,[0,null,null,null,null,null,[0,[1,[0,null,null,null,null,null,null,null,[0,null,null,null,null,{"\uDA9D\uDDDDux\uDA9D\uDDDdux\uDA9D\uDDA9D\uDA9D\uDDDduxux\uDA9D\uDDDdDDDux\uDA9D\uDDDdu|\uDA4D\uDDA9D\uDA9D\uDDDDDDux\uDA9D\uDDDdDDA9D\uDA9D\uDDDDDDux9D\uDA9D\uDDDDDDux\uDA9D\uDDDduxux\uDA9D\uDDDdDDDux\uDA9D\uDDDdu\uDA9D\uDDA9D\uDA9D\uDDDDD-2Dux\uDA9D\uDDDdDDduxux\uDA9D\uDDDdDDDux\uDA9D\uDDDdu|\uDA9D\uDDADdux\uDA9D\uDDA9D\uDA9D\uDDDDDDux\uDA9D\uDDDduxux\uDA9D\uDDDdDDDux\uDA9D\uDDDdu|\uDA4D\uDDA9D\uDA9D\uDDDDDDux\uDA9D\uDDDdDDA9D\uDA9D\uDDDDDDux9D\uDA9D\uDDDDDDux\uDA9D\uDDDduxux\uDA9D\uDDDdDDDux\uDA9D\uDDDdu|\uDA9D\uDDA9D\uDA9D\uDDDDDnull,[1,[1,null,null,null,null,null,[0,[1,[0,null,1nulll,,[1
Binary file not shown.
@@ -0,0 +1 @@
["\"\b\b\f\n\"\\\/\b\\\/:b\b\f\\nb\f\n\r\/\f\n\r\/\\r\/\f\n\rb\\\f\n\r\/\f\n\r\r/\f\n\r\/\\r\/\f\n\r\\圭f\n\r\/\f\n\r\/\\r\\\/\b\b\f\n\"\\\/\b\\\/\b\b\f\n\"\\\/f\n\"\\\/\b\\\/:b\b\f\n\"\\\/\b\b\f\n\r\/\f\n\r\/\\r\/\f\n\r\\b\f\n\r\/\f\n\r\\/\/\f\n\r\7\b
@@ -0,0 +1 @@
[[ [[[[[[[[[[{"n
@@ -0,0 +1,91 @@
[[[{},{}, [[[{},{},[[[[{},{}, [[[{},{},[[false, [[false, [[[{},8,[-41.8,[8,[8,[[[[[-41.8,[8,[8,[[[[ [[[ [[-41.8,[3,[8,[[[[ [[[
[[-418,[8,[[[
[[-41.8,[8,[8,
[[-41.8,[-41.8,[8,[8,[[[[[-41.8,[8,[
[[-418,[8,[[[[[[-41.8,[8,[8,[[[[ [[[
[[-41,{},[[[[{},{}, [[[{},{},[[false, [[false, [[[{},8,[-41.8,[8,[8,[[[[[-20.8,[8,[8,[[1.8,[3,[8,[[[[ [[[
[[-418,[8,[[[
[[-41,{},[[false, [[false, [[[{},8,[[[ [[[ [[-41.8,[3,[8,[[[[ [[[
[[-418,[8,[1.8,[3,[8,[[[[ [[[
[[-418,[8,[[[
[[-22222222222222222222222222222222222222222222222222222222222222222222241.8,[8,[8,
[[-41.8,[-41.8,[8,[8,[[[[[-41.8,[8,[
[[-418,[8,[[[[[[-41.8,[8,[7,[[[[41.8,[8,[8,[[[[ [[[ [[-41.8,[3,[899,
9,0,3,0,3,99,[[[[ [[[
[[-418,[8,[[[
[[-41.8,[8,[8,
[[-41.8,[-41.8,[8,[8,[[[[[-41.8,[8,[
[[-418,[8,[[[[[[-41.8,[8,[8,[[[[ [[[
[[-41,{},[[[[{},{}, [[[{},{},[[false, [[false, [[[{},8,[-41.8,[8,[8,[[[[[-20.8,[8,[8,[[1.8,[3,[0,[[[[ [[[
[[-418,[8,[[[
[[-41,{},[[false, [[false, [[[{},8,[-41.8,[8,[8,[[[[[-41.8,[8,[8,[[[[ [[[ [[-41.8,[3,[8,[[[[ [[[
[[-418,[8,[[[
[[-41.8,[8,[8,
[[-41.8,[-41.8,[8,[8,8,[8,[8,[[[[[-41.8,[7E-5,7E-5,3E8,[
[[-418,[8,[[[[[[-41.8,[8,[8,[[[[ [[[
[[-41,{},[[[[{},{}, [[[{},{},[[false, [[false, [[[{},8,[-41.8,[8,[8.8,[8,[[[{},{}, [[[
[[-418,[8,[[[
[[-41.8,[8,[8,
[[-41.8,[-41.8,[8,[8,[[[[[-41.8,[8,[
[[-418,[8,[[[[[[-41.8,[8,[8,[[[[ [[[
[[-41,{},[[[[{},{}, [[[{},{},[[false, [[false, [[[{},8,[-41.8,[8,[8,[[[[[-20.8,[8,[8,[[1.8,[3,[0,[[[[ [[[
[[-418,[8,[[[
[[-41,{},[[false, [[false, [[[{},8,[-41.8,[8,[8,[[[[[-41.8,[8,[8,[[[[ [[[ [[-41.8,[3,[8,[[[[ [[[
[[-418,[8,[[[
[[-41.8,[8,[8,
[[-41.8,[-41.8,[8,[8,8,[8,[8,[[[[[-41.8,[7E-5,7E-5,3E8,[
[[-418,[8,[[[[[[-41.8,[8,[8,[[[[ [[[
[[-41,{},[[[[{},{}, [[[{},{},[[false, [[false, [[[{},8,[-41.8,[8,[8.8,[8,[[[{},{}, [[[{},{},[[false, [[false, [[[{},8, [[[
[[-41,{},[[[[{},{}, [[[{},{},[[false, [[false, [[-836,[8,[[[
[[-41.8,[8,[8,
[[-41.8,[-41.8,[8,[8,[[[[[-41.8,[8,[
[[-418,[8,[[[[[[-41.8,[8,[8,[[[[ [[[
[[-41,{}
,[[[[{},{
}, [[[{},{},[[false, [[false, [[[{},8,[-41.8,[8,[8,[[[[[-20.8,[8,[8,[[1.8,[3,[8,[[[[ [[[3,[8,[[[[ [[[
[[-418,[8,[[[
[[-41.8,[8,[8,
[[-41.8,[-41.8,[8,[8,[[[[[-41.8,[8,[
[[-418,[8,[[[[[[-41.8,[8,[8,[[[[41.8,[8,[8,[[[[ [[[ [[-20.8,[3,[8,[[[[ [[[
[[-418,[8,[[[
[[-41.8,[8,[8,
[[-41.8,[-41.8,[8,[8,[[[[[-41.8,[8,[
[[-418,[8,[[[ [[[ [[-41.8,[3,[8,[[[[ [[[
[[-418,[8,[[[
[[-41.8,[8,[8,
[[-41.8,[-41.8,[8,[8,[[[[[-41.8,[8,[
[[-418,[8,[[[[[[-41.8,[8,[8,[[[[ [[[
[[-41,{},[[[[{},{}, [[[{},{},[[false, [[false, [[[{},8,[-41.8,[8,[8,[[[[[-20.8,[8,[8,[[1.8,[3,[8,[[[[ [[[
[[-418,[8,[[[
[[-41,{},[[false, [[false, [[[{},8,[-41.8,[8,[8,[[[[[-41.8,[8,[8,[[[[ [[[ [[-41.8,[3,[8,[[[[ [[[
[[-418,[8,[[[
[[-41.8,[8,[8,
[[-41.8,[-41.8,[5,[8,[8,[[[[[-41.8,[78,[
[[-418,[8,[[[[[[-41.8,[8,[8,[[[[ [[[
[[-41,{},[[[[{},{}, [[[{},{},[[false, [[false, [[[{},8,[-41.8,[8,[8,8,[8,[[[{},{}, [[[{},{},[[false, [[false, [[[{},8, [[[
[[-41,{},[[[[{},{}, [[[{},{},[[false, [[false,34e55,335223334e55,33e5,334e55,3e5,3999099999,8,99999990999909999,9990999998,9919999999,999099999,[-41,{},[[[[{},{}, [[[{},99999,99909999,999099999,8,9999999049999,8,@91999999,4e55,33
Binary file not shown.
@@ -0,0 +1 @@
{"tl\u041f\u043e\u043b\u0442\u043e\u04440\u041f\u043e\u043b\u0442\u043e\u0440\u0430 \u0417\u0435\u043c\u043b\u0435\u043b\u04343a\u043e\u0A3f\u}
Binary file not shown.
@@ -0,0 +1 @@
"\u9999999{ 99999999999999999999 ,
Binary file not shown.
@@ -0,0 +1 @@
["\uDA9D\uDDDDux\uDA9D\uDDDdux\uDA9D\uDDA9D\uDA9D\uDDDDDDux\uDA9D\uDDDduxux\uDA9D\uDDDdDDDux\uDA9D\uDDDdu|\uDA4D\uDDA9D\uDA9D\uDDDDDDux\uDA9D\uDDDdDDA9D\uDA9D\uDDDDDDux9D\uDA9D\uDDDDDDux\uDA9D\uDDDduxux\uDA9D\uDDDdDDDux\uDA9D\uDDDdu|\uDA9D\uDDADdux\uDA9D\uDDDdu|\uDA4D\uDDA9D\uDA9D\uDDDDDDux\uDA9D\uDDDdDDA9D\uDA9D\uDDDDDDux9D\uDA9D\uDDDDDDux\uDA9D\uDDDduuDDDDDDux\uDA9D\uDDDddDDDux\uDA9D\uDDDDDDdu|\uDA9D\uDDA9D\uDA9D\uDDDDDDux\uDA9D\uDDDdDDA9D\uDA9D\uDDDDDDux9D\uDA9D\uDDDDDDux\uDA9D\uDDDduxux\uDA9D\uDDDdDDDux\uDA9D\uDDDdu|\uDA4D\uDDA9D\uDA9D\uDDDDDDux\uDA9D\uDDDdDDAuDDDD
@@ -0,0 +1,2 @@
[[[ true,[[[[true, true,true,true,[ true,[[[[[["\"\b\b\f[\n\"\\!\/\b\\50\"\"&\\u30af\u0061-u6\u0030\\u30af\u0061-u6\u000af\u0061-u6\"6\u003061-u6\"\\u30af\u0061-u:6\u0030\\u30af61-u6\"6\u003061-u6\"\\u30af\u0061-u:6\u0030\\u30af\u0061-u6\u0030\u30af\u0061-u6\"630\u30af\u0061-u6\"\u30af\u0061-u6\"\\u30af\u0061-u6\u0030\\\\u30af\[[[[[[
{"7[-2":u0-u3true\r]\/\6f\\/][99\f",8,9999
@@ -0,0 +1,2 @@
{"1f\ue
44e\]€0u0
Binary file not shown.
@@ -0,0 +1,4 @@
[4,[5,[5,[4,[6,[5,[5,55,5,[[5,[4,[5,[5,[5,5,[5,[5,[[5,[5,[415,[4,[5,[5,[3,[5,5,[5,[5,[[null,[415,[[5,[5,[415,4,5,[[5,5,[5,[5,[[null,5,[5,[5,[[5,[5,[415,[4,[5,[5,[3,[5,[5,[5,5,[[5,[4,[5,[[5,5,[5,[5,[[null,[415,[4,[5,[[5,[4,[5,[5,[5,5,[5,[5,[[5,[5,[415,[4,[5,[5,[4,[5,[5,[5,5,[[5,[4,[5,[[5,5,[5,[5,[[null,[415,[4,[5,[5,[4,5,[5,5,[[5,[4,[5,[[5,5,[5,[5,[[null,[413,[5,[5,[5,5,[[5,[4,[5,[[5,5,[5,[5,[[null,[415,[4,[5,[[5,[4,[5,[5,[5,5,[5,[5,[[5,[5,[415,[4,[5,[5,[4,[5,[5,[5,5,[[5,[4,[5,[[5,5,[5,[5,[[null,[415,[4,[5,[5,[4,5,[5,5,4,[5,[5,[5,5,[5,[5,[[5,[5,[415,[4,[5,[5,[[5,[[null,[415,[4,[5,[[5,[4,[5,[5,[5,5,[5,[5,[[5,[5,[415,[4,[5,[5,[4,[5,[5,[5,5,[[5,[4,[5,[[5,5,[5,[5,[[null,[415,[4,[5,[5,[4,5,[5,5,[[[5,5,[5,[5,[[null,[415,[[5,[5,[415,4,5,[[5,5,[5,[5,[[null,5,[5,[5,[[5,[5,[415,[4,[5,[5,[3,[5,[5,[5,5,[[5,[4,[5,[[5,5,[5,[5,[[null,[415,[4,[5,[[5,[4,[5,[5,[5,5,[5,[5,[[5,[5,[415,[4,[5,[5,[4,[5,[5,[5,5,[[5,[4,[5,[[5,5,[5,[5,[[null,[415,[4,[5,[5,[4,5,[5,5,[[5,[4,[5,[[5,5,[5,[5,[[null,[413,[5,[5,[5,5,[[5,[4,[5,[[5,5,[5,[5,[[null,[415,[4,[5,[[5,[4,[5,[5,[5,5,[5,[5,[[5,[5,[415,[4,[5,[5,[4,[5,[5,[5,5,[[5,[4,[5,[[5,5,[5,[5,[[null,[415,[4,[5,[5,[4,5,[[[[5,5,[5,[5,[[null,[415,[[5,[5,[415,4,5,[[5,5,[5,[5,[[null,5,[5,[5,5,[5,[5,[[5,[5,[415,[4,[5,[5,[4,[5,[5,[5,5,[[5,[4,[5,[[5,5,[5,[5,[[null,[415,[4,[5,[5,[4,5,[5,5,[[[5,5,[5,[5,[[null,[415,[[5,[5,[415,4,5,[[5,5,[5,[5,[[null,5,[5,[5,[[5,[5,[415,[4,[5,[5,[3,[5,[5,[5,5,[[5,[4,[5,[[5,5,[5,[5,[[null,[415,[4,[5,[[5,[4,[5,[5,0,[[5,[4,[5,[[5,5,[5,[5,[[null,[415,[4,[5,[[5,[4,[5,[5,[5,5,[5,[5,[[5,[5,[415,4,5,[[5,5,[5,[5,[[null,[415,[4,[5,[[5,[4,[5,[5,[5,5,[5,[4,[[5,[5,[415,4,[5,[5,[5,55,5,[[5,[4,[5,[5,[5,5,[5,[5,[[5,[5,[415,[4,[5,[5,[[0,[[null,[415,[4,[5,[[5,[4,[5,[5,[5,5,[5,[5,[[5,[5,[415,[4,[5,[5,[4,[5,[5,[5,5,[[5,[4,[5,[[5,5,[5,[5,[[null,[415,[4,[5,[5,[4,5,[5,5,[[[5,5,[5,[5,[[null,[415,[[5,[5,[4,[5,[5,[4,5,[5,5,[[5,[4,[5,[[5,5,[5,[5,[[null,[413,[5,[5,[5,5,[[5,[4,[5,[[5,5,[5,[5,[[null,[415,[4,[5,[[5,[4,[5,[5,[5,5,[5,[5,[[5,[5,[415,[4,[5,[5,[4,[5,[5,[5,5,[[5,[4,[5,[[5,5,[5,[5,[[null,[415,[4,[5,[5,[4,5,[[[[5,5,[5,[5,[[null,[415,[[5,[5,[415,4,5,[[5,5,[5,[5,[[null,5,[5,[5,5,[5,[5,[[5,[5,[415,[4,[5,[5,[4,[5,[5,[5,5,[[5,[4,[5,[[5,5,[5,[5,[[null,[415,[4,[5,[5,[4,5,[5,5,[[[5,5,[5,[5,[[null,[415,[[5,[5,[415,4,5,[[5,5,[5,[5,[[null,5,[5,[5,[[5,[5,[415,[4,[5,[5,[3,[5,[5,[5,5,[[5,[4,[5,[[5,5,[5,[5,[[null,[415,[4,[5,[[5,[4,[5,[5,0,[[5,[4,[5,[[5,5,[5,[5,[[null,[415,[4,[5,[[5,[4,[5,[5,[5,5,[5,[5,[[5,[5,[415,4,5,[[5,5,[5,[5,[[null,[415,[4,[5,[[5,[4,[5,[5,[5,5,[5,[4,[[5,[5,[415,4,[5,[5,[5,55,5,[[5,[4,[5,[5,[5,5,[5,[5,[[5,[5,[415,[4,[5,[5,[[0,[[null,[415,[4,[5,[[5,[4,[5,[5,[5,5,[5,[5,[[5,[5,[415,[4,[5,[5,[4,[5,[5,[5,5,[[5,[4,[5,[[5,5,[5,[5,[[null,[415,[4,[5,[5,[4,5,[5,5,[[[5,5,[5,[5,[[null,[415,[[5,[5,[415,4,5,[[5,5,[5,[5,[[null,5,[5,[5,[[5,[5,[415,[4,[5,[5,[3,[5,[5,[5,5,[[5,[4,[5,[[5,5,[5,[5,[[null,[415,[4,[5,[[5,[4,[5,[5,[5,5,[5,[5,[[5,[5,[415,[4,[5,[5,[4,[7,[5,[5,5,[[5,[4,[5,[[5,5,[5,[5,[[null,[415,[4,[5,[5,[4,5,[5,5,[[5,[4,[5,[[5,5,[5,[5,[[null,[413,[5,[5,[5,5,[[5,[4,[5,[[5,5,[5,[5,[[null,[415,[4,[5,[[5,[4444444444444444444444444444444444444444444444444444444444444444444444444444,[5,[5,[5.75,775,[5,7,5,[5,[5,[[5,[5,[415,[4,[5,[5,[4,[5,[5,[5,5,[[5,[4,[5,[[5,5,[5,[5,[[null,[415,[4,[5,[5,[4,5,[5,5,4,[5,[5,[5,5,[5,[5,[[5,[5,[415,[4,[5,[5,[[5,[[null,[415,[4,[5,[[5,[4,[5,[5,[5,5,[5,[5,[[5,[5,[415,[4,[5,333333333
,0,333333333
,0,3333,null,0,null,null,[1,[1,null,null,null,[0,null,null,0,null,null,null,[0,null,8333334
,0,0,333,[5,[5,[[5,[5,[41,
@@ -0,0 +1 @@
"fa\udafa\udffa2fqfafa2fqfa\udafa\udffa2fffa\udafa\udffa2ffa\udafa\udfa2fffa\udafa\udffa2ffa\udafa\udffadffa4fa2@@@@@a2@@@Aa2@2fqfa\udafa\udffa2fffa\udafa\udffa2ffa\udafa\udfa2fffa\udafa\udffa2ffa\udafa\udffadffa2fa2@@@@@a2@2udffa2@@@Aaa\udafa\udffa2fffa\udafa\udffa2ffa\udafa\udfa2fffa\udafa\udffa2ffa\udafa\udffadffa2fa2@@@@@a2@2@fa\udafa\udffa2fqfa\udafa\udffa2fffa\udafa\udffa2ffa\udafa\udfa2fffa\udafa\udffa2ffa\ud2fffa\udafa\udffa2ffa\udafa\udfa2ff!!!@@a2@@@@AA
@@ -0,0 +1 @@
[[{"%min":58, "mJ
Binary file not shown.
Binary file not shown.
@@ -0,0 +1 @@
"\\35\u760a5\u760a\u021e\u0433Zb\u0835\u760b\u0835\u760a\u0ae0\u4342c\u042b\u0835\u760a\u043e\u6870985\u760a\u0ae0\u43422b\u0835\u760a
@@ -0,0 +1 @@
["b\b\b\f\b\r\\/\b\r\\/\b\b\\\/\b\\ №"\\\ИИИИИBИИ\\b
@@ -0,0 +1 @@
{"titlA":"\u7 }itl
@@ -0,0 +1,4 @@
␍ [[0,0,[
12011111111112111111110,5,[
[[],[],["{>>>>>>>>>>>>>>T>>>>>>>>>>>[]w,[[],=[],[],[[],[3>>>>>>>>>>>->>>>>>>>>;":[{"":[{
Binary file not shown.
@@ -0,0 +1 @@
[false, [false, false, false, [ { "min": -2.0e+28, "man": -3.8, "max": 8, "man": -3.8, "max": 2.0e+28, "man": -3, "max": 8, "man": -3.8, "max": { "min": -2.0e+28, "man": -3.8, "max": 8, "man": -2.0e+28, "man": -3.8, "max": 8, "man": [ [ { "min": -2.0e+28, "man": -3.8, "max": 8, "man": -3.8, "max": 1.0e+28, "man": -3, "max": 8, "man": -3.8, "max": { "min": -2.0e+28, "man": -3.8, "max": 8, "man": -3.8, "max": 1.0e+28, "man": -3, "max": 8, "man": -3.8, "max": { "min": -2.0e+28, "man": -3.8, "max": 8, "man": -3.8, "max": 1.0e+28, "man": { "min": -2.0e+28, "man": -3.8, "max": 8, "man": [ { "min": -2.0e+28, "man": -3.8, "mmax": { "min": -2.0e+28, "man": -3.8, "max": { "min": -3.8, "max": 1.0e+28, "man": { "min": -2.0e+28, "man": -3.8, "max": 8, "man": -2.8, "maAx": 1.0e+28, "man": -6, "max": [ [ [ { "min": -2.0e+28, "man": -3, "max": 8, "man": -3.8, "max": { "min": -2.0e+28, "man": -3.8, "max": -3.8, "max": 8, "man": -3.8, "max": 1.0e+28, "man": -3, "max": 8, "man": -3.8, "max":[ { "min": -2.0e+28, "man": -3.8, "max": 8, "man": -3.8, "max": 1.0e+28, "man": -3, "max": 8, "man": -3.8, "max": { "min": -2.0e+28, "man": -3.8, "max": 8, "man": -3.8, "max": 1.0e+28, "man": -3, "max": 8, "man": -3.8, "max": { "min": -2.0e+28, "man": -3.8, "max": 8, "man": -3.8, "max": 1.0e+28, "man": -3, "max": 8, "man": -3.8, "max": { "min": -2.0e+28, "man": -3.8, "max": 8, "man": -3.8, "max": 1.0e+28, "man": -3, "max": [ [ [ { "min": -2.0e+28, "man": -3.8, "max": 8, "man": -3.8, "max": 1.0e+28, "man": -3, "max": 8, "man": -3.8, "max": { "min": -2.0e+28, "man": -3.8, "max": 8, "man": -3.8, "max": 1.0e+28, "man": -3, "max": 8, "man": -3.8, "max": { "min": -2.0e+28, "man": -3.8, "max": 8, "man": -3.8, "max": 1.0e+28, "man": { "min": -2e+28, "man": -3.8, "max": 8, "man": -3.8, "max": 1.0e+28, "man": -3, "max": [ [ [ { "min": -2.0e+28, "man": -3.8, "max": { "min": -2.0e+28, "man": -3.8, "max": 8, "man": -3.8, "max": 1.0e+28, "man": -3, "max": 8, "man": -3.8, "max": { "min": -2.0e+28, "man+": -3.8, "max": 8, "man": -3.8, "max": 1.0e+28, false, [false, fa { "min": -2.0e+28, "man": -3.8, "-ax": 8, "man": -3.8, "max": 1.0e+28, "man": { "min": -2.0e+28,": -3.8, "
@@ -0,0 +1,2 @@
{"7":"k995.597", "7":"{7", "7:
false
@@ -0,0 +1 @@
{"1f\u043e\u043b\u0441]u0d41d\ud82d\udd9c8\ud5de39\ud20d41d\ud82d\udd9c8\ud5de39\ud41d\ud82d\udd98d29dc8ud5de3\ud41d41d\ud82d\udd9c8\ud5de39\ud41d\ud82d\udd982dd9c1d4u043e\u0043ba\u043e\u040430 \u0417\u0A435\u043c\u043b\u043043e\u043f0\u0430 \u0417\u0435\u043c'\u043b\u0835\u760a\u043e\u020217\u0417\u0982dd9c8u\2d8d435\u04\ude43e\u040430d \u043b\u0435\u043a
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -0,0 +1 @@
[false, [false, false, false, [false, [{"6,..\udafa\udffaXXe
@@ -0,0 +1 @@
"\\u30af\u0061-uu300af\u0061-006030\"uF800\uF628\uD400\uF400\uF800\uF628\"\uF628\uD401\uF628\uD400\uF800uD400\uF800u30af\u0061-]\u0877\\u0061-006030\"\uF628\"\uF628\uD400\uF800\uF628\uD400\uF400\uF800\uF62B\"\uF628\uD4030\\u30af\u0066eu6\"\u30af00\u30a0030\u30af\u0061-006030\"\uF628\"\uF628\uD400\uFÇÇÇ
@@ -0,0 +1 @@
{"tit7\u021743C\u542bd\u
Binary file not shown.
Binary file not shown.
@@ -0,0 +1 @@
["u\uDDDD\u聞
@@ -0,0 +1,2 @@
[{"7":"{7", "7":
"{7", "":"{", "":".597", "7\
Binary file not shown.
@@ -0,0 +1 @@
"ffa\udafa\udffa2
@@ -0,0 +1,3 @@
␍ [[0,0,[112011111111112111111110,5,[
[[],[],">>>>>>>>>>>>>>>>>>>>Y>>>>>>>>>[],[[],[?],[[],[],[[],[4>>>>>>>>>>>>>?>;":[
@@ -0,0 +1 @@
{ ":
@@ -0,0 +1 @@
Binary file not shown.
Binary file not shown.
@@ -0,0 +1,3 @@
␍ [[0,0,[
12011111111112111111110,5,["{>>>>>>>>>>>>>>>>>>>>>>>>>>>?>>>>[>>>>>>>>>>>?>>[],[[],[[],[[]],[[],[3>>>>>->>""uf
@@ -0,0 +1,11 @@
[[4,
2,2,
{},{},{},
[[{},[{},[{},
{},
{},{},
{},[{},
{␍␍␍␍␍␍␍␍␍␍"\uDADD\uDDDD\uEDADDDu\\{},{},
{},[{},
{÷òòò‚Ó„ß
@@ -0,0 +1 @@
["\uDA8D\uDDDDux\uDA9D\uDDDdDux\uDA9D\uDDDduxux\uDA9D\uDDDdDDDux\uDA9D\uDDDeu|\uDA9D\uDDDDDDux\uDA9D\uDDDdDDADDDux\uDA9D\uDDDduxux\uDA9D\uDDDdD\uDA9D\uDDDduuDDA9D\uDA9D\uDDDDD-ux\uDA9D\uDDDdDDDDDDux\uDA9D\uDDDduxux\uDA9D\uDDDdDux\uDA9D\uDDDdu|DDux\uD—A8D\uDDDddDDDD
Binary file not shown.
Binary file not shown.
@@ -0,0 +1 @@
[[[[{},{"435\u04317
@@ -0,0 +1 @@
{"":[{"":[{"":["\ョ
@@ -0,0 +1 @@
{"tl\u041f\u043e\u043b\u0442\u043e\u0440\u0430 \u0417\u0435\u043c\u043b\u0435\u043b\u04343a\u043e\u043f\u}
@@ -0,0 +1 @@
["\uDA9D\uDDDDux\uDA9D\uDDDdux\uDA9D\uDDA9D\uDA9D\uDDDduxux\uDA9D\uDDDdDDDux\uDA9D\uDDDdu|\uDA4D\uDDA9D\uDA9D\uDDDDDDux\uDA9D\uDDDdDDA9D\uDA9D\uDDDDDDux9D\uDA9D\uDDDDDD*x\uDA9D\uDDDduxux\uDA9D\uDDDdDDDux\uDA9D\uDDDdu\uDA9D\uDDdDDA0
Binary file not shown.
Binary file not shown.
@@ -0,0 +1 @@
{"x":[{"id": "xxx"}],"x":[{"i":[{"id": ""}],"x":[{"i": "xxx"}],"x":[{"id": "xx"}],"x":[{"idd": "xx"}],"x":[{"id": "xxxxxxx+x"}],"x":[{"id": "xx"}],"x":[{"idd": "xx"}],"x":[{"id": "x"}],"":[{"id": "xxx"}],"x":[{"id": "xx"}],"x":[{"idd": "xx"}],"x":[{"id": "x"}],"x":[{"iid": "xxxxxxx"}],"x":[{"i":[{"id": "zxxxxxx"}],"x":[{"i":[{"id": "xxxxxxxxx"}],"x":[{"id": "xx"}],"x":[{"idd": "xx"}],"xd": "xxxx"}],"x":[{"id":"xx"}],"x":[{"idd": "xx"}],"":[{"id": ""}],"x":[{"i":[{"id": "xxx"}],"x":[{"id": "xx"}],"": "xx"}{"id""}
@@ -0,0 +1 @@
[[[ true,[[[[true, true,true,true,[ true,[[[[[["\"\b\b\f[\n\"\\!\/\b\\50\"\"&\\u30af\u0061-u6\u0030\\u30af\u0061-u6\u000af\u0061-u6\"6\u003061-u6\"\\u15af\u0061-u@:6\u0030\\u30af61-u6\"6\u003061-u6\"\\u30af\u0061-u:6\u0030\\u30af\u0061-u6\u0030\u30af\u0061-u6\"630\u30af\u0061-u6\"\u30af\u0061-u6\"\\u30af\u0061-u6\u0030\\\\u60af\u0061-u6\u0030\u30a0061-q6\u000af\u0061-u6\"6\u000af\u0061-u2\u0030\\u30061-u6\"6\u00306Y1-u6\"\\u30af\u0061-u@:6\u0576\\u30af61-u6\"6\u003061-u6\"\\u30af\u0061-u:6\u0030\\u30af\u0061-u6\u0030\u30af\u0061-u6\"630\u30af\u0061-u6\"\u30af\u0061-uu2\u0030\\u30061999
@@ -0,0 +1 @@
{"x":[{"id": "xxxxxxh$xxxxxxxxxxx"}],"x":[{"i":{"x":[{"id": "xxxxxxxxxxxhxxxxxxxxxxxxxxxxxxxxxx"}],"x":[{"i":[{"id": "xxxxxx"}],"x":[{"i":[{"id": "xxxxxxxxxxhxxxxxxxxxxxxxxxxxxxxxx"}],"x":[{"i":[{"id": "xxxxxx"}],"x":[{"i":[{"id": "xxxxxxxxxxxxxxxxxxxudc83dxxxxxx"}],"x":[{"id": "xx"}],"x":[{"idd": "xxxxxxxud83dxxxxxx"}],"x":[{"id": "xx"}],"x":[{"idd": "xx"}],"x":[{"id": "x"}],"x":[{"idd": "xx"}],"x":[{"id": "x"}],"x":[{"i":[{"id": "xxxxxxxxxxxxxxxxxxxudc83dxxxxxx"}],"x":[{"id": "xx"}],"x":[{"idd": "xxxxxxxud83dxxxxxx"}],"x":[{"id": "xx"}],"x":[{"idd": "xx"}],"x":[{"id": "xxxxxxxx"}],"x":[{"id": "xx"}],"x":[{"idd": "xx"}],"x":[{"id": "xxxxxxxxxxxxxxx]}
Binary file not shown.
@@ -0,0 +1 @@
["\"\b\b\f\n\"\\/\b\b/\b\\b\r\\/\b\b\\\/\b\\ 𝂬 ] 𝄟 𝂬] 𝄞 𝂬 \b\b\f\b\r\\/\b\b\f\n\"\\\/\b\\\/\b\b\f\r\\/\b\b\\\/\b\\ 𝂬 ] 𝄟 𝂬] 𝄞 𝂬 ] 𝄟 𝂌 ](€ ] 𝄞 𝆞 𝂬 ] 𝄞 𝂬\/:b\b\/\b\\\\\b\b\f\b\r\\/\b\b\\\/\b\\ 𝂬 ] 𝄟 b\f\\n\"\\\/\b\n\"\\\/f\n\"\\\/\b\b/:\/\b\\\n\"\\\b\b\f\b\r\\\/\b\\ 𝂬 ] 𝄟 𝂬] 𝄞 𝂬 \b\b\f\b\r\\/\b\b\f\n\"\\/\b\\ 𝂬 ] 𝄟 𝂬] 𝄞 𝂬 ] 𝄟 𝂌 ](€ ] 𝄞 𝄞 𝂬 ] 𝄞 𝂬\/:b\b\\\\b\b\f\b\r\\/\b\b\\\/\b\\ 𝂬 ] 𝄟 𝂬] 𝄞 𝂬 \b\b\f\b\r\\/\b\b\f\n\"\\\/\b\b\f\n\"\f/:b\b/\b\\,/\b b\f\\n\"\\\/\b\n\"\\\/f\n\"\\\/\b\b/:\/\b\\\n\"\\\b\b\f\b\r\\\/\]\\ \f\n\"\\\b
@@ -0,0 +1 @@
"\\u3@af\uF628\"[3,3\uF628\uD500\uF8000\uF800\uF628\uD400\uF4F62f\uF628\"auF6200\uF800\uF628\uD400\uF400\uF800\uF628\"\3au0"
@@ -0,0 +1 @@
{"id- &": {"id": { "id-": {"id": {"id-": {"id#": { "id-": { "id-": { "": {"id#": { "id-d- &": {"id": { "id-": { "min": -2.0e+28, "manDDux\uDA9D\uDDDeu|\uDA9D\uDDDDDDux\uDA9D\uDDDdDDADDDux\uDA9D\uDDDduxux\uDA9D\uDDDdD\uDA9D\uDDDduuDDA9D\uDA9D\uDDDDD-ux\uDA9D\uDDDdDDAAuDDDDDDDux\uDA9D\uDDDduxux\uDA9D\uDDDdDux\uDA9D\uDDDdu|DDux\uDA9D\uDDDddDDDDDux\uDA9D\uDDDduxux\uDA9D\uDDDdDux\uDA9D\uDDDdu|DDux\uDA9D\uDDDddDDux\uDA9D\uDDDdu|\uDA4D\uDDA9D\uDA9D\uDDDDDDux\uDA0D\uDDDdD;A0D\uDA9D\uDDDduxux\uDA9D\uDDDdDux\uDA9D\uDDDdu|Dux\uDA9D\uDDDdDDDux\uDA9D\uDDDduDDdu|\uDA9D\uDDDDDux\uDA9D\uDDDdDDA9D\uDA9D\uDDDDDDDDD\uDA9D\uDDDduxu\uDA9D\uDDDdDDEux\uDA9D\uDDDdDux\uDA9D\uDDDduxux\uDA9D\uDDDdDDDux\uDA9D\uDDDbu|\uDA4D\uDDA9D\uDA9D\uDDDDux\uDA9D\uDDDdDDDD\uDA9D\uDDDduxux\uDA9D\uDDDdDDDux\uDA9D\uDDDdu|\uDA8D\uDD{ "min": -2.0e+2 "max": 1.0e+2828:0
@@ -0,0 +1 @@
{"\uDA9D\uDDDDux\uDA9D\uDDDdux\uDA4D\uDDA9D\uDA9D\uDDDduxux\uDA9D\uDDDdDDDux\uDA9D\uDDDdu|\uDA4D\uDDA9D\uDA9D\uDDDDDDux\uDA9D\uDDDdDDA9D\uDA9D\uDDDDDDux9D\uDA9D\uDDDDDDux\uDA9D\uDDDduxux\uDA9D\uDDDdDDDux\uDA9D\uDDDdu\uDA9D\uDDA9D\uDA9D\uDDDDD-2Dux\uDA9D\uDDDdDDduxux\uDA9D\uDDDdDDDux\uDA9D\uDDDdu|\uDA9D\uDDADduullx\uDA9D\uDDA9D\uDA9D\uDDDDDDux\uDA9D\uDDDduxux\uDA9D\uDDDdDDDux\uDA9D\uDDDdu|\uDA4D\uDDA9D\uDA9D\uDDDDDDux\uDA9D\uDDDdDDA9D\uDA9D\uDDDDDDux9D\uDA9D\uDDDDDDux\uDA9D\uDDDduxux\uDA9D\uDDDdDDDux\uDA9D\uDDDdu|\uDA9D\uDDA9D\uDA9D\uDDDDDDux\¬ \b\b\f\bDA9Dux\uDA9D\uDDDdDDA0
@@ -0,0 +1 @@
["\uDA9D\uDDDDux\uDA9D\uDDDdux\uDA9D\uDDA9D\uDA9D\uDDDDDDux\uDA9D\uDDDduxux\uDAAD\uDDDdDDDux\uDA9D\uDDDdu|\uDA4D\uDDA9D\uDA9D\uDDDDDDux\uDA9D\uDDDdDDA9D\uDA9D\uDDDDDDux9D\uDA9D\uDDDDDDux\uDA9D\uDDDduxux\u8DDDDDDux9D\uDA9D\uDDDD'DDD\uDA9D\uDDDD
@@ -0,0 +1 @@
{"title":"3e\u043b\u0441]u040\u0430 \u00e7\u0435\u043c\u04440\u0430 \u0411\u0870\u525c\u043b\u08442043b\u0435\u760ae\u0440\u041fu0430eu0435\u760a\u04043b\u0442\u043E\u0443b\u0441]u04043e\u0440\u0433b\u0835\u760a\u043e\u020217.1c\u043bu0440\u0430 \u0417\u0870\u043c\u043b\u0835\u435a\u0435\u760a\u04043b\u0442\u043E\u0443b\u0441]u04043e\u0440\u0433b\u0835\u760a\u043e\u020217.1c\u043bu044\u043c\u04440\u0430 \u0411\u0870\u525c\u043b\u08442043b\u0435\u760ae\u0440\u041fu0430eu0435\u760a\uAa\u04
@@ -0,0 +1,60 @@
[[[{},{}, [[[{},{},[[[[{},{}, [[[{},{},[[false, [[false, [[[{},8,[-41.8,[8,[8,[[[[[-41.8,[8,[8,[[[[ [[[ [[-41.8,[3,[8,[[[[ [[[
[[-418,[8,[[[
[[-41.8,[8,[8,
[[-41.8,[-41.8,[8,[8,[[[[[-41.8,[8,[
[[-418,[8,[[[[[[-41.8,[8,[8,[[[[ [[[
[[-41,{},[[[[{},{}, [[[{},{},[[false, [[false, [[[{},8,[-41.8,[8,[8,[[[[[-20.8,[8,[8,[[1.8,[3,[8,[[[[ [[[
[[-418,[8,[[[
[[-41,{},[[false, [[false, [[[{},8,[-41.8,[8,[8,[[[[[-41.8,[8,[8,[[[[ [[[ [[-41.8,[3,[8,[[[[ [[[
[[-418,[8,[[[
[[-41.8,[8,[8,
[[-41.8,[-41.8,[8,[8,[[[[[-41.8,[8,[
[[-418,[8,[[[[[[-41.8,[8,[7,[[[[41.8,[8,[8,[[[[ [[[ [[-41.8,[3,[8,[[[[ [[[
[[-418,[8,[[[
[[-41.8,[8,[8,
[[-41.8,[-41.8,[8,[8,[[[[[-41.8,[8,[
[[-418,[8,[[[[[[-41.8,[8,[8,[[[[ [[[
[[-41,{},[[[[{},{}, [[[{},{},[[false, [[false, [[[{},8,[-41.8,[8,[8,[[[[[-20.8,[8,[8,[[1.8,[3,[8,[[[[ [[[
[[-418,[8,[[[
[[-41,{},[[false, [[false, [[[{},8,[-41.8,[8,[8,[[[[[-41.8,[8,[8,[[[[ [[[ [[-41.8,[3,[8,[[[[ [[[
[[-418,[8,[[[
[[-41.8,[8,[8,
[[-41.8,[-41.8,[8,[8,8,[8,[8,[[[[[-41.8,[8,[
[[-418,[8,[[[[[[-41.8,[8,[8,[[[[ [[[
[[-41,{},[[[[{},{}, [[[{},{},[[false, [[false, [[[{},8,[-41.8,[8,[8.8,[8,[[[{},{}, [[[{},{},[[false, [[false, [[[{},8, [[[
[[-41,{},[[[[{},{}, [[[{},{},[[false, [[false, [[-418,[8,[[[
[[-41.8,[8,[8,
[[-41.8,[-41.8,[8,[8,[[[[[-41.8,[8,[
[[-418,[8,[[␍[[[[-41.8,[8,[8,[[[[ [[[
[[-41,{},[[[[{},{}, [[[{},{},[[false, [[false, [[[{},8,[-41.8,[8,[8,[[[[[-20.8,[8,[8,[[1.8,[3,[8,[[[[ [[[3,[8,[[[[ [[[
[[-418,[8,[[[
[[-41.8,[8,[8,
[[-41.8,[-41.8,[8,[8,[[[[[-41.8,[8,[
[[-418,[8,[[[[[[-41.8,[8,[8,[[[[41.8,[8,[8,[[[[ [[[ [[-41.8,[3,[8,[[[[ [[[
[[-418,[8,[[[
[[-41.8,[8,[8,
[[-41.8,[-41.8,[8,[8,[[[[[-41.8,[8,[
[[-418,[8,[[[[[[-41.8,[8,[8,[[[[ [[[
[[-41,{},[[[[{},{}, [[[{},{},[[false, [[false, [[[{},8,[-41.8,[8,[8,[[[[[8,[8,[8,
[[-41.8,[-41.8,[8,[8,[[[[[-41.8,[8,[
[[-418,[8,[[[[[[-41.8,[8,[8,[[[[ [[[
[[-41,{},[[[[{},{}, [[[{},{},[[false, [[false, [[[{},8,[-41.8,[8,[8,[[[[[-20.8,[8,[8,[[1.8,[3,[8,[[[[ [[[
[[-418,[8,[[[
[[-41,{},[[false, [[false, [[[{},8,[-41.8,[8,[8,[[[[[-41.8,[8,[8,[[[[ [[[ [[-41.8,[3,[8,[[[[ [[[
[[-418,[8,[[[
[[-41.8,[8,[8,
[[-41.8,[-41.8,[8,[8,[[[[[-41.8,[8,[
[[-418,[8,[[[[[[-41.8,[8,[7,[[[[41.8,[8,[8,[[[[ [[[ [[-41.8,[3,[8,[[[[ [[[
[[-418,[8,[[[
[[-41.8,[8,[8,
[[-41.8,[-41.8,[8,[8,[[[[[-41.8,[8,[
[ [-418,[8,[[[[[[-41.8,[8,[8,[[[[ [[[
[[-41,{},[[[[{},{}, [[[{},{},[[false, [[false, [[[{},8,[-417.777E-8,[[[[[-20.8,[8,[8,[[1.8,[3,[8,[[[[ { "$i": 9, "max": 8, "x": 2.0e+28, "m=n": -3.8, "max": 8, "man": -0e+20, "max": [[[
[[-418,[8,[[[
[[-41,{},[[false, [[false, [[[{},8,[-41.8,[8,[8,[[[[[-41.8,[8,[8,[[[[ [[[ [[-41.8,[3,[8,[[[[ [[[
[[-418,[8,[[[
[[-41.8,[8,[8,
[[-41.8,[-41.8,[8,[8,[[[[[-41.8,[8,[
[[-418,[8,[[[[[[-41.8,[8,[8,[[[[ [[[
[[-41,{},[[[[{},{}, [[[{},{},[[false, [[false, [[[{},8,[-41.8,[8,[8.8,[8,[[[{},{}, [[[{},{},[[false, [[false, [[[{},8, [[[
[[-41,{},[[[[{},{}, [[[{},{},[[false, [[false, "8[[-418,[8,[4,[5,[5,[4,[6 8, "man": -3.8, "max": 8, "max": 8, "man": ,[5,5, 5,[5,max
@@ -0,0 +1,7 @@
[[[[],[[[],[],[[[5, [[[{},8,[-41.8,[8,[8,[[[[[-41.8,[8,[8,[[[[ [[[ [[-41.8,[8,[[[[ [[[
[[-418,[8,[[[
[[-41.8,[8,[8,
[[-41.8,[-41.8,[8,[8,8,[8,[8,[[[[[-41.8,[8,[
[[-418,[8,[[[[[[-41.8,[8,[8,[[[[ [[[
[[-41,{},[[[[{},{}, [[[{},{},[[false, [[false, [[[{},6,[-41.8,[8,[8.8,[8,["\\u30af\u0061Yuu300af\u0061-006030\"uF800\uF628\u30af\u00030\u30af\u0061-006uF628\uD400\uF400\uF800\uF628\"\uF628\uD400\uF628\uD400\uF800uD400\uF800u30af\u0061-63?0\\u30af\u0061-u6\u0030\u30af\u0061-u6\"\u30af00\u30af\u0061-u6f\u0061-u6\u0030\u30af\u0061-006030\"\uF628\"\uF628\uD400\uF800\uF628\uD400\uF400\uF800\uF628\"\uF628\uD400\uF628\uD400\uF800uD400\uF800u30af\u0061-]\u0030\\0060\u30030\"\uF628\"\uF628\uD400\uF800\uF628\uD400\uF400\uF800\uF628\"\uF628\uD400\uF628\uD400\uF800uD4l00\0af\u0061-u6\"\uF800uD400\uF800u30af\u0061-63?0\\u30af\u0061-u6\u0030\u30af\u0061-u6\"\u30af00\u30af\u00 [[[-41.8,[8,[
[[-418,28\uD400\uF400\uF800\uF628\"\uF628\u}D400\uF628\uD40[false, [[false0\, u[[F800uD4l00\0af\u0061-u6\"
@@ -0,0 +1,60 @@
[[[{},{}, [[[{},{},[[[[{},{}, [[[{},{},[[false, [[false, [[[{},8,[-41.8,[8,[8,[[[[[-41.8,[8,[8,[[[[ [[[ [[-41.8,[3,[8,[[[[ [[[
[[-418,[8,[[[
[[-41.8,[8,[8,
[[-41.8,[-41.8,[8,[8,[[[[[-41.8,[8,[
[[-418,[8,[[[[[[-41.8,[8,[8,[[[[ [[[
[[-41,{},[[[[{},{}, [[[{},{},[[false, [[false, [[[{},8,[-41.8,[8,[8,[[[[[-20.8,[8,[8,[[1.8,[3,[8,[[[[ [[[
[[-418,[8,[[[
[[-41,{},[[false, [[false, [[[{},8,[-41.8,[8,[8,[[[[[-41.8,[8,[8,[[[[ [[[ [[-41.8,[3,[8,[[[[ [[[
[[-418,[8,[[[
[[-41.8,[8,[8,
[[-41.8,[-41.8,[8,[8,[[[[[-41.8,[8,[
[[-418,[8,[[[[[[-41.8,[8,[7,[[[[41.8,[8,[8,[[[[ [[[ [[-41.8,[3,[8,[[[[ [[[
[[-418,[8,[[[
[[-41.8,[8,[8,
[[-41.8,[-41.8,[8,[8,[[[[[-41.8,[8,[
[[-418,[8,[[[[[[-41.8,[8,[8,[[[[ [[[
[[-41,{},[[[[{},{}, [[[{},{},[[false, [[false, [[[{},8,[-41.8,[8,[8,[[[[[-20.8,[8,[8,[[1.8,[3,[8,[[[[ [[[
[[-418,[8,[[[
[[-41,{},[[false, [[false, [[[{},8,[-41.8,[8,[8,[[[[[-41.8,[8,[8,[[[[ [[[ [[-41.8,[3,[8,[[[[ [[[
[[-418,[8,[[[
[[-41.8,[8,[8,
[[-41.8,[-41.8,[8,[8,8,[8,[8,[[[[[-41.8,[8,[
[[-418,[8,[[[[[[-41.8,[8,[8,[[[[ [[[
[[-41,{},[[[[{},{}, [[[{},{},[[false, [[false, [[[{},8,[-41.8,[8,[8.8,[8,[[[{},{}, [[[{},{},[[false, [[false, [[[{},8, [[[
[[-41,{},[[[[{},{}, [[[{},{},[[false, [[false, [[-418,[8,[[[
[[-41.8,[8,[8,
[[-41.8,[-41.8,[8,[8,[[[[[-41.8,[8,[
[[-418,[8,[[␍[[[[-41.8,[8,[8,[[[[ [[[
[[-41,{},[[[[{},{}, [[[{},{},[[false, [[false, [[[{},8,[-41.8,[8,[8,[[[[[-20.8,[8,[8,[[1.8,[3,[8,[[[[ [[[3,[8,[[[[ [[[
[[-418,[8,[[[
[[-41.8,[8,[8,
[[-41.8,[-41.8,[8,[8,[[[[[-41.8,[8,[
[[-418,[8,[[[[[[-41.8,[8,[8,[[[[41.8,[8,[8,[[[[ [[[ [[-41.8,[3,[8,[[[[ [[[
[[-418,[8,[[[
[[-41.8,[8,[8,
[[-41.8,[-41.8,[8,[8,[[[[[-41.8,[8,[
[[-418,[8,[[[[[[-41.8,[8,[8,[[[[ [[[
[[-41,{},[[[[{},{}, [[[{},{},[[false, [[false, [[[{},8,[-41.8,[8,[8,[[[[[8,[8,[8,
[[-41.8,[-41.8,[8,[8,[[[[[-41.8,[8,[
[[-418,[8,[[[[[[-41.8,[8,[8,[[[[ [[[
[[-41,{},[[[[{},{}, [[[{},{},[[false, [[false, [[[{},8,[-41.8,[8,[8,[[[[[-20.8,[8,[8,[[1.8,[3,[8,[[[[ [[[
[[-418,[8,[[[
[[-41,{},[[false, [[false, [[[{},8,[-41.8,[8,[8,[[[[[-41.8,[8,[8,[[[[ [[[ [[-41.8,[3,[8,[[[[ [[[
[[-418,[8,[[[
[[-41.8,[8,[8,
[[-41.8,[-41.8,[8,[8,[[[[[-41.8,[8,[
[[-418,[8,[[[[[[-41.8,[8,[7,[[[[41.8,[8,[8,[[[[ [[[ [[-41.8,[3,[8,[[[[ [[[
[[-418,[8,[[[
[[-41.8,[8,[8,
[[-41.8,[-41.8,[8,[8,[[[[[-41.8,[8,[
[ [-418,[8,[[[[[[-41.8,[8,[8,[[[[ [[[
[[-41,{},[[[[{},{}, [[[{},{},[[false, [[false, [[[{},8,[-417.777E-8,[[[[[-20.8,[8,[8,[[1.8,[3,[8,[[[[ { "$i": 9, "max": 8, "x": 2.0e+28, "m=n": -3.8, "max": 8, "man": -0e+20, "max": [[[
[[-418,[8,[[[
[[-41,{},[[false, [[false, [[[{},8,[-41.8,[8,[8,[[[[[-41.8,[8,[8,[[[[ [[[ [[-41.8,[3,[8,[[[[ [[[
[[-418,[8,[[[
[[-41.8,[8,[8,
[[-41.8,[-41.8,[8,[8,[[[[[-41.8,[8,[
[[-418,[8,[[[[[[-41.8,[8,[8,[[[[ [[[
[[-41,{},[[[[{},{}, [[[{},{},[[false, [[false, [[[{},8,[-41.8,[8,[8.8,[8,[[[{},{}, [[[{},{},[[false, [[false, [[[{},8, [[[
[[-41,{},[[[[{},{}, [[[{},{},[[false, [[false, "8[[-418,[8,[4,[5,[5,[4,[6 8, "man": -3.8, "max": 8, "max": 8, "man": ,[5,5, 5,[5,max
@@ -0,0 +1 @@
[[{"1f.u043e\u043b\u0441]
@@ -0,0 +1 @@
{"":{"":{"":{":{
+9 -3
View File
@@ -8,14 +8,20 @@ extern "C" {
struct WeaselJsonCallbacks {
void (*on_begin_object)(void *userdata);
void (*on_end_object)(void *userdata);
/** The string data provided has already been unescaped. If `done` is false,
* this string may be incomplete and there will be another call with more data
/** The string data provided has already been unescaped, unless the
* WeaselJsonRaw flag is used. If `done` is false, this string may be
* incomplete and there will be another call, potentially with more data
*/
void (*on_string_data)(void *userdata, const char *buf, int len, int done);
/** The key data provided has already been unescaped, unless the
* WeaselJsonRaw flag is used. If `done` is false, this key may be
* incomplete and there will be another call, potentially with more data
*/
void (*on_key_data)(void *userdata, const char *buf, int len, int done);
void (*on_begin_array)(void *userdata);
void (*on_end_array)(void *userdata);
/*If `done` is false, this number may be incomplete and there will be another
* call with more data*/
* call, potentially with more data*/
void (*on_number_data)(void *userdata, const char *buf, int len, int done);
void (*on_true_literal)(void *userdata);
void (*on_false_literal)(void *userdata);
+37
View File
@@ -1,5 +1,6 @@
#pragma once
#include <cassert>
#include <cstdint>
#include <cstdio>
#include <string>
@@ -14,6 +15,9 @@ inline WeaselJsonCallbacks printCallbacks() {
result.on_string_data = +[](void *, const char *buf, int len, int /*done*/) {
printf("on_string_data `%.*s`\n", len, buf);
};
result.on_key_data = +[](void *, const char *buf, int len, int /*done*/) {
printf("on_key_data `%.*s`\n", len, buf);
};
result.on_begin_array = +[](void *) { puts("on_begin_array"); };
result.on_end_array = +[](void *) { puts("on_end_array"); };
result.on_number_data = +[](void *, const char *buf, int len, int /*done*/) {
@@ -30,6 +34,7 @@ inline WeaselJsonCallbacks noopCallbacks() {
result.on_begin_object = +[](void *) {};
result.on_end_object = +[](void *) {};
result.on_string_data = +[](void *, const char *, int, int) {};
result.on_key_data = +[](void *, const char *, int, int) {};
result.on_begin_array = +[](void *) {};
result.on_end_array = +[](void *) {};
result.on_number_data = +[](void *, const char *, int, int) {};
@@ -58,6 +63,11 @@ struct SerializeState {
if (!back.isObject && back.index > 0) {
result.append(",");
}
}
}
void on_end_value() {
if (!stack.empty()) {
auto &back = stack.back();
++back.index;
}
}
@@ -77,6 +87,7 @@ inline WeaselJsonCallbacks serializeCallbacks() {
auto *state = (SerializeState *)p;
state->stack.pop_back();
state->result.append("}");
state->on_end_value();
};
result.on_string_data = +[](void *p, const char *buf, int len, int done) {
auto *state = (SerializeState *)p;
@@ -86,7 +97,28 @@ inline WeaselJsonCallbacks serializeCallbacks() {
state->result.append("<");
}
state->result.append(std::string(buf, len));
if (!state->stack.empty() && state->stack.back().isObject) {
assert(state->stack.back().index % 2 == 1);
}
if (done) {
state->on_end_value();
state->startedData = false;
state->result.append(">");
}
};
result.on_key_data = +[](void *p, const char *buf, int len, int done) {
auto *state = (SerializeState *)p;
if (!state->startedData) {
state->startedData = true;
state->on_begin_value();
state->result.append("<");
}
state->result.append(std::string(buf, len));
assert(!state->stack.empty());
assert(state->stack.back().isObject);
assert(state->stack.back().index % 2 == 0);
if (done) {
state->on_end_value();
state->startedData = false;
state->result.append(">");
}
@@ -101,6 +133,7 @@ inline WeaselJsonCallbacks serializeCallbacks() {
auto *state = (SerializeState *)p;
state->stack.pop_back();
state->result.append("]");
state->on_end_value();
};
result.on_number_data = +[](void *p, const char *buf, int len, int done) {
auto *state = (SerializeState *)p;
@@ -112,6 +145,7 @@ inline WeaselJsonCallbacks serializeCallbacks() {
state->result.append(std::string(buf, len));
if (done) {
state->startedData = false;
state->on_end_value();
state->result.append(")");
}
};
@@ -119,16 +153,19 @@ inline WeaselJsonCallbacks serializeCallbacks() {
auto *state = (SerializeState *)p;
state->on_begin_value();
state->result.append("true");
state->on_end_value();
};
result.on_false_literal = +[](void *p) {
auto *state = (SerializeState *)p;
state->on_begin_value();
state->result.append("false");
state->on_end_value();
};
result.on_null_literal = +[](void *p) {
auto *state = (SerializeState *)p;
state->on_begin_value();
state->result.append("null");
state->on_end_value();
};
return result;
}
+12
View File
@@ -79,6 +79,18 @@ inline WeaselJsonCallbacks readValueCallbacks() {
state->on_end_value();
}
};
result.on_key_data = +[](void *p, const char *buf, int len, int done) {
auto *state = (ReadValueState *)p;
if (!state->startedData) {
state->startedData = true;
state->valueStack.emplace_back(std::string());
}
std::get<std::string>(state->valueStack.back()).append(buf, len);
if (done) {
state->startedData = false;
state->on_end_value();
}
};
result.on_begin_array = +[](void *p) {
auto *state = (ReadValueState *)p;
state->valueStack.emplace_back(std::make_unique<JsonArray>());
+2
View File
@@ -1,3 +1,5 @@
#include <cstdlib>
#include "parser3.h"
#include "weaseljson.h"
+70 -16
View File
@@ -90,7 +90,11 @@ struct Parser3 {
}
assert(len >= 0);
if (done || len > 0) {
callbacks->on_string_data(userdata, dataBegin, len, done);
if (inKey) {
callbacks->on_key_data(userdata, dataBegin, len, done);
} else {
callbacks->on_string_data(userdata, dataBegin, len, done);
}
}
}
@@ -141,6 +145,7 @@ struct Parser3 {
uint32_t minCodepoint;
NumDfa numDfa;
Utf8Dfa strDfa;
bool inKey = false;
};
inline PRESERVE_NONE WeaselJsonStatus skipWhitespace(char *&buf, char *bufEnd) {
@@ -204,21 +209,25 @@ inline PRESERVE_NONE WeaselJsonStatus scan_string_impl(Parser3 *self,
if (self->strDfa.accept()) {
for (;;) {
if (bufEnd - buf < V::lanes) [[unlikely]] {
buf = (char *)self->strDfa.scan(buf, bufEnd);
break;
}
auto v = V{(int8_t *)buf};
int normal =
(v != V::splat('"') & v != V::splat('\\') & v >= V::splat(0x20))
((v != V::splat('"')) & (v != V::splat('\\')) & (v >= V::splat(0x20)))
.count_leading_nonzero_lanes();
buf += normal;
if (normal < V::lanes) {
if (buf != bufEnd && (int8_t)*buf < 0x20) {
buf = (char *)self->strDfa.scan(buf, bufEnd);
}
break;
}
}
} else {
buf = (char *)self->strDfa.scan(buf, bufEnd);
}
buf = (char *)self->strDfa.scan(buf, bufEnd);
int len = buf - before;
if (!(self->flags & WeaselJsonRaw)) {
if (self->writeBuf != before) {
@@ -397,6 +406,8 @@ inline PRESERVE_NONE WeaselJsonStatus n_object2(Parser3 *self, char *buf,
}
MUSTTAIL return Parser3::keepGoing(self, buf, bufEnd);
case '"':
assert(!self->inKey);
self->inKey = true;
++buf;
self->dataBegin = self->writeBuf = buf;
self->pop();
@@ -432,14 +443,28 @@ inline PRESERVE_NONE WeaselJsonStatus n_object3(Parser3 *self, char *buf,
MUSTTAIL return Parser3::keepGoing(self, buf, bufEnd);
case ',':
++buf;
assert(!self->inKey);
self->inKey = true;
self->pop();
if (auto s = self->push({N_STRING, T_COLON, N_VALUE, N_OBJECT3})) {
if (auto s = skipWhitespace(buf, bufEnd)) {
if (auto s2 = self->push({N_STRING, T_COLON, N_VALUE, N_OBJECT3})) {
return s2;
}
return s;
}
if (*buf != '"') [[unlikely]] {
return WeaselJson_REJECT;
}
++buf;
self->dataBegin = self->writeBuf = buf;
self->strDfa.reset();
if (auto s = self->push({N_STRING2, T_COLON, N_VALUE, N_OBJECT3})) {
return s;
}
if (buf == bufEnd) {
return WeaselJson_AGAIN;
}
MUSTTAIL return n_string(self, buf, bufEnd);
MUSTTAIL return n_string2(self, buf, bufEnd);
default:
[[unlikely]] return WeaselJson_REJECT;
}
@@ -726,7 +751,11 @@ inline PRESERVE_NONE WeaselJsonStatus t_hex2(Parser3 *self, char *buf,
w[0] = (0b00011111 & self->utf8Codepoint) | 0b11000000;
w += 2;
if (useTmp) [[unlikely]] {
self->callbacks->on_string_data(self->userdata, tmp, 2, false);
if (self->inKey) {
self->callbacks->on_key_data(self->userdata, tmp, 2, false);
} else {
self->callbacks->on_string_data(self->userdata, tmp, 2, false);
}
}
}
} else {
@@ -760,7 +789,11 @@ inline PRESERVE_NONE WeaselJsonStatus t_hex2(Parser3 *self, char *buf,
w[0] = (0b00001111 & self->utf8Codepoint) | 0b11100000;
w += 3;
if (useTmp) [[unlikely]] {
self->callbacks->on_string_data(self->userdata, tmp, 3, false);
if (self->inKey) {
self->callbacks->on_key_data(self->userdata, tmp, 3, false);
} else {
self->callbacks->on_string_data(self->userdata, tmp, 3, false);
}
}
}
}
@@ -818,7 +851,11 @@ inline PRESERVE_NONE WeaselJsonStatus t_hex3(Parser3 *self, char *buf,
w[0] = (0b00000111 & self->utf8Codepoint) | 0b11110000;
w += 4;
if (useTmp) [[unlikely]] {
self->callbacks->on_string_data(self->userdata, tmp, 4, false);
if (self->inKey) {
self->callbacks->on_key_data(self->userdata, tmp, 4, false);
} else {
self->callbacks->on_string_data(self->userdata, tmp, 4, false);
}
}
}
@@ -904,17 +941,12 @@ inline PRESERVE_NONE WeaselJsonStatus n_null(Parser3 *self, char *buf,
}
}
template <char kChar, bool kSkipWhitespace = false>
template <char kChar>
inline PRESERVE_NONE WeaselJsonStatus singleChar(Parser3 *self, char *buf,
char *bufEnd) {
if (buf == bufEnd) [[unlikely]] {
return WeaselJson_REJECT;
}
if constexpr (kSkipWhitespace) {
if (auto s = skipWhitespace(buf, bufEnd)) {
return s;
}
}
if (*buf == kChar) {
++buf;
self->pop();
@@ -927,6 +959,28 @@ inline PRESERVE_NONE WeaselJsonStatus singleChar(Parser3 *self, char *buf,
}
}
inline PRESERVE_NONE WeaselJsonStatus t_colon(Parser3 *self, char *buf,
char *bufEnd) {
if (buf == bufEnd) [[unlikely]] {
return WeaselJson_REJECT;
}
if (auto s = skipWhitespace(buf, bufEnd)) {
return s;
}
if (*buf == ':') {
++buf;
assert(self->inKey);
self->inKey = false;
self->pop();
if (buf == bufEnd) {
return WeaselJson_AGAIN;
}
MUSTTAIL return Parser3::keepGoing(self, buf, bufEnd);
} else [[unlikely]] {
return WeaselJson_REJECT;
}
}
inline PRESERVE_NONE WeaselJsonStatus t_eof(Parser3 *, char *buf,
char *bufEnd) {
if (buf != bufEnd) [[unlikely]] {
@@ -963,7 +1017,7 @@ constexpr inline struct ContinuationTable {
continuations[T_A] = singleChar<'a'>;
continuations[T_L] = singleChar<'l'>;
continuations[T_S] = singleChar<'s'>;
continuations[T_COLON] = singleChar<':', true>;
continuations[T_COLON] = t_colon;
continuations[T_HEX] = t_hex;
continuations[T_HEX2] = t_hex2;
continuations[T_HEX3] = t_hex3;
+3 -3
View File
@@ -558,7 +558,7 @@ template <std::integral T, int kLanes> struct simd<T, kLanes, Simd_x86_SSE> {
for (; i + 16 / sizeof(T) <= kLanes; i += 16 / sizeof(T)) {
__m128i v0;
memcpy(&v0, &x[i], 16);
v0 = _mm_xor_si128(v0, _mm_set1_epi8(0xff));
v0 = _mm_xor_si128(v0, _mm_set1_epi8((char)0xff));
memcpy(&result.x[i], &v0, 16);
}
for (; i < kLanes; ++i) {
@@ -1702,13 +1702,13 @@ template <std::integral T, int kLanes> struct simd<T, kLanes, Simd_x86_AVX2> {
for (; i + 32 / sizeof(T) <= kLanes; i += 32 / sizeof(T)) {
__m256i v0;
memcpy(&v0, &x[i], 32);
v0 = _mm256_xor_si256(v0, _mm256_set1_epi8(0xff));
v0 = _mm256_xor_si256(v0, _mm256_set1_epi8((char)0xff));
memcpy(&result.x[i], &v0, 32);
}
for (; i + 16 / sizeof(T) <= kLanes; i += 16 / sizeof(T)) {
__m128i v0;
memcpy(&v0, &x[i], 16);
v0 = _mm_xor_si128(v0, _mm_set1_epi8(0xff));
v0 = _mm_xor_si128(v0, _mm_set1_epi8((char)0xff));
memcpy(&result.x[i], &v0, 16);
}
for (; i < kLanes; ++i) {
+9 -3
View File
@@ -215,6 +215,10 @@ void doTestUnescapingUtf8(std::string const &escaped,
auto &s = *(std::string *)p;
s.append(buf, len);
};
c.on_key_data = +[](void *p, const char *buf, int len, int /*done*/) {
auto &s = *(std::string *)p;
s.append(buf, len);
};
auto *parser = WeaselJsonParser_create(1024, &c, &result, flags);
auto copy = escaped;
for (size_t i = 0; i < copy.size(); i += stride) {
@@ -266,9 +270,10 @@ TEST_CASE("bench3") {
bench.batch(json.size());
bench.unit("byte");
auto *parser = WeaselJsonParser_create(1024, &c, nullptr, 0);
std::string copy;
for (size_t stride = 128; stride <= json.size(); stride *= 2) {
bench.run("parser3 (stride: " + std::to_string(stride) + ")", [&]() {
auto copy = json;
copy = json;
WeaselJsonParser_reset(parser);
for (size_t i = 0; i < copy.size(); i += stride) {
if (WeaselJsonParser_parse(parser, copy.data() + i,
@@ -379,10 +384,11 @@ TEST_CASE("bench input types") {
bench.doNotOptimizeAway(doc);
});
std::string copy;
{
auto *parser = WeaselJsonParser_create(1024, &c, nullptr, 0);
bench.run("parser3 " + name, [&]() {
auto copy = json;
copy = json;
WeaselJsonParser_reset(parser);
if (WeaselJsonParser_parse(parser, copy.data(), copy.size()) !=
WeaselJson_AGAIN) {
@@ -397,7 +403,7 @@ TEST_CASE("bench input types") {
{
auto *parser = WeaselJsonParser_create(1024, &c, nullptr, WeaselJsonRaw);
bench.run("parser3 (raw) " + name, [&]() {
auto copy = json;
copy = json;
WeaselJsonParser_reset(parser);
if (WeaselJsonParser_parse(parser, copy.data(), copy.size()) !=
WeaselJson_AGAIN) {
+7
View File
@@ -0,0 +1,7 @@
_GLOBAL_OFFSET_TABLE_
__cpu_indicator_init
__cpu_model
__stack_chk_fail@GLIBC_2.4
free@GLIBC_2.2.5
malloc@GLIBC_2.2.5
memmove@GLIBC_2.2.5

Some files were not shown because too many files have changed in this diff Show More