annotate clang/test/SemaCXX/value-initialization.cpp @ 221:79ff65ed7e25

LLVM12 Original
author Shinji KONO <kono@ie.u-ryukyu.ac.jp>
date Tue, 15 Jun 2021 19:15:29 +0900
parents 1d019706d866
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
150
anatofuz
parents:
diff changeset
1 // RUN: %clang_cc1 -fsyntax-only -verify %s -std=c++11
anatofuz
parents:
diff changeset
2
anatofuz
parents:
diff changeset
3 struct A { // expected-warning {{does not declare any constructor to initialize}}
anatofuz
parents:
diff changeset
4 const int i; // expected-note{{const member 'i' will never be initialized}} expected-note {{implicitly deleted}}
anatofuz
parents:
diff changeset
5 virtual void f() { }
anatofuz
parents:
diff changeset
6 };
anatofuz
parents:
diff changeset
7
anatofuz
parents:
diff changeset
8 int main () {
anatofuz
parents:
diff changeset
9 (void)A(); // expected-error {{call to implicitly-deleted default constructor}}
anatofuz
parents:
diff changeset
10 }