Skip to content

out-of-line definition of constrained members is not accepted (new failing example of closed bug) #139476

@xaxazak

Description

@xaxazak

currently closed bug here (maybe reopen that and close this one)

namespace moo
	{
		template <typename T>
		constexpr bool baa = true;
		
		template <typename T> requires baa<T>
		void caw();
	}

template <typename T> requires moo::baa<T>
void moo::caw() {}

compiler-explorer

(using -std=c++26)
clang (trunk): error: out-of-line definition of 'caw' does not match any declaration in namespace 'moo'
gcc: compiles successfully

Metadata

Metadata

Assignees

No one assigned

    Labels

    clang:frontendLanguage frontend issues, e.g. anything involving "Sema"conceptsC++20 conceptsconfirmedVerified by a second party

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions