commit | 5bef8943865f1ebe9e7867ba5e3082cfd6a79e4d | [log] [tgz] |
---|---|---|
author | Wyatt Hepler <hepler@google.com> | Thu Sep 15 21:05:40 2022 +0000 |
committer | CQ Bot Account <pigweed-scoped@luci-project-accounts.iam.gserviceaccount.com> | Thu Sep 15 21:05:40 2022 +0000 |
tree | 2c0177583942f64edb26b0917ebd6cddd76042b2 | |
parent | 9087b154595b8043da257bd8d4dbcd8c8934180b [diff] |
pw_string: pw::InlineString implicit conversions from std::string_view std::string requires conversions from std::string_view to be explicit. For pw::InlineString, explicit conversions are more cumbersome because the capacity template parameter must be specified. This makes it more awkward use std::string_view with pw::InlineString<> when calling a function or initializing a struct member with aggregate initialization. This change allows implicit conversions from std::string_view to pw::InlineString<kCapacity>. Types that convert to std::string_view still require explicit conversion. Change-Id: I3cc8264753a0ba271364a900522ba8f77747b079 Reviewed-on: https://pigweed-review.googlesource.com/c/pigweed/pigweed/+/110394 Reviewed-by: Ted Pudlik <tpudlik@google.com> Pigweed-Auto-Submit: Wyatt Hepler <hepler@google.com> Commit-Queue: Auto-Submit <auto-submit@pigweed.google.com.iam.gserviceaccount.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/.