```Object foo``` is a class instance, perhaps null, perhaps a Clock or AlarmClock or Vegetable.

What is the expression to ask the boolean question:
Is foo of type Clock or a type derived from Clock, such as AlarmClock?


I tried the obvious ```foo is Clock```, but this did not compile.
```
Error: type `Object` is not an expression
       bool isClock = (o is Clock)
                            ^
```

Reply via email to