commit | b2910a44678ae35cbe10613c6b0104f45c357114 | [log] [tgz] |
---|---|---|
author | Dennis Kormalev <denk@google.com> | Tue Jun 14 18:47:31 2022 +0000 |
committer | CQ Bot Account <pigweed-scoped@luci-project-accounts.iam.gserviceaccount.com> | Tue Jun 21 19:52:01 2022 +0000 |
tree | 24c16529eb9a94ff457ec67f0df5f8f7e8ad742f | |
parent | 6f87d9d1d643dad2c6ccfd1c9cb7d27134b2f751 [diff] |
pw_thread: Add explicit public default ctor for stl::Options Without the explicit default public constructor c++20-based compiler rejects `stl::Options{}` initialization and allows only `stl::Options()` one. See this example for the reference: https://godbolt.org/z/K5GWaGsTf. This CL also prevents to create `thread::Options` using `{}` syntax with explicitly defining the empty constructor instead of the default one. See this example for the reference: https://godbolt.org/z/EP7hTooo8. This is a redo of the 2bc2d9b4ea8fe26d5ff8b4a19b3886b64a24635e commit with proper copy/move constructors (they don't need to be explicitly defined, default ones are fine). Change-Id: I312773142003daea91ba3fbe41d86c2fab2d82b1 Reviewed-on: https://pigweed-review.googlesource.com/c/pigweed/pigweed/+/99140 Commit-Queue: Auto-Submit <auto-submit@pigweed.google.com.iam.gserviceaccount.com> Pigweed-Auto-Submit: Dennis Kormalev <denk@google.com> Reviewed-by: Wyatt Hepler <hepler@google.com> Reviewed-by: Scott James Remnant <keybuk@google.com>
Pigweed is an open source collection of embedded-targeted libraries–or as we like to call them, modules. These modules are building blocks and infrastructure that enable faster and more reliable development on small-footprint MMU-less 32-bit microcontrollers like the STMicroelectronics STM32L452 or the Nordic nRF52832.
For more information please see our website: https://pigweed.dev/.