Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for enable_if Attribute #225

Open
Swatinem opened this issue Jul 8, 2021 · 3 comments
Open

Add support for enable_if Attribute #225

Swatinem opened this issue Jul 8, 2021 · 3 comments

Comments

@Swatinem
Copy link
Contributor

Swatinem commented Jul 8, 2021

This is supported in llvm, since a long time it seems:

https://github.com/llvm/llvm-project/blob/026bb84bcd42b875d77b769eb5ee4c19fc2a9719/llvm/include/llvm/Demangle/ItaniumDemangle.h#L5275-L5286

> llvm-cxxfilt "__Z6strchrUa9enable_ifIXLb1EEEPKci"
strchr(char const*, int) [enable_if:true]
> llvm-cxxfilt "__Z6memchrUa9enable_ifIXLb1EEXLb1EEEPKvU17pass_object_size1ij"
memchr(void const*, int pass_object_size1, unsigned int) [enable_if:true, true]
@khuey
Copy link
Collaborator

khuey commented Jul 8, 2021

Is this documented anywhere?

@Swatinem
Copy link
Contributor Author

Swatinem commented Jul 8, 2021

I don’t really find anything for this. llvm seems to hardcode the whole Ua9enable_ifI part and match on that. No idea where that is coming from.

@khuey
Copy link
Collaborator

khuey commented Jul 8, 2021

'U' is defined for vendor prefixes but the 'a' immediately after that is not compatible with the spec, as far as I can tell. It should be followed by a regular <source-name> production (i.e. the 9enable_if part).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants