Open Wilfred opened 5 years ago
As of c2c032e8c20e841dddadfd111ca36da5c225239a, a workaround is to restart hack-mode (i.e. M-x hack-mode
) when this occurs.
I'm struggling to replicate this. Will reopen if I see it happen again.
OK, I can replicate.
// This will run, but it's not doing what the user expects. We never
// pass arguments to entry points.
<<__EntryPoint>>
function bad_variadic(mixed ...$_): void {}
Insert this into a file. Next, start typing a <?hh
header before hand. Observe that the highlighting of __EntryPoint
breaks.
Currently we set text properties but never remove them, resulting in modified code incorrectly being considered XHP.