JSON parser cleanups

XMLWordPrintableJSON

    • Type: Improvement
    • Resolution: Works as Designed
    • Priority: Major - P3
    • 1.10.0
    • Affects Version/s: None
    • Component/s: json
    • None
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      The first frame of the JSON parser stack is never used; it's substituted with a separate bson_t in bson_json_reader_bson_t.bson. Much of the code would be simpler if we use bson_json_reader_bson_t.stack[0].bson as the root object instead. Additionally, there are many checks for "bson_json_reader_bson_t.n > 0" which I believe are always true as the parser descends into the JSON object.

              Assignee:
              A. Jesse Jiryu Davis
              Reporter:
              A. Jesse Jiryu Davis
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Created:
                Updated:
                Resolved: