Another pattern matching example (automatic casting).