Commit 310c265
committed
Reorganize DynamicCasting spec
This only rearranges the existing sections; it does not change any technical points.
This attempts to make the spec a little clearer by grouping the individual type discussions under four main headings:
* Classes and Foreign Types. This includes Swift classes, Obj-C classes, and CF types.
* Other Concrete Types. Struct, Enum, Tuple, Function, Optional, and Set/Dict/Array
* Existential Types. Any, AnyObject, Error, Protocol types, and AnyHashable(*)
* Metatypes & Existential Metatypes (*)
This organization seems to flow a little better.
In particular, it gives me a place to discuss issues common to all Existential types, which I'll work through in a subsequent PR.
Footnotes: This organization isn't perfect, of course:
* AnyHashable isn't really an Existential type, but it behaves as such for casting purposes, so it makes the most sense to discuss it in the Existentials section.
* Metatypes are technically concrete types, but it seems to make more sense to discuss them after discussing Existential types.1 parent 539b241 commit 310c265
1 file changed
+189
-162
lines changed
0 commit comments