This repository has been archived by the owner on Sep 9, 2019. It is now read-only.
Releases: xp-lang/compiler
Releases · xp-lang/compiler
4.0.0: Enter PHP 5.5
PHP 5.6
- Implemented power operator
**
in PHP syntax - @thekid
PHP 5.5
- Merged PR #43: Add support for
::class
resolution - @thekid - Allowed dereferencing of constant arrays and strings - @thekid
- Changed ARM blocks to use try / finally in PHP 5.5+ - @thekid
- Changed code to emit native
finally
statement in PHP 5.5+ - @thekid - Merged PR #40: support for generators / yield - @thekid
- Changed default emitter to "php5.5" - @thekid
PHP 5.4
- Merged PR #46: Add function type syntax - @thekid
- Merged PR #45: Make lambda capturing explicit when using PHP - @thekid
- Merged PR #44: Implement short array and map syntax in PHP - @thekid
- Merged PR #41: Fix capturing of local variables in lambdas - @thekid
Other
- Fixed forward compatibility with XP 6.6.0 - @thekid
3.0.0: Support for HHVM and PHP7
Added support for PHP7
- Replaced String classes used in test suite as "string" is reserved as
type name in PHP7.
(@thekid) - Rewrote tests verifying exceptions are raised for argument type
mismatches to work in both PHP 5.x and PHP 7.X.
(@thekid)
Fixed issue #39: HHVM support
- Fixed sscanf() incompatibilities - HHVM doesn't support
%*
for not
assigning variables. Worked around by supplying dummy variables.
(@thekid) - Added a native importer which doesn't verify extensions. HHVM does
not group functions into extensions like PHP does.
(@thekid)
Removed support for PHP 5.2 and PHP 5.3
- Added new PHP 5.4 the default emitter, which emits
new T().method()
as(new T())->method()
instead of wrapping it in the deprecated
create
core functionality.
(@thekid) - Removed PHP 5.2 and 5.3 emitters, using
-E php5.2
or-E php5.3
on the command line will produce an error!
(@thekid)
Other improvements
- Improved performance when loading supported syntaxes by deferring
parser and lexer instantiation until when first needed.
(@thekid)
2.1.0: XP Framework adoption
- Adopted to newer XP versions by no longer using deprecated functionality:
. Replaceduses()
call with class loader API call
. Replacedraise()
with reflection-based creation statement
. Changeddelete()
call to useunset
language construct.
(@thekid)
2.0.0: New lambda syntax, namespaces and 5.3 closures
This release contains the following changes:
- Made available via Composer (@thekid)
- Heads up: Changed minimum XP version to run the XP compiler to XP
6.0.0. It can still generated code to run on XP 5.X-SERIES, but will
require 6.X-SERIES to run itself (@thekid) - Added possibility to add default values to lambda parameters. See
#38 - (@thekid) - Fixed compiler choking on methods with generic return types (@thekid)
- Allowed omitting the parameter type inside method declarations. The type
will then be set tovar
and will be unchecked at runtime (@thekid) - Changed syntax for lambdas from
#{ $a -> $a + 1 };
to$a -> $a + 1;
,
after resolving the grammar conflicts the former was avoiding. The old
form is still supported but will raise compile-time warnings. It will be
removed in the next major release.
(@thekid) - Changed PHP 5.3 emitter to emit PHP 5.3 anonymous functions for lambdas
(@thekid) - Merged pull request #37 to solve issue #36: Support "new T()", "T::const"
and "T::$static" inside annotations - (@thekid) - Added backwards compatible emitter (-E php5.2) to create non-namespaced
code for use with XP 5.8 and PHP 5.2 - (@thekid) - Changed default behaviour to creating namespaced code (compatible with
XP 5.9 and PHP 5.3+) - (@thekid) - Changed "-E" command line argument to support versions:
-E name
will
load xp.compiler.emit.name.Emitter,-E name60
will load the class
xp.compiler.emit.name.V60Emitter - (@thekid) - Changed all emit*() methods in xp.compiler.emit.Emitter to protected
(@thekid)