
module Possibly fix https://github.com/llvm/llvm-project/issues/96693 The direct reason is that we are calculating the linkage for the declaration too early so that the linkage got calculated incorrectly. And after I look into the problem, I found it is completely not necessary to calculate the linkage there. It is for ModulesTS. So I simply removes that legacy experimental code and fix the issue.
23 lines
369 B
C++
23 lines
369 B
C++
// RUN: rm -rf %t
|
|
// RUN: split-file %s %t
|
|
// RUN: cd %t
|
|
//
|
|
// RUN: %clang_cc1 -std=c++20 %t/m.cppm -fsyntax-only -verify
|
|
|
|
//--- foo.h
|
|
|
|
template <typename... U>
|
|
static void foo(U...) noexcept;
|
|
|
|
class A {
|
|
template <typename... U>
|
|
friend void foo(U...) noexcept;
|
|
};
|
|
|
|
//--- m.cppm
|
|
// expected-no-diagnostics
|
|
module;
|
|
#include "foo.h"
|
|
export module m;
|
|
export using ::A;
|