# \[Pitch\] Introduce existential \`any\`

**URL:** <https://forums.swift.org/t/pitch-introduce-existential-any/53520>\
**Category:** Pitches\
**Created:** [November 16, 2021, 3:48am UTC](https://forums.swift.org/t/pitch-introduce-existential-any/53520 "2021-11-16T03:48:13Z")\
**Posts on this page:** 1\
**Showing post:** 21

<div class="post-metadata">

**Author:** ![DevAndArtist](https://sea2.discourse-cdn.com/swift/user_avatar/forums.swift.org/devandartist/32/287_2.png) [@DevAndArtist](https://forums.swift.org/u/DevAndArtist)\
**Post date:** [November 16, 2021, 3:24pm UTC](https://forums.swift.org/t/pitch-introduce-existential-any/53520/21 "2021-11-16T15:24:07Z")

</div>

Well, as outlined before we have to be careful on how we involve `any` in the context out meta types. The proposed `(any P).Type` does already break the ideas from the UX discussion, as `any P.Type` was meant to become the "existential of the protocol P metatype".

If on the other hand we'd design it in an additive manner, then I'm fine deferring this topic. I have a fear that if we don't solve it with `any` at all, or if we go the with the pitched direction in the context of meta types, the chances on when we can resolve the issue with meta types might shrink down to zero.

Personally I would love to see a `meta` keyword and finally free up the `.Type` space for custom nested types called `Type`, however this is such a massive source break. :(

One future direction from our old proposal was this:

```swift
func subtype<T>(of type: Type<T>, named: String) -> AnyType<T>? { ... }

// with the idea of a `meta` keyword this would be
func subtype<T>(of type: meta T, named: String) -> (any meta T)? { ... }

// with the spelling from Joe Groff this would become
func subtype<T>(of type: (any T).Type, named: String) -> (any P.Type)? { ... }

```

---

_[View the full topic](https://forums.swift.org/t/pitch-introduce-existential-any/53520)._
