[Lldb-commits] [PATCH] D49271: Adding libc++ formattors for std::optional

Pavel Labath via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Wed Aug 1 04:44:36 PDT 2018

labath added a comment.

Thanks for the patience. I've tried the patch out on our end. You shouldn't have any problems now.

Comment at: packages/Python/lldbsuite/test/functionalities/data-formatter/data-formatter-stl/libcxx/optional/TestDataFormatterLibcxxOptional.py:21
+    @add_test_categories(["libc++"])
+    @skipIf(oslist=no_match(["macosx"]), compiler="clang", compiler_version=['<', '5.0'])
shafik wrote:
> labath wrote:
> > Could you add another line for `gcc` here? The -std=c++17 flag seems to be supported starting with gcc-5.1.
> > 
> > Also a comment that this is due to the -std flag would be helpful to people looking at this in the future.
> Adding a comment makes sense.
> So `@add_test_categories(["libc++"])` won't skip for gcc bots then?
It won't because it doesn't make sense to do that. Gcc is perfectly capable of using libc++. The only tricky thing is that it doesn't have the magic `-stdlib` argument, so you have to specify the include paths and libraries explicitly (which our makefiles do).

Comment at: packages/Python/lldbsuite/test/functionalities/data-formatter/data-formatter-stl/libcxx/optional/main.cpp:17-20
+    bool has_optional = false ;
+    has_optional = true ;
This could be simplified to `bool has_optional = HAVE_OPTIONAL;`


More information about the lldb-commits mailing list