h...@sdf.org writes:

> I'm trying to compile OpenCog [1] using g++47, but get an error about
> missing std::stoi.
>
> I have attached a micro-example [2] that generates the same error, if I
> try to compile it with:
>
> % g++47 -std=c++11 s.cc
> s.cc: In function 'int main()':
> s.cc:8:13: error: 'stoi' is not a member of 'std'
>
>
> There are no problems neither with clang nor with g++ on Debian:
>
> % clang++ -std=c++11 s.cc
>
>
>
> What am I missing?

An old libc++ bug in gcc.

You need a newer compiler. 

The default compiler on recent (I think 10.0 and up) is a version of
clang that will get this right.
_______________________________________________
freebsd-ports@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-ports
To unsubscribe, send any mail to "freebsd-ports-unsubscr...@freebsd.org"

Reply via email to