From 41e33b1f3cb253e49cf5c626901a38926df18d57 Mon Sep 17 00:00:00 2001 From: Lalit Kumar Bhasin Date: Fri, 29 Apr 2022 00:19:48 +0530 Subject: [PATCH 1/3] fix initialization order --- .../etw/include/opentelemetry/exporters/etw/etw_tracer.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/exporters/etw/include/opentelemetry/exporters/etw/etw_tracer.h b/exporters/etw/include/opentelemetry/exporters/etw/etw_tracer.h index 65fe2770f2..f97a659541 100644 --- a/exporters/etw/include/opentelemetry/exporters/etw/etw_tracer.h +++ b/exporters/etw/include/opentelemetry/exporters/etw/etw_tracer.h @@ -761,10 +761,10 @@ class Span : public opentelemetry::trace::Span const opentelemetry::trace::StartSpanOptions &options, Span *parent = nullptr) noexcept : opentelemetry::trace::Span(), + start_time_(std::chrono::system_clock::now()), owner_(owner), parent_(parent), - context_(CreateContext()), - start_time_(std::chrono::system_clock::now()) + context_(CreateContext())) { name_ = name; UNREFERENCED_PARAMETER(options); From fe1e2c733d5f0c68d030ede3422ed0b75ede9cc4 Mon Sep 17 00:00:00 2001 From: Lalit Kumar Bhasin Date: Fri, 29 Apr 2022 00:33:32 +0530 Subject: [PATCH 2/3] fix --- sdk/src/metrics/meter.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sdk/src/metrics/meter.cc b/sdk/src/metrics/meter.cc index d5af7f9ec9..c0b0ce7a57 100644 --- a/sdk/src/metrics/meter.cc +++ b/sdk/src/metrics/meter.cc @@ -28,7 +28,7 @@ namespace nostd = opentelemetry::nostd; Meter::Meter(std::shared_ptr meter_context, std::unique_ptr instrumentation_library) noexcept - : meter_context_{meter_context}, instrumentation_library_{std::move(instrumentation_library)} + : instrumentation_library_{std::move(instrumentation_library)}, meter_context_{meter_context} {} nostd::shared_ptr> Meter::CreateLongCounter(nostd::string_view name, From 11284d4af0ff9347b79289db53be96c67f604ccd Mon Sep 17 00:00:00 2001 From: Lalit Kumar Bhasin Date: Fri, 29 Apr 2022 01:02:32 +0530 Subject: [PATCH 3/3] fix syntax error --- exporters/etw/include/opentelemetry/exporters/etw/etw_tracer.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/exporters/etw/include/opentelemetry/exporters/etw/etw_tracer.h b/exporters/etw/include/opentelemetry/exporters/etw/etw_tracer.h index f97a659541..82bd6d726c 100644 --- a/exporters/etw/include/opentelemetry/exporters/etw/etw_tracer.h +++ b/exporters/etw/include/opentelemetry/exporters/etw/etw_tracer.h @@ -764,7 +764,7 @@ class Span : public opentelemetry::trace::Span start_time_(std::chrono::system_clock::now()), owner_(owner), parent_(parent), - context_(CreateContext())) + context_(CreateContext()) { name_ = name; UNREFERENCED_PARAMETER(options);