Commit Graph

15 Commits

Author SHA1 Message Date
Alex E. 2d80c18304
[Code health] Perform cppcheck cleanup (#3150) 2024-12-07 00:34:19 +01:00
Romain Geissler @ Amadeus 3d9c2b5382
[BUILD] Avoid buggy "should be explicitly initialized in the copy constructor" warning with gcc <= 8 (#3087)
gcc <= 8, when building with -Wextra (and -Werror) wrongly raises this:
/data/mwrep/res/mdw/SIOTF/internal/opentelemetry_cpp/trace/18-0-0-7/include/opentelemetry/trace/default_span.h: In copy constructor 'opentelemetry::v1::trace::DefaultSpan::DefaultSpan(const opentelemetry::v1::trace::DefaultSpan&)':
/data/mwrep/res/mdw/SIOTF/internal/opentelemetry_cpp/trace/18-0-0-7/include/opentelemetry/trace/default_span.h:70:3: error: base class 'class opentelemetry::v1::trace::Span' should be explicitly initialized in the copy constructor [-Werror=extra]
   DefaultSpan(const DefaultSpan &spn) noexcept : span_context_(spn.GetContext()) {}
   ^~~~~~~~~~~

See on Compiler Explorer here: https://godbolt.org/z/ed5rv74nT

I believe Jason Merrill fixed it in gcc for all gcc >= 9 with:
https://gcc.gnu.org/git/?p=gcc.git;a=commitdiff;h=f3f7cefecc833b4ab652215ceb8b408c21dca225;hp=777083bb806dbe31ab97002b7d445191d3ee7a2d

Workaround this by calling explicitly the empty Span constructor.
2024-10-08 17:28:30 +02:00
Marc Alff 17da6d87c1
[API] Add a new AddLink() operation to Span (#2380) 2023-10-27 18:27:57 +02:00
Cengizhan Pasaoglu 990da7dd0f
Fix inclusion header files and use forward declaration for API (#2124) 2023-05-07 16:02:40 -07:00
Marc Alff 85b78784a5
Fix more build warnings (#1616) (#1620) 2022-09-20 11:43:08 -07:00
Lalit Kumar Bhasin 99a72e1ae0
Add noexcept/const qualifier at missing places for Trace API. (#1374)
* fix noxcept

* fix etw
2022-05-06 07:21:22 -07:00
Lalit Kumar Bhasin 61d3c5e318
Document DefaultSpan, remove DefaultTracer (#959) 2021-08-25 09:07:39 -07:00
Lalit Kumar Bhasin 3fa6525f40
Add missing Copyright headers (#754) 2021-05-25 11:37:08 +05:30
Johannes Tax a978920411
Get rid of obsolete core namespace in API (#686) 2021-04-22 12:15:10 +05:30
Max Golovanov d1f0b136e3
Resolve warnings about unused parameter in interface definitions (#674) 2021-04-14 06:40:48 +05:30
Lalit Kumar Bhasin cae3511915
Update StatusCode as per specs (#535) 2021-01-29 13:57:52 +05:30
Karen Xu f2708921be
Move KeyValueIterable and KeyValueIterableView from trace to common (#363) 2020-10-17 20:10:44 -07:00
Johannes Tax 4a1b793ce7
Add functionality to explicitely specify a span parent (#349) 2020-10-09 00:55:39 -07:00
Johannes Tax dbf2e36478
Add Scope object to control the currently active span (#324) 2020-09-15 08:06:31 -07:00
Tianlin-Zhao 09983abea2
Added Http Trace Context (#143) 2020-08-25 18:18:40 -07:00