Surprised this needs to be cast. Is this an IntelliJ peculiarity? If it's just IntelliJ, can you add a comment saying so.