Fixes to isJSXElement.

* Don't treat `<T>{x:1, y:2}` as JSX tag.
* Treat `<T>[EOF]` as cast for completions.