Skip to content

Adopt reflect-cpp (<rfl/nlohmann.hpp>, json::Raw, ErrorKind) in StandardCompiler - #1

Open
clockblocker wants to merge 1 commit into
developfrom
adopt-rfl-nlohmann-json
Open

clockblocker wants to merge 1 commit into
developfrom
adopt-rfl-nlohmann-json

Conversation

@clockblocker

Copy link
Copy Markdown
Owner

Showcase PR migrating StandardCompiler JSON input parsing (libsolidity/interface/StandardCompiler.cpp) from hand-written nlohmann::json checks to reflect-cpp.

reflect-cpp lanes exercised

  • JSON / RPC Interop (Wave 3): Opt-in <rfl/nlohmann.hpp> adapter (#69) + rfl::json::Raw (#67) for raw AST subtree passthrough
  • Structured Diagnostics (Wave 7): rfl::ErrorKind (#70) for structured JSONError dispatch

Measured gains

  • 64/64 StandardCompiler Boost unit tests + 238/238 standard_* cmdline golden tests pass (214 non-SMT + 24 modelChecker JSONError)
  • Fixes 3 uncaught nlohmann::json::type_error crashes in input validation for free
  • −21% validation LoC (ex-legacy table; −44 net LoC across 2 files) with incremental coexistence alongside existing nlohmann::json code
  • Base commit imports clockblocker/reflect-cpp@showcase/all-lanes via FetchContent

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant