| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
Sorry, something went wrong.
…maps perf: rebuild Multimap canonicalization without intermediate vectors/maps
📝 Walkthrough
WalkthroughThe PR refactors Multimap canonicalization methods in src/utils.cc to eliminate intermediate container allocations. A new helper function collapses consecutive whitespace. GetCanonicalHeaders() and GetCanonicalQueryString() are rewritten to build results directly during map iteration. ToQueryString() is reintroduced as a delegation wrapper. ChangesMultimap Canonicalization Optimization
Sequence Diagram(s)No sequence diagrams needed; the changes are internal optimizations to individual methods without new cross-component interactions or control flow alterations. Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes Suggested reviewers
Poem🚥 Pre-merge checks | ✅ 5 ✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches 🧪 Generate unit tests (beta)
Warning There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure. 🔧 Infer (1.2.0) src/utils.ccsrc/utils.cc:18:10: fatal error: 'miniocpp/utils.h' file not found ... [truncated 2200 characters] ... m ClangFrontend__CTrans.CTrans_funct.instruction in file "src/clang/cTrans.ml" (inlined), line 4765, characters 38-71 Comment @coderabbitai help to get the list of available commands and usage tips. |
Sorry, something went wrong.
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agentsVerify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. Inline comments: In `@src/utils.cc`: - Around line 583-599: The loop currently iterates map_ and lowercases each key later, causing mixed-case duplicates and non-deterministic ordering; instead iterate keys_ (which should contain the canonical/lowercased header names) and for each key k append it to signed_headers/canonical_headers without calling ToLower on map keys, then gather and join all values from map_ entries whose original key lowercased equals k (so case-variants are merged) using removeExtraSpaces before joining with commas; update the logic that builds signed_headers and canonical_headers (symbols: keys_, map_, ToLower, signed_headers, canonical_headers, removeExtraSpaces) so the header order and value aggregation are stable and case-insensitive.
Fix all unresolved CodeRabbit comments on this PR:
Configuration used: defaults
Review profile: CHILL
Plan: Pro Plus
Run ID: 257b6fe7-2de7-4ef2-a407-913ad084f9e8
📥 CommitsReviewing files that changed from the base of the PR and between a6f124b and 507f064.
📒 Files selected for processing (1)
Sorry, something went wrong.
| Back | FazBrowse Home | New Git URL |
…maps
perf: rebuild Multimap canonicalization without intermediate vectors/maps
fix #220
Summary by CodeRabbit
Release Notes