Skip to content

Implement a sourcemeta::core::is_pointer convenience function#2295

Merged
jviotti merged 1 commit intomainfrom
jsonpointer-check
Mar 17, 2026
Merged

Implement a sourcemeta::core::is_pointer convenience function#2295
jviotti merged 1 commit intomainfrom
jsonpointer-check

Conversation

@jviotti
Copy link
Member

@jviotti jviotti commented Mar 17, 2026

Signed-off-by: Juan Cruz Viotti jv@jviotti.com

Signed-off-by: Juan Cruz Viotti <jv@jviotti.com>
@augmentcode
Copy link

augmentcode bot commented Mar 17, 2026

🤖 Augment PR Summary

Summary: Adds a lightweight API to validate JSON Pointer strings (RFC 6901) without constructing a full Pointer.

Changes:

  • Expose sourcemeta::core::is_pointer(std::string_view) in jsonpointer.h.
  • Implement is_pointer in jsonpointer.cc by running the existing parser in a “check-only” mode.
  • Refactor the internal parser into parse_pointer<CheckOnly> so it can optionally skip building tokens/containers.
  • Update to_pointer(const JSON&) to use parse_pointer<false>.
  • Expand JSON Pointer unit tests to assert is_pointer behavior across valid/invalid inputs, including control characters and JSON-escape-related cases.

Technical Notes: is_pointer is noexcept and returns false on any parsing exception; the check-only parser path aims to reuse existing grammar validation while avoiding pointer construction.

🤖 Was this summary useful? React with 👍 or 👎

Copy link

@augmentcode augmentcode bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Review completed. 1 suggestion posted.

Fix All in Augment

Comment augment review to trigger a new review at any time.

Copy link

@cubic-dev-ai cubic-dev-ai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

1 issue found across 5 files

Prompt for AI agents (unresolved issues)

Check if these issues are valid — if so, understand the root cause of each and fix them. If appropriate, use sub-agents to investigate and fix each issue separately.


<file name="src/core/jsonpointer/parser.h">

<violation number="1" location="src/core/jsonpointer/parser.h:89">
P2: `is_pointer()` no longer rejects numeric tokens that `to_pointer()` cannot parse. Skipping `parse_index()` in check-only mode drops the overflow validation, so oversized indices can pass `is_pointer()` and still throw in `to_pointer()`.</violation>
</file>

Reply with feedback, questions, or to request a fix. Tag @cubic-dev-ai to re-run a review.

Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Benchmark (linux/llvm)

Details
Benchmark suite Current: 04ec2bb Previous: 881ade3 Ratio
Regex_Lower_S_Or_Upper_S_Asterisk 3.1114252758465173 ns/iter 3.119952196075416 ns/iter 1.00
Regex_Caret_Lower_S_Or_Upper_S_Asterisk_Dollar 3.1099302632502845 ns/iter 3.1093155620341153 ns/iter 1.00
Regex_Period_Asterisk 3.1117847959488643 ns/iter 3.109820831398893 ns/iter 1.00
Regex_Group_Period_Asterisk_Group 3.109828846629421 ns/iter 3.109108434837617 ns/iter 1.00
Regex_Period_Plus 3.111116652387835 ns/iter 2.9995853954120455 ns/iter 1.04
Regex_Period 3.1213888734371973 ns/iter 2.8431749367191945 ns/iter 1.10
Regex_Caret_Period_Plus_Dollar 3.1165313160730785 ns/iter 3.1045795800665785 ns/iter 1.00
Regex_Caret_Group_Period_Plus_Group_Dollar 3.1132526479581126 ns/iter 3.001617298760991 ns/iter 1.04
Regex_Caret_Period_Asterisk_Dollar 3.111608422877107 ns/iter 3.4200230639257367 ns/iter 0.91
Regex_Caret_Group_Period_Asterisk_Group_Dollar 3.111338945912317 ns/iter 3.108959015312979 ns/iter 1.00
Regex_Caret_X_Hyphen 6.225742882056492 ns/iter 10.62592358846294 ns/iter 0.59
Regex_Period_Md_Dollar 27.317143696956876 ns/iter 27.250828570105217 ns/iter 1.00
Regex_Caret_Slash_Period_Asterisk 5.913814301055486 ns/iter 6.221110770342106 ns/iter 0.95
Regex_Caret_Period_Range_Dollar 3.1123165400912125 ns/iter 3.731952618011078 ns/iter 0.83
Regex_Nested_Backtrack 49.02227290358194 ns/iter 52.63337801598422 ns/iter 0.93
JSON_Array_Of_Objects_Unique 436.5012233502174 ns/iter 427.6764082143371 ns/iter 1.02
JSON_Parse_1 6170.619848984961 ns/iter 6074.702839652629 ns/iter 1.02
JSON_Parse_Real 10935.878153023743 ns/iter 10923.80928059885 ns/iter 1.00
JSON_Parse_Decimal 11319.624548209538 ns/iter 11722.042686179202 ns/iter 0.97
JSON_Parse_Schema_ISO_Language 3596168.0153849768 ns/iter 3608841.1340206782 ns/iter 1.00
JSON_Fast_Hash_Helm_Chart_Lock 62.869045430997566 ns/iter 61.88247628423947 ns/iter 1.02
JSON_Equality_Helm_Chart_Lock 158.64862925684483 ns/iter 158.42414902333954 ns/iter 1.00
JSON_Divisible_By_Decimal 589.1895837588306 ns/iter 590.1346047484298 ns/iter 1.00
JSON_String_Equal/10 7.156861855867596 ns/iter 6.2288066221102225 ns/iter 1.15
JSON_String_Equal/100 6.873410381552235 ns/iter 6.852411979036435 ns/iter 1.00
JSON_String_Equal_Small_By_Perfect_Hash/10 0.9346668420315069 ns/iter 0.9342522539602879 ns/iter 1.00
JSON_String_Equal_Small_By_Runtime_Perfect_Hash/10 10.26683611806254 ns/iter 10.26786143718597 ns/iter 1.00
JSON_String_Fast_Hash/10 2.4921710998407427 ns/iter 2.4891891579747183 ns/iter 1.00
JSON_String_Fast_Hash/100 2.5053133807605232 ns/iter 2.489257317501589 ns/iter 1.01
JSON_String_Key_Hash/10 2.1792084748299736 ns/iter 2.1816554070888103 ns/iter 1.00
JSON_String_Key_Hash/100 6.534027306324502 ns/iter 6.544997321189076 ns/iter 1.00
JSON_Object_Defines_Miss_Same_Length 3.7523455327311814 ns/iter 3.7424722804313744 ns/iter 1.00
JSON_Object_Defines_Miss_Too_Small 3.7389843313405686 ns/iter 3.7388438446403245 ns/iter 1.00
JSON_Object_Defines_Miss_Too_Large 3.7382725835110824 ns/iter 3.736227385584405 ns/iter 1.00
Pointer_Object_Traverse 27.127281505907415 ns/iter 27.36775795715703 ns/iter 0.99
Pointer_Object_Try_Traverse 28.214467091104698 ns/iter 28.202599185307385 ns/iter 1.00
Pointer_Push_Back_Pointer_To_Weak_Pointer 160.37754889087276 ns/iter 160.8359146020735 ns/iter 1.00
Pointer_Walker_Schema_ISO_Language 3034251.974138011 ns/iter 3137127.840000176 ns/iter 0.97
Schema_Frame_WoT_References 4777365.620690223 ns/iter 4840392.479451728 ns/iter 0.99
Schema_Frame_OMC_References 20699370.735294852 ns/iter 20561012.484849375 ns/iter 1.01
Schema_Frame_OMC_Locations 18923944.59459435 ns/iter 19004733.864863813 ns/iter 1.00
Schema_Frame_ISO_Language_Locations 102021651.16667552 ns/iter 105584851.83332777 ns/iter 0.97
Schema_Frame_KrakenD_References 40025826.94444199 ns/iter 40837570.70588276 ns/iter 0.98
Schema_Frame_KrakenD_Reachable 605107493.9999808 ns/iter 631551192.9999502 ns/iter 0.96
Schema_Iterator_ISO_Language 2260414.3709680745 ns/iter 2296378.8684211443 ns/iter 0.98
Schema_Frame_ISO_Language_Locations_To_JSON 131802827.00000134 ns/iter 139937018.75000396 ns/iter 0.94
Schema_Tracker_ISO_Language 28417022.375000063 ns/iter 29490379.04347832 ns/iter 0.96
Schema_Tracker_ISO_Language_To_JSON 24374433.571430083 ns/iter 26833909.111111872 ns/iter 0.91
Schema_Format_ISO_Language_To_JSON 109908436.16669583 ns/iter 112069356.50000106 ns/iter 0.98
Schema_Bundle_Meta_2020_12 1564115.4235334613 ns/iter 1556648.5346786552 ns/iter 1.00
Schema_Frame_Many_Resources_References 372504324.5000279 ns/iter 369969491.0000062 ns/iter 1.01
Alterschema_Check_Readibility_ISO_Language_Set_3 222121613.6666726 ns/iter 220684456.33332583 ns/iter 1.01
Alterschema_Check_Readibility_OMC 32971351.5909072 ns/iter 34078887.050003454 ns/iter 0.97
Alterschema_Apply_Readibility_KrakenD 620802028.9999467 ns/iter 662521463.9998376 ns/iter 0.94
EditorSchema_ForEditor_EmbeddedResources 13460623.36539306 ns/iter 13514862.134610001 ns/iter 1.00
URITemplateRouter_Create 16828.495569530856 ns/iter 17393.613263532985 ns/iter 0.97
URITemplateRouter_Match 172.7501510177255 ns/iter 177.87834927000796 ns/iter 0.97
URITemplateRouterView_Restore 6722.74912758077 ns/iter 6853.973604546327 ns/iter 0.98
URITemplateRouterView_Match 151.67150877008493 ns/iter 153.76491402888374 ns/iter 0.99

This comment was automatically generated by workflow using github-action-benchmark.

Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Benchmark (windows/msvc)

Details
Benchmark suite Current: 04ec2bb Previous: 881ade3 Ratio
Regex_Lower_S_Or_Upper_S_Asterisk 4.12137781986013 ns/iter 4.122668569587853 ns/iter 1.00
Regex_Caret_Lower_S_Or_Upper_S_Asterisk_Dollar 4.104021694596666 ns/iter 4.114368846632615 ns/iter 1.00
Regex_Period_Asterisk 4.794257153557964 ns/iter 4.7580462159783465 ns/iter 1.01
Regex_Group_Period_Asterisk_Group 4.427711875000284 ns/iter 4.418755000000374 ns/iter 1.00
Regex_Period_Plus 4.424758125000494 ns/iter 4.412060636488545 ns/iter 1.00
Regex_Period 4.411661886488176 ns/iter 4.422087500000771 ns/iter 1.00
Regex_Caret_Period_Plus_Dollar 4.096912284101113 ns/iter 4.092359933035741 ns/iter 1.00
Regex_Caret_Group_Period_Plus_Group_Dollar 3.780965401785709 ns/iter 3.7959615788895307 ns/iter 1.00
Regex_Caret_Period_Asterisk_Dollar 4.423490624999715 ns/iter 4.420059375000562 ns/iter 1.00
Regex_Caret_Group_Period_Asterisk_Group_Dollar 4.102028033883096 ns/iter 4.105957498168098 ns/iter 1.00
Regex_Caret_X_Hyphen 7.5753582589272686 ns/iter 7.57924665178576 ns/iter 1.00
Regex_Period_Md_Dollar 35.74131358466745 ns/iter 35.62568034178873 ns/iter 1.00
Regex_Caret_Slash_Period_Asterisk 7.2546910714277955 ns/iter 7.356428571428962 ns/iter 0.99
Regex_Caret_Period_Range_Dollar 4.099450377635342 ns/iter 4.103266614470912 ns/iter 1.00
Regex_Nested_Backtrack 109.33365625000135 ns/iter 109.29360937499412 ns/iter 1.00
JSON_Array_Of_Objects_Unique 457.59754483990315 ns/iter 462.5889871850819 ns/iter 0.99
JSON_Parse_1 9357.24215516922 ns/iter 8988.029017858526 ns/iter 1.04
JSON_Parse_Real 16619.584059711236 ns/iter 16572.22972475093 ns/iter 1.00
JSON_Parse_Decimal 15641.494234402793 ns/iter 15337.696428571033 ns/iter 1.02
JSON_Parse_Schema_ISO_Language 5844232.999997985 ns/iter 5912297.32143006 ns/iter 0.99
JSON_Fast_Hash_Helm_Chart_Lock 55.81086999998206 ns/iter 58.58976785713058 ns/iter 0.95
JSON_Equality_Helm_Chart_Lock 258.00312982153235 ns/iter 257.73010714285 ns/iter 1.00
JSON_Divisible_By_Decimal 1178.8653571427078 ns/iter 1142.6564285715453 ns/iter 1.03
JSON_String_Equal/10 12.332646428571284 ns/iter 12.25231964285659 ns/iter 1.01
JSON_String_Equal/100 12.996037500000416 ns/iter 12.918880357143994 ns/iter 1.01
JSON_String_Equal_Small_By_Perfect_Hash/10 1.8875027695426079 ns/iter 1.885461162397175 ns/iter 1.00
JSON_String_Equal_Small_By_Runtime_Perfect_Hash/10 12.859710714289056 ns/iter 12.964572263549465 ns/iter 0.99
JSON_String_Fast_Hash/10 3.1699276785711765 ns/iter 3.143602973661683 ns/iter 1.01
JSON_String_Fast_Hash/100 3.2702267857140606 ns/iter 3.147955357142962 ns/iter 1.04
JSON_String_Key_Hash/10 4.112104873414262 ns/iter 4.104634516258189 ns/iter 1.00
JSON_String_Key_Hash/100 14.444377232142156 ns/iter 14.415010649935526 ns/iter 1.00
JSON_Object_Defines_Miss_Same_Length 3.7836214218143667 ns/iter 3.775426064685763 ns/iter 1.00
JSON_Object_Defines_Miss_Too_Small 3.7955485491078127 ns/iter 3.791909882467947 ns/iter 1.00
JSON_Object_Defines_Miss_Too_Large 5.035738999999921 ns/iter 5.04810500000076 ns/iter 1.00
Pointer_Object_Traverse 42.36777217400814 ns/iter 41.17909073007824 ns/iter 1.03
Pointer_Object_Try_Traverse 55.780544642861486 ns/iter 55.70039000001544 ns/iter 1.00
Pointer_Push_Back_Pointer_To_Weak_Pointer 158.0444866071673 ns/iter 158.73200892860342 ns/iter 1.00
Pointer_Walker_Schema_ISO_Language 10975362.500001242 ns/iter 11311670.312498024 ns/iter 0.97
Schema_Frame_WoT_References 9940543.333333254 ns/iter 10271932.000002077 ns/iter 0.97
Schema_Frame_OMC_References 40915323.52941506 ns/iter 40962752.941181056 ns/iter 1.00
Schema_Frame_OMC_Locations 37773131.57894768 ns/iter 38368110.526310995 ns/iter 0.98
Schema_Frame_ISO_Language_Locations 179773075.00001416 ns/iter 192670566.66664454 ns/iter 0.93
Schema_Frame_KrakenD_References 86403133.33333123 ns/iter 90009028.57142785 ns/iter 0.96
Schema_Frame_KrakenD_Reachable 487878100.0001027 ns/iter 503726000.00014246 ns/iter 0.97
Schema_Iterator_ISO_Language 4119020.930232203 ns/iter 4200155.000000904 ns/iter 0.98
Schema_Frame_ISO_Language_Locations_To_JSON 255352499.99995813 ns/iter 253883566.6666728 ns/iter 1.01
Schema_Tracker_ISO_Language 43371305.8823474 ns/iter 46055759.99999019 ns/iter 0.94
Schema_Tracker_ISO_Language_To_JSON 49993399.999997176 ns/iter 50827309.99999967 ns/iter 0.98
Schema_Format_ISO_Language_To_JSON 183302550.0000076 ns/iter 185795999.9998684 ns/iter 0.99
Schema_Bundle_Meta_2020_12 2691074.6987997997 ns/iter 2681431.439393209 ns/iter 1.00
Schema_Frame_Many_Resources_References 1439939699.999968 ns/iter 1478963900.0000534 ns/iter 0.97
Alterschema_Check_Readibility_ISO_Language_Set_3 313205550.0000206 ns/iter 313931300.00003564 ns/iter 1.00
Alterschema_Check_Readibility_OMC 56605581.818179086 ns/iter 58626954.54545081 ns/iter 0.97
Alterschema_Apply_Readibility_KrakenD 926590600.0000541 ns/iter 963253799.9998477 ns/iter 0.96
EditorSchema_ForEditor_EmbeddedResources 26606819.230778456 ns/iter 27300955.999999132 ns/iter 0.97
URITemplateRouter_Create 21996.806250001555 ns/iter 21859.12812500135 ns/iter 1.01
URITemplateRouter_Match 208.39974069643725 ns/iter 215.96034375001236 ns/iter 0.96
URITemplateRouterView_Restore 30549.598214284808 ns/iter 34975.089285720984 ns/iter 0.87
URITemplateRouterView_Match 153.02807798981527 ns/iter 155.02656250002846 ns/iter 0.99

This comment was automatically generated by workflow using github-action-benchmark.

Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Benchmark (linux/gcc)

Details
Benchmark suite Current: 04ec2bb Previous: 881ade3 Ratio
URITemplateRouter_Create 11242.20771713596 ns/iter 13888.779574059687 ns/iter 0.81
URITemplateRouter_Match 149.41435256204963 ns/iter 153.41429803151607 ns/iter 0.97
URITemplateRouterView_Restore 2519.795597685973 ns/iter 7929.741486611096 ns/iter 0.32
URITemplateRouterView_Match 130.51611945022515 ns/iter 146.09982441242192 ns/iter 0.89
EditorSchema_ForEditor_EmbeddedResources 12694651.249997184 ns/iter 13648560.490180757 ns/iter 0.93
Alterschema_Check_Readibility_ISO_Language_Set_3 200473692.3333894 ns/iter 209612309.66660574 ns/iter 0.96
Alterschema_Check_Readibility_OMC 35964508.52631661 ns/iter 33422631.000002224 ns/iter 1.08
Alterschema_Apply_Readibility_KrakenD 623451630.0000905 ns/iter 596505143.0000585 ns/iter 1.05
Schema_Frame_WoT_References 4688638.577181642 ns/iter 5124199.014704466 ns/iter 0.91
Schema_Frame_OMC_References 22955504.87500009 ns/iter 20953323.63636303 ns/iter 1.10
Schema_Frame_OMC_Locations 20662690.470591288 ns/iter 19392825.749997023 ns/iter 1.07
Schema_Frame_ISO_Language_Locations 107594224.99999498 ns/iter 100724093.28569977 ns/iter 1.07
Schema_Frame_KrakenD_References 42792390.37499849 ns/iter 38664693.83333676 ns/iter 1.11
Schema_Frame_KrakenD_Reachable 852380170.9998225 ns/iter 602447575.000042 ns/iter 1.41
Schema_Iterator_ISO_Language 2424028.6070173103 ns/iter 2509592.437275788 ns/iter 0.97
Schema_Frame_ISO_Language_Locations_To_JSON 263022146.99997723 ns/iter 247214462.000026 ns/iter 1.06
Schema_Tracker_ISO_Language 35878528.31579814 ns/iter 29787425.7083303 ns/iter 1.20
Schema_Tracker_ISO_Language_To_JSON 38145199.611108184 ns/iter 27809562.35999838 ns/iter 1.37
Schema_Format_ISO_Language_To_JSON 119568156.16667883 ns/iter 106111773.99997966 ns/iter 1.13
Schema_Bundle_Meta_2020_12 1624292.3125033753 ns/iter 1725177.1732580129 ns/iter 0.94
Schema_Frame_Many_Resources_References 399578991.9999879 ns/iter 375458633.49998856 ns/iter 1.06
Pointer_Object_Traverse 26.413651215384668 ns/iter 27.897439220359207 ns/iter 0.95
Pointer_Object_Try_Traverse 28.29557208974188 ns/iter 30.910638520226662 ns/iter 0.92
Pointer_Push_Back_Pointer_To_Weak_Pointer 156.73783099186488 ns/iter 139.21394421177402 ns/iter 1.13
Pointer_Walker_Schema_ISO_Language 3362737.358851623 ns/iter 3413534.236453299 ns/iter 0.99
JSON_Array_Of_Objects_Unique 322.09291701107173 ns/iter 416.6142730572967 ns/iter 0.77
JSON_Parse_1 7160.21979494868 ns/iter 8158.66391341786 ns/iter 0.88
JSON_Parse_Real 10856.036423892927 ns/iter 12003.130872942409 ns/iter 0.90
JSON_Parse_Decimal 14553.326495764559 ns/iter 18243.431022363035 ns/iter 0.80
JSON_Parse_Schema_ISO_Language 4312734.460123142 ns/iter 4619023.717105775 ns/iter 0.93
JSON_Fast_Hash_Helm_Chart_Lock 50.1991905582812 ns/iter 66.43345001154398 ns/iter 0.76
JSON_Equality_Helm_Chart_Lock 143.29727508109997 ns/iter 165.43747224077995 ns/iter 0.87
JSON_Divisible_By_Decimal 544.3982043174117 ns/iter 596.356542016697 ns/iter 0.91
JSON_String_Equal/10 5.87834282489342 ns/iter 6.621148743458574 ns/iter 0.89
JSON_String_Equal/100 7.028196811758065 ns/iter 7.2427786990067275 ns/iter 0.97
JSON_String_Equal_Small_By_Perfect_Hash/10 0.8257147347973564 ns/iter 0.7528715559220927 ns/iter 1.10
JSON_String_Equal_Small_By_Runtime_Perfect_Hash/10 21.90124858108684 ns/iter 32.962551356737585 ns/iter 0.66
JSON_String_Fast_Hash/10 1.4430591778721555 ns/iter 1.2445557253244126 ns/iter 1.16
JSON_String_Fast_Hash/100 1.4424394493435977 ns/iter 1.2447795273365256 ns/iter 1.16
JSON_String_Key_Hash/10 1.1554350438292356 ns/iter 1.2471496176396264 ns/iter 0.93
JSON_String_Key_Hash/100 11.842456919627336 ns/iter 12.442728737177866 ns/iter 0.95
JSON_Object_Defines_Miss_Same_Length 3.3846288318958155 ns/iter 3.114260431082416 ns/iter 1.09
JSON_Object_Defines_Miss_Too_Small 3.588403093156024 ns/iter 3.4278076212478537 ns/iter 1.05
JSON_Object_Defines_Miss_Too_Large 3.4999367887751083 ns/iter 3.425656431404225 ns/iter 1.02
Regex_Lower_S_Or_Upper_S_Asterisk 1.4428008087884285 ns/iter 1.2460545184545442 ns/iter 1.16
Regex_Caret_Lower_S_Or_Upper_S_Asterisk_Dollar 1.441382657562651 ns/iter 1.2453346437152966 ns/iter 1.16
Regex_Period_Asterisk 1.4423417906980338 ns/iter 1.245252438156326 ns/iter 1.16
Regex_Group_Period_Asterisk_Group 1.441333107285878 ns/iter 1.2491682377086013 ns/iter 1.15
Regex_Period_Plus 1.4433411433793326 ns/iter 1.2445141253704406 ns/iter 1.16
Regex_Period 1.4429989919350865 ns/iter 1.2445924502563575 ns/iter 1.16
Regex_Caret_Period_Plus_Dollar 1.4446883366704917 ns/iter 1.2452924570196446 ns/iter 1.16
Regex_Caret_Group_Period_Plus_Group_Dollar 1.7316158102785182 ns/iter 1.5572042903009629 ns/iter 1.11
Regex_Caret_Period_Asterisk_Dollar 1.731780318953888 ns/iter 1.557679683217645 ns/iter 1.11
Regex_Caret_Group_Period_Asterisk_Group_Dollar 1.4428645866918346 ns/iter 1.5566164348653229 ns/iter 0.93
Regex_Caret_X_Hyphen 8.068578231431067 ns/iter 12.77424972664232 ns/iter 0.63
Regex_Period_Md_Dollar 23.708030571419247 ns/iter 29.741101723541476 ns/iter 0.80
Regex_Caret_Slash_Period_Asterisk 7.786032292870791 ns/iter 4.978813159157766 ns/iter 1.56
Regex_Caret_Period_Range_Dollar 1.7323992477107162 ns/iter 1.557070781862708 ns/iter 1.11
Regex_Nested_Backtrack 39.68568713295594 ns/iter 53.46624208533966 ns/iter 0.74

This comment was automatically generated by workflow using github-action-benchmark.

@jviotti jviotti merged commit 8c04297 into main Mar 17, 2026
13 checks passed
@jviotti jviotti deleted the jsonpointer-check branch March 17, 2026 17:48
Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Benchmark (macos/llvm)

Details
Benchmark suite Current: 04ec2bb Previous: 881ade3 Ratio
Regex_Lower_S_Or_Upper_S_Asterisk 1.7038800223644113 ns/iter 2.1875405277657642 ns/iter 0.78
Regex_Caret_Lower_S_Or_Upper_S_Asterisk_Dollar 1.7167386473634327 ns/iter 2.366182983222109 ns/iter 0.73
Regex_Period_Asterisk 1.719421255242867 ns/iter 2.2157724316913496 ns/iter 0.78
Regex_Group_Period_Asterisk_Group 1.7393318161446878 ns/iter 2.477710613909813 ns/iter 0.70
Regex_Period_Plus 2.0521816716555072 ns/iter 2.6516617058792584 ns/iter 0.77
Regex_Period 2.0532113016098963 ns/iter 2.6236737679639326 ns/iter 0.78
Regex_Caret_Period_Plus_Dollar 2.0567783356577176 ns/iter 2.755783601603368 ns/iter 0.75
Regex_Caret_Group_Period_Plus_Group_Dollar 2.152661853747229 ns/iter 3.0678073985810497 ns/iter 0.70
Regex_Caret_Period_Asterisk_Dollar 1.8665474945705438 ns/iter 2.903128346086997 ns/iter 0.64
Regex_Caret_Group_Period_Asterisk_Group_Dollar 1.9772623442882282 ns/iter 2.499995651581476 ns/iter 0.79
Regex_Caret_X_Hyphen 6.779887148094781 ns/iter 9.34428301196086 ns/iter 0.73
Regex_Period_Md_Dollar 22.18361017331724 ns/iter 32.21744104314877 ns/iter 0.69
Regex_Caret_Slash_Period_Asterisk 4.935136923103061 ns/iter 6.911248936095685 ns/iter 0.71
Regex_Caret_Period_Range_Dollar 1.8454248577181485 ns/iter 2.6422117185398326 ns/iter 0.70
Regex_Nested_Backtrack 25.57712220261896 ns/iter 42.952971956172 ns/iter 0.60
JSON_Array_Of_Objects_Unique 364.39764363952446 ns/iter 456.97161890200607 ns/iter 0.80
JSON_Parse_1 4429.356226533384 ns/iter 6171.208835112108 ns/iter 0.72
JSON_Parse_Real 6517.379280281732 ns/iter 9298.374402738309 ns/iter 0.70
JSON_Parse_Decimal 8192.458736651803 ns/iter 12027.426827602763 ns/iter 0.68
JSON_Parse_Schema_ISO_Language 4774172.485294143 ns/iter 6039688.596491974 ns/iter 0.79
JSON_Fast_Hash_Helm_Chart_Lock 59.18701100965785 ns/iter 70.98953716734184 ns/iter 0.83
JSON_Equality_Helm_Chart_Lock 163.92633209106404 ns/iter 186.2819570278421 ns/iter 0.88
JSON_Divisible_By_Decimal 484.10285138990804 ns/iter 613.5384701630343 ns/iter 0.79
JSON_String_Equal/10 7.494871395422631 ns/iter 8.922000961270587 ns/iter 0.84
JSON_String_Equal/100 6.6221398100559785 ns/iter 9.787190879642012 ns/iter 0.68
JSON_String_Equal_Small_By_Perfect_Hash/10 0.7728490146620588 ns/iter 1.0573252747964226 ns/iter 0.73
JSON_String_Equal_Small_By_Runtime_Perfect_Hash/10 3.34838846140907 ns/iter 5.00349581243043 ns/iter 0.67
JSON_String_Fast_Hash/10 2.419394281074117 ns/iter 2.988366509491433 ns/iter 0.81
JSON_String_Fast_Hash/100 2.0616992293663268 ns/iter 3.1887110787975175 ns/iter 0.65
JSON_String_Key_Hash/10 1.345115635808478 ns/iter 1.89742974033449 ns/iter 0.71
JSON_String_Key_Hash/100 2.3169285032075893 ns/iter 3.589142339165069 ns/iter 0.65
JSON_Object_Defines_Miss_Same_Length 2.4032731214645078 ns/iter 3.3461326471018187 ns/iter 0.72
JSON_Object_Defines_Miss_Too_Small 2.399089917977719 ns/iter 3.4630295153186417 ns/iter 0.69
JSON_Object_Defines_Miss_Too_Large 2.6148594264356113 ns/iter 3.758505766725784 ns/iter 0.70
Pointer_Object_Traverse 16.854400743459127 ns/iter 20.805705417856434 ns/iter 0.81
Pointer_Object_Try_Traverse 19.8494854464092 ns/iter 27.611312053358812 ns/iter 0.72
Pointer_Push_Back_Pointer_To_Weak_Pointer 159.84610000852848 ns/iter 210.48001564019086 ns/iter 0.76
Pointer_Walker_Schema_ISO_Language 5284639.532894474 ns/iter 6074036.813954588 ns/iter 0.87
Schema_Frame_WoT_References 4585998.397436114 ns/iter 6462863.0952379275 ns/iter 0.71
Schema_Frame_OMC_References 27464770.037037548 ns/iter 35879192.16666553 ns/iter 0.77
Schema_Frame_OMC_Locations 25640019.466663945 ns/iter 34530075.72727529 ns/iter 0.74
Schema_Frame_ISO_Language_Locations 78328239.62500867 ns/iter 127588366.60000269 ns/iter 0.61
Schema_Frame_KrakenD_References 46133946.42857266 ns/iter 74860694.44444688 ns/iter 0.62
Schema_Frame_KrakenD_Reachable 404878062.00002295 ns/iter 649517582.9998062 ns/iter 0.62
Schema_Iterator_ISO_Language 2533461.8768327697 ns/iter 2866294.7850462445 ns/iter 0.88
Schema_Frame_ISO_Language_Locations_To_JSON 99786380.85713752 ns/iter 130199531.25001393 ns/iter 0.77
Schema_Tracker_ISO_Language 35908537.90908775 ns/iter 39584703.1250014 ns/iter 0.91
Schema_Tracker_ISO_Language_To_JSON 15427535.022726344 ns/iter 20111491.379307624 ns/iter 0.77
Schema_Format_ISO_Language_To_JSON 85976286.50002776 ns/iter 134394076.49999186 ns/iter 0.64
Schema_Bundle_Meta_2020_12 1266403.0536321208 ns/iter 2232269.3602722753 ns/iter 0.57
Schema_Frame_Many_Resources_References 321201604.0000094 ns/iter 583993291.9998318 ns/iter 0.55
Alterschema_Check_Readibility_ISO_Language_Set_3 149099958.40000647 ns/iter 206486180.33336183 ns/iter 0.72
Alterschema_Check_Readibility_OMC 45004496.22727584 ns/iter 49783544.6428618 ns/iter 0.90
Alterschema_Apply_Readibility_KrakenD 619511333.999867 ns/iter 766551667.99992 ns/iter 0.81
EditorSchema_ForEditor_EmbeddedResources 16798570.57143051 ns/iter 16669625.023237236 ns/iter 1.01
URITemplateRouter_Create 26010.344497795577 ns/iter 21615.305347218768 ns/iter 1.20
URITemplateRouter_Match 235.06025470151772 ns/iter 230.05758317291037 ns/iter 1.02
URITemplateRouterView_Restore 22678.438469596345 ns/iter 17874.80866457214 ns/iter 1.27
URITemplateRouterView_Match 173.07942475717726 ns/iter 156.89047693510855 ns/iter 1.10

This comment was automatically generated by workflow using github-action-benchmark.

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