Fix DEFAULT_PARSERCONTEXT, speed up parsing.#359
Fix DEFAULT_PARSERCONTEXT, speed up parsing.#359Zentrik wants to merge 4 commits intoJuliaIO:masterfrom
Conversation
Unfortunately this was never updated in JuliaIO#280 to be the correct default, and so has been wrong ever since introduction.
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #359 +/- ##
=======================================
Coverage 99.35% 99.35%
=======================================
Files 7 7
Lines 466 466
=======================================
Hits 463 463
Misses 3 3 ☔ View full report in Codecov by Sentry. |
|
|
||
| # Workaround for slow dynamic dispatch for creating objects | ||
| const DEFAULT_PARSERCONTEXT = ParserContext{Dict{String, Any}, Int64, false, nothing}() | ||
| const DEFAULT_PARSERCONTEXT = ParserContext{Dict{String, Any}, Int64, true, nothing}() |
There was a problem hiding this comment.
If we change the default to be a non-strict spec, we will certainty want to update the docs and make a version bump. The Python docs may serve as a guide for communicating this: #280 (comment)
There was a problem hiding this comment.
Unless I'm missing something, this is a default in the sense that there is a fast path for it. This change doesn't change the result but is merely a performance improvement. If you look further down you'll see that these are the default parameters for parse.
|
Bump |
|
Obsolete post-#374 |
Unfortunately this was never updated in #280 to be the correct default, and so has been wrong ever since that pr.
#263 suggest significant improvements, I don't see as big an improvement but still substantial.