MCPcopy Create free account
hub / github.com/GraphiteEditor/Graphite / strip_trailing_commas

Function strip_trailing_commas

node-graph/nodes/text/src/json.rs:52–94  ·  view source on GitHub ↗

Strips trailing commas before `]` and `}` to accept JSON-with-trailing-commas input. Respects string literals so commas inside strings are left untouched.

(json: &str)

Source from the content-addressed store, hash-verified

source not stored for this graph (policy: none)

Callers 3

format_jsonFunction · 0.85
query_jsonFunction · 0.85
query_json_allFunction · 0.85

Calls 3

lenMethod · 0.45
nextMethod · 0.45
pushMethod · 0.45

Tested by

no test coverage detected