The Facebook XHP extension introduces what are basically XML literals (well, XHTML literals) to the PHP language, allowing syntax like the following:
$foo = <div>hello</div>;
$foo = <div>
hello
</div>;
$foo = 'hello';
echo <div>{$foo}</div>; // outputs <div>hello</div>
$foo = 'hello';
echo <div>{substr($foo, 0, 2)}</div>; // outputs <div>he</div>
The biggest problem is that I cannot find an IDE that supports this syntax without flagging it as a syntax error.
I'm told that Facebook generally uses vim or emacs for development but I'm hoping for a more full-blown IDE that supports this syntax. At present, Netbeans 6.9, 7.0 M2, and Zend Studio 8 all flag this syntax as an error even though it executes fine on PHP with the XHP extension enabled.
Suggestions for an editor or plugin to an editor that allows this to work without syntax errors?
Info about XHP: https://github.com/facebook/xhp/wiki