From 38b9734230eb578faa4758b98d1d49860284e0bb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Catt=C4=AB=20Cr=C5=ABd=C4=93l=C4=93s?= <17695588+wzy9607@users.noreply.github.com> Date: Mon, 16 Sep 2024 15:09:28 +0800 Subject: [PATCH] doc(metric): fix incorrect explanation of how `metric.WithAttributes` works (#5822) --- metric/instrument.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/metric/instrument.go b/metric/instrument.go index ea52e402331..a535782e1d9 100644 --- a/metric/instrument.go +++ b/metric/instrument.go @@ -351,7 +351,7 @@ func WithAttributeSet(attributes attribute.Set) MeasurementOption { // // cp := make([]attribute.KeyValue, len(attributes)) // copy(cp, attributes) -// WithAttributes(attribute.NewSet(cp...)) +// WithAttributeSet(attribute.NewSet(cp...)) // // [attribute.NewSet] may modify the passed attributes so this will make a copy // of attributes before creating a set in order to ensure this function is