prometheus/promql/parser
Bryan Boreham b987afa7ef labels: simplify call to get Labels from Builder
It took a `Labels` where the memory could be re-used, but in practice
this hardly ever benefitted. Especially after converting `relabel.Process`
to `relabel.ProcessBuilder`.

Comparing the parameter to `nil` was a bug; `EmptyLabels` is not `nil`
so the slice was reallocated multiple times by `append`.

Lastly `Builder.Labels()` now estimates that the final size will depend
on labels added and deleted.

Signed-off-by: Bryan Boreham <bjboreham@gmail.com>
2023-03-22 17:05:20 +00:00
..
ast.go Update go to 1.19, set min version to 1.18 (#11279) 2022-09-07 11:30:48 +02:00
functions.go promql: Add histogram_count and histogram_sum 2022-06-28 18:16:48 +02:00
generated_parser.y labels: simplify call to get Labels from Builder 2023-03-22 17:05:20 +00:00
generated_parser.y.go labels: simplify call to get Labels from Builder 2023-03-22 17:05:20 +00:00
lex.go Adds support for prettifying PromQL expression (#10544) 2022-07-07 18:13:36 +05:30
lex_test.go Run gofumpt on all files (#10392) 2022-03-03 17:21:05 +01:00
parse.go Switch from 'sanity' to more inclusive lanuage (#9376) 2022-11-28 17:09:18 +00:00
parse_test.go Update tests 2023-03-08 16:32:39 +01:00
prettier.go Adds support for prettifying PromQL expression (#10544) 2022-07-07 18:13:36 +05:30
prettier_rules.md Adds support for prettifying PromQL expression (#10544) 2022-07-07 18:13:36 +05:30
prettier_test.go Prettifier: Add spaces with non-callable keywords (#11005) 2022-07-15 00:09:56 +02:00
printer.go Prettifier: Add spaces with non-callable keywords (#11005) 2022-07-15 00:09:56 +02:00
printer_test.go Prettifier: Add spaces with non-callable keywords (#11005) 2022-07-15 00:09:56 +02:00
value.go promql: use explicit type declare instead of string. (#7716) 2020-08-02 09:57:38 +01:00