int (Something something) { return switch (something) { case P(_) when something instanceof Object o: yield o.hashCode(); case E _ when something instanceof Object o1: yield <error descr="Cannot resolve symbol 'o'">o</error>.hashCode(); default: { yield 2; } }; }