4 ms·
It's not the same sort of intersection as you might understand it from mathematical sets: http://stackoverflow.com/questions/5653678/union-types-and-intersectio
by ken47 11y ago
It's not the same sort of intersection as you might understand it from mathematical sets: http://stackoverflow.com/questions/5653678/union-types-and-intersection-types http://stackoverflow.com/questions/5653678/union-types-and-i...
See the response about C#.
- WorldMaker 11y agoIt is referring to mathematical sets, but at the categorization of types level rather than the "shape" of types. If you think of Set X consisting of all the objects that could possibly be built as Class X and Set Y as all the objects that could possibly be built as Class Y, then the union of those sets is all of the Class X derived objects and all of the Class Y derived objects, whereas the intersection of those sets are whatever objects manage to implement or derive from both Class X and Class Y.