Skip to content

✨ Add same_template_as#305

Merged
elbeno merged 1 commit intointel:mainfrom
elbeno:same-template-as
Jan 5, 2026
Merged

✨ Add same_template_as#305
elbeno merged 1 commit intointel:mainfrom
elbeno:same-template-as

Conversation

@elbeno
Copy link
Contributor

@elbeno elbeno commented Dec 30, 2025

Problem:

  • It's sometimes useful to know if two types specialize the same base template.

Solution:

  • Add concept: same_template_as<T, U> and type trait: is_same_template_v<T, U>.

Problem:
- It's sometimes useful to know if two types specialize the same base template.

Solution:
- Add concept: `same_template_as<T, U>` and type trait: `is_same_template_v<T, U>`.
@elbeno
Copy link
Contributor Author

elbeno commented Dec 30, 2025

One use case we have for this is conceptualizing CIB builders. A builder's add function typically returns a dependent type that is the same base template as the builder.

@elbeno elbeno merged commit 21bef33 into intel:main Jan 5, 2026
50 checks passed
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

Successfully merging this pull request may close these issues.

2 participants