Skip to content

Conversation

@AlisdairM
Copy link
Contributor

The typename keyword is not needed to identify a dependent type in a new expression.

This PR contributes to #3637 by resolving all current uses of typename in a new expression in the library.

@frederick-vs-ja
Copy link
Contributor

Hmm, I still think it would be cleaner to use iter-value-type here. See also #7844.

@AlisdairM
Copy link
Contributor Author

I agree, but that seemed a much bigger change.
We can resolve that preferred direction when LWG can take a look, hopefully for C++29.

The `typename` keyword is not needed to identify a dependant
type in a `new` expression.
@AlisdairM AlisdairM force-pushed the remove_typename_after_new branch from 3a90581 to 1713b56 Compare November 12, 2025 23:00
@tkoeppe tkoeppe merged commit 19ad41d into cplusplus:main Nov 15, 2025
2 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.

4 participants