File tree Expand file tree Collapse file tree 1 file changed +1
-4
lines changed Expand file tree Collapse file tree 1 file changed +1
-4
lines changed Original file line number Diff line number Diff line change @@ -39,10 +39,7 @@ to those statements.
3939In this topic, you'll build a method that computes the area of
4040different geometric shapes. But, you'll do it without resorting to object
4141oriented techniques and building a class hierarchy for the different shapes.
42- You'll use * pattern matching* instead. To further emphasize that we're not
43- using inheritance, you'll make each shape a ` struct ` instead of a class.
44- Note that different ` struct ` types cannot specify a common user defined
45- base type, so inheritance is not a possible design.
42+ You'll use * pattern matching* instead.
4643As you go through this sample, contrast this code with how it would
4744be structured as an object hierarchy. When the data you must
4845query and manipulate is not a class hierarchy, pattern matching enables
You can’t perform that action at this time.
0 commit comments