Skip to content

Covariance example could be clearer #3

@ChrisBrooksbank

Description

@ChrisBrooksbank

'''c#
circlePusher.Push( new Circle());
Shape aShape = shapePopper.Pop();
'''

Implys we push a Circle onto a stack, and then pop it back off.
In fact this isn't the case as its two separate stack objects.

Also we ought to mention the naiveness of the Stack class, i.e. no bounds checking

Metadata

Metadata

Labels

No labels
No labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions