Allow calling closures inline

Summary: Add support for invokeing closures inline to the parser:
`(function () { echo "foo"; })()`

Fixes #3890

Reviewed By: @JoelMarcey

Differential Revision: D1662663

Signature: t1:1662663:1415249841:ce564a5ec1a2324dbca6c0e47db96ed85076c89e
Fix reference to nonexistent module.

Summary: This gets things building again. The problem was introduced
through a sloppy rebase.

Reviewed By: @jwatzman

Differential Revision: D1663499
Copy missing relative information from timelib

Summary: Copy over all relatice information from timelib struct, this fixes some of the
special modify modes, including `+1 weekday`.

Fixes #3468

Reviewed By: @JoelMarcey

Differential Revision: D1663384

Signature: t1:1663384:1415255569:cf95e9f81af740e5d235702cb873c10bb27cb5ec
Fix bugs with VariableSerializer and setObjectInfo() / setResourceInfo()

Summary: writeArrayFooter() depends on m_objCode, but callers of setObjectInfo()
could possibly clobber m_objCode and not properly restore it (i.e. they
weren't following a proper "push/pop" pattern). This caused var_export()
to produce wrong output in some cases.

This diff replaces all uses of setObjectInfo() and setResourceInfo() to
instead use new push/pop APIs to avoid these kinds of bugs.

Reviewed By: @swtaarrs

Differential Revision: D1660182
Add support for pre-built branches to benchy

Summary: Many times you will have already built a branch somewhere and you
want to use that build rather than having to rebuild everything to a place
that benchy knows about. This patch adds the ability to specify the location
of a pre-built VM so that this workflow is now possible.

This diff also updates the tab complete script to support tab completion
of paths as part of the VM. Run with -h to see an example of how to use
it.

Reviewed By: @jdelong

Differential Revision: D1646858
Add overflow info to is_numeric_string

Summary: When comparing numeric strings which overflow PHP detects overflow and falls
back to standard string comparison.

Fixes #1914

Reviewed By: @fredemmott

Differential Revision: D1659152

Signature: t1:1659152:1415142964:f4f12b72a5866d2df5b1407d6fd8c327ca5e415c
Fix return value annotation for openssl_x509_checkpurpose

Summary: Was supposed to return boolean on success or failure and only integer on error.

Fixes #4070

Reviewed By: @JoelMarcey

Differential Revision: D1660716

Signature: t1:1660716:1415202574:8911c0a9304e956e1f1790c7060b2ef430409b7c
Match PHP 5 backquote processing

Summary: In PHP 5 backquotes can be nested by escaping the inner pair.
(e.g. echo `echo \`echo foo\``)

Fixes #4078

Reviewed By: @JoelMarcey

Differential Revision: D1660472

Signature: t1:1660472:1415170658:cfa04549bbb32a3433b2991f0ac499a947ee3ad1
Remove KindOfNamedLocal from DataType enum

Reviewed By: @edwinsmith

Differential Revision: D1632828
Eliminate default cases in DataType switches in runtime/base

Reviewed By: @edwinsmith

Differential Revision: D1638294
Eliminate default cases in DataType switches in runtime/vm

Reviewed By: @edwinsmith

Differential Revision: D1638299
Eliminate default cases in DataType switches in compiler

Reviewed By: @edwinsmith

Differential Revision: D1640979
Eliminate default cases in DataType switches in ext

Reviewed By: @edwinsmith

Differential Revision: D1660924
Provide runtime option for udiffing the same two arrays

Summary: With non-normal (beyond specification) comparison callbacks for array diff
functions like `array_udiff`, we don't match PHP 5.x in the output. PHP 5.x
gives an empty array; we sometimes actuall have an element in the array.

I actually think our behavior is not wrong, per se because it clearly states
that comparison functions need to specified as returing -1, 0, 1 when comparing.
But to match PHP 5.x, we can provide a runtime option to help match behavior.

Fixes #3653

Reviewed By: @paulbiss

Differential Revision: D1660877

Signature: t1:1660877:1415215794:79f4f61ceb60fd0f34dd9b87a969e93e976e3756
Add hfsort to .gitignore.

Summary: Add hfsort to .gitignore.
Closes https://github.com/facebook/hhvm/pull/4146

Reviewed By: @sgolemon

Differential Revision: D1663371

Signature: t1:1663371:1415295773:22d534a602ab05709b93fb318e05087203b64dbf
http streams: only split headers into two pieces

Summary: Limit header explosions to two pieces to avoid truncating header data containing colons.
Closes https://github.com/facebook/hhvm/pull/4147

Reviewed By: @sgolemon

Differential Revision: D1663374

Signature: t1:1663374:1415295777:e15ae52ba0709f440ae0c8ae4ebece29884ff84a
Ban trailing commas in type parameter lists

Summary: HHVM rejects this, we should too -- it seems much more likely
indicitive of an error than trailing commas on functions.

Fixes https://github.com/facebook/hhvm/issues/3168

Reviewed By: @int3, @elgenie

Differential Revision: D1662701

Signature: t1:1662701:1415253151:71fafd8e490a6b014753b9e2c7e7b90ead74c20d
Fix exhaustiveness checks on first-class enum switch

Summary: We need to expand thru tyvars and check across unresolved here.

Reviewed By: @int3, @elgenie

Differential Revision: D1661633

Signature: t1:1661633:1415253666:32eb74f02129508f9e4a07c59b701c8e454c5c8a
Fix mis-parsing of '{$' constructions in String2

Summary: During string interpolation, just `$foo` is a special beast --
notably `"$foo->x()"` is a //member// lookup on `$foo` followed by two
literal parens. That's why we have `encapsed_expr`. But, if it's
surrounded by curlies, then it is in fact a real expression again, and
we should use the full expression parser on it.

The new test cases show the three variations here, by way of errors: one
is a failed member lookup, one a failed function call, and one just
doesn't parse at all.

Fixes https://github.com/facebook/hhvm/issues/2972
Fixes https://github.com/facebook/hhvm/issues/3669

Reviewed By: @elgenie

Differential Revision: D1662433

Signature: t1:1662433:1415287920:d226bfd8f0c4b22130592ec9a15291f311c561dc
Add namespaced name to closures

Summary: Fixes facebook/hhvm#1669

Reviewed By: @paulbiss

Differential Revision: D1662546

Signature: t1:1662546:1415235548:93421bc3160e3dbec7aa582a14f4cd8afba83706