diff options
author | kinggo <lilong.21@bytedance.com> | 2022-10-30 00:57:40 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-10-29 18:57:40 +0200 |
commit | 3963a79a64ac0c35c38274516cdc1080a326102a (patch) | |
tree | ab2b399bbcff5125e1e2d4d9479ae19842457c1d /args.go | |
parent | fix: (#1410) (diff) | |
download | fasthttp-3963a79a64ac0c35c38274516cdc1080a326102a.tar.gz fasthttp-3963a79a64ac0c35c38274516cdc1080a326102a.tar.bz2 fasthttp-3963a79a64ac0c35c38274516cdc1080a326102a.zip |
feat: add PeekKeys and PeekTrailerKeys (#1405)
* feat: add PeekKeys and PeekTrailerKeys
* Improve warning
Co-authored-by: Erik Dubbelboer <erik@dubbelboer.com>
Diffstat (limited to 'args.go')
-rw-r--r-- | args.go | 8 |
1 files changed, 8 insertions, 0 deletions
@@ -633,3 +633,11 @@ func peekAllArgBytesToDst(dst [][]byte, h []argsKV, k []byte) [][]byte { } return dst } + +func peekArgsKeys(dst [][]byte, h []argsKV) [][]byte { + for i, n := 0, len(h); i < n; i++ { + kv := &h[i] + dst = append(dst, kv.key) + } + return dst +} |