view clang/test/Modules/pr56826.cppm @ 236:c4bab56944e8 llvm-original

LLVM 16
author kono
date Wed, 09 Nov 2022 17:45:10 +0900
parents
children
line wrap: on
line source

// RUN: %clang_cc1 -std=c++20 -fsyntax-only -verify %s

export module m3;
export template <class> struct X {
  template <class Self> friend void f(Self &&self) {
    (Self&)self; // expected-warning {{expression result unused}}
  }
};
void g() { f(X<void>{}); } // expected-note {{in instantiation of function template specialization}}