History log of /PHP-Parser/test/PhpParser/PrettyPrinterTest.php (Results 26 – 50 of 56)
Revision (<<< Hide revision tags) (Show revision tags >>>) Date Author Comments
Revision tags: v4.3.0, v4.2.5, v4.2.4, v4.2.3, v4.2.2, v4.2.1
# b7e63615 19-Jan-2019 Lars Moelleken

updates via "rectorphp/rector" (#573)

- "global" -> remove unused "use" statements
- "phpunit" -> fix "@covers" comments
- "phpunit" -> replace "->will($this->returnValue()" with "->

updates via "rectorphp/rector" (#573)

- "global" -> remove unused "use" statements
- "phpunit" -> fix "@covers" comments
- "phpunit" -> replace "->will($this->returnValue()" with "->willReturn()"
- "UseTest.php" -> add missing namespace
- "composer.json" -> use "autoload-dev"
- remove -> "require_once" usage in the tests (use autoload-dev via composer.json)

-> most of the changes are done automatically by "https://github.com/rectorphp/rector"

show more ...


Revision tags: v4.2.0, v4.1.1, v4.1.0
# d638dd9b 22-Sep-2018 Tomáš Votruba

Use methods instead of annotations for expected exceptions (#533)


Revision tags: v4.0.4, v4.0.3, v4.0.2
# 6526ea24 03-Jun-2018 Nikita Popov

Throw when printin EncapsedStringPart

This needs to go through something like Encapsed or ShellExec to
determine quotation type. Explicitly throw an exception to avoid
getting an und

Throw when printin EncapsedStringPart

This needs to go through something like Encapsed or ShellExec to
determine quotation type. Explicitly throw an exception to avoid
getting an undefined method error.

show more ...


Revision tags: v4.0.1, v4.0.0, v3.1.5, v4.0.0beta1, v3.1.4
# 5285df8f 13-Jan-2018 Nikita Popov

[CS] Use elseif instead of else if

Conflicts:
lib/PhpParser/TokenStream.php


Revision tags: v4.0.0alpha3, v3.1.3
# 4dbb02c5 12-Dec-2017 Gabriel Caruso

Use Null Coalesce Operator


Revision tags: v4.0.0alpha2, v3.1.2
# b58157f0 02-Nov-2017 TomasVotruba

add strict_types to tests + fix explode type


# 5900d78c 29-Oct-2017 Nikita Popov

FPPP: Support anonymous classes (#432)

This is a huge hack... We temporarily create a new node with the
correct structure and use that for printing.

I think it would be better t

FPPP: Support anonymous classes (#432)

This is a huge hack... We temporarily create a new node with the
correct structure and use that for printing.

I think it would be better to always use a separate node type for
NewAnonClass, rather than using a combination of New and Class,
but this would require some larger changes, as this node type would
have to be both Expr and ClassLike, which is not possible right now,
as the latter is a class rather than an interface...

show more ...


Revision tags: v4.0.0alpha1
# f071b660 06-Oct-2017 Nikita Popov

Print comments of inserted statements


Revision tags: v3.1.1
# af128074 13-Aug-2017 TomasVotruba

[cs] apply same to tests


Revision tags: v3.1.0, v3.0.6
# a6846e3b 28-Apr-2017 Nikita Popov

Always use Identifier nodes

The parser will now always generate Identifier nodes (for
non-namespaced identifiers). This obsoletes the useIdentifierNodes
parser option.

Node

Always use Identifier nodes

The parser will now always generate Identifier nodes (for
non-namespaced identifiers). This obsoletes the useIdentifierNodes
parser option.

Node constructors still accepts strings and will implicitly create
an Identifier wrapper. Identifier implement __toString(), so that
outside of strict-mode many things continue to work without changes.

show more ...


Revision tags: v3.0.5, v3.0.4, v3.0.3
# d287c167 03-Feb-2017 Nikita Popov

Pretty print: Handle Error in ClassConstFetch


# fd7ac251 29-Jan-2017 Nikita Popov

Throw if pretty-printing Error node


# b5fb6f2d 20-Jan-2017 Nikita Popov

Don't require useNopStatements=false for format preservation

Instead assign attributes on Nop nodes and in the pretty printer
specially handle end<start offsets. It's a somewhat weird ca

Don't require useNopStatements=false for format preservation

Instead assign attributes on Nop nodes and in the pretty printer
specially handle end<start offsets. It's a somewhat weird case,
but not wrong per se given the meaning the offsets have.

show more ...


# 48d3243a 19-Jan-2017 Nikita Popov

Drop last vestiges of consistent var mode flag


# 1bfbd7bc 19-Jan-2017 Nikita Popov

Make useExpressionStatement only supported mode


# 4d2a4d02 23-Dec-2016 Nikita Popov

Add first shot at format preserving pretty printer


# 6bcc6c31 22-Dec-2016 Nikita Popov

Add useIdentifierNodes mode to parser

In this mode non-namespaced names that are currently represented
using strings will be represented using Identifier nodes instead.
Identifier no

Add useIdentifierNodes mode to parser

In this mode non-namespaced names that are currently represented
using strings will be represented using Identifier nodes instead.
Identifier nodes have a string $name subnode and coerce to string.

This allows preserving attributes and in particular location
information on identifiers.

show more ...


# 58970e2a 11-Dec-2016 Nikita Popov

Improve LNumber/DNumber pretty printing

* Support PHP_INT_MIN
* Support negative binary/octal/hex numbers
* Support INF/-INF/NAN in namespaces


Revision tags: v3.0.2, v3.0.1, v3.0.0, v3.0.0beta2, v3.0.0beta1, v2.1.1, v3.0.0alpha1, v2.1.0
# 588e6a4d 02-Apr-2016 Nikita Popov

Add string kinds and doc string labels

Scalar\String_ and Scalar\Encapsed now have an additional "kind"
attribute, which may be one of:

* String_::KIND_SINGLE_QUOTED
* Str

Add string kinds and doc string labels

Scalar\String_ and Scalar\Encapsed now have an additional "kind"
attribute, which may be one of:

* String_::KIND_SINGLE_QUOTED
* String_::KIND_DOUBLE_QUOTED
* String_::KIND_NOWDOC
* String_::KIND_HEREDOC

Additionally, if the string kind is one of the latter two, an
attribute "docLabel" is provided, which contains the doc string
label (STR in <<<STR) that was originally used.

The pretty printer will try to take the original kind of the string,
as well as the used doc string label into account.

show more ...


# aa199120 09-Mar-2016 Nikita Popov

Add kind attribute for arrays

To distinguish array() and [] syntax. The pretty printer respects
this attribute. The shortArraySyntax pretty printer option acts as
a default in case t

Add kind attribute for arrays

To distinguish array() and [] syntax. The pretty printer respects
this attribute. The shortArraySyntax pretty printer option acts as
a default in case the attribute is not specified.

show more ...


Revision tags: v2.0.1
# 9829bf69 28-Feb-2016 Nikita Popov

Fix issue #251


Revision tags: v2.0.0, v2.0.0beta1
# e4b837e0 02-Oct-2015 Nikita Popov

Split up pretty printer test in stmt/expr

The list was getting unweildly.

Also improve error message when parsing fails in pretty printer
test and extend some tests.


# 39a039fa 21-Sep-2015 Nikita Popov

Add option for short array syntax in pretty printer


Revision tags: v1.4.1, v2.0.0alpha1, v1.4.0
# d8312a09 20-Jun-2015 Nikita Popov

Split parsing tests into code tests and other stuff

And run the other stuff against Php5 and Php7 parsers.

Also move canonicalize() from CodeTestAbstract into a free-standing
fu

Split parsing tests into code tests and other stuff

And run the other stuff against Php5 and Php7 parsers.

Also move canonicalize() from CodeTestAbstract into a free-standing
function.

show more ...


# 71fa7c66 13-Jun-2015 Nikita Popov

Support UVS in pretty printer

Try to generate interoperable code where possible (but not
everything can be expressed in PHP 5).


123