Using std types and functions within GCC

dkm@kataplop.net dkm@kataplop.net
Fri Mar 15 13:43:25 GMT 2024


March 15, 2024 at 2:00 PM, "Tom Tromey" <tom@tromey.com> wrote:
 
> > 
> > "David" == David Malcolm via Gcc <gcc@gcc.gnu.org> writes:
> > 
> 
> David> For example, there's at
> David> least one place where I'd have used std::optional, but that's C++14 and
> David> so unavailable.
> 
> FWIW, gdb had its own gdb::optional (which was really just a
> stripped-down copy of the one from libstdc++) to fill exactly this need,
> at least until we moved to C++17 this year. If you need it you could
> easily lift it from the gdb repository.
> 

Hi,

In the Rust frontend, we are using a single header implementation from https://github.com/TartanLlama/optional, until we can use something from libstdc++.

Marc


More information about the Gcc mailing list