Run DCE after a LoopFlatten test to reduce spurious output [nfc]
[llvm-project.git] / clang / test / SemaCXX / cxx1z-user-defined-literals.cpp
blob978fd2fbc4b2b6a3b99755c3476cbbaa5d49661d
1 // RUN: %clang_cc1 -std=c++1z %s -include %s -verify
3 #ifndef INCLUDED
4 #define INCLUDED
6 #pragma clang system_header
7 namespace std {
8 using size_t = decltype(sizeof(0));
10 struct string_view {};
11 string_view operator""sv(const char*, size_t);
14 #else
16 using namespace std;
17 string_view s = "foo"sv;
18 const char* p = "bar"sv; // expected-error {{no viable conversion}}
19 char error = 'x'sv; // expected-error {{invalid suffix}} expected-error {{expected ';'}}
21 #endif