Add test for std::filesystem::path
This commit is contained in:
parent
75b1314f6b
commit
aa6d4924b5
24
test/Prompt/ValuePrinter/FileSystemPath.C
Normal file
24
test/Prompt/ValuePrinter/FileSystemPath.C
Normal file
@ -0,0 +1,24 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// CLING - the C++ LLVM-based InterpreterG :)
|
||||
//
|
||||
// This file is dual-licensed: you can choose to license it under the University
|
||||
// of Illinois Open Source License or the GNU Lesser General Public License. See
|
||||
// LICENSE.TXT for details.
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
// RUN: cat %s | %cling | FileCheck %s
|
||||
|
||||
#include <iostream>
|
||||
#if __cplusplus >= 201703L
|
||||
#include <filesystem>
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
auto p = std::filesystem::path("/some/path/foo.cpp");
|
||||
p
|
||||
#else
|
||||
// Hack to prevent failure if feature does not exist!
|
||||
std::cout << "(std::filesystem::path &)";
|
||||
std::cout << "/some/path/foo.cpp\n";
|
||||
#endif
|
||||
// CHECK: (std::filesystem::path &) /some/path/foo.cpp
|
Loading…
Reference in New Issue
Block a user