mirror of
https://github.com/danog/parser.git
synced 2024-11-26 20:04:57 +01:00
558ce71563
Co-authored-by: Ryan Chandler <ryangjchandler@gmail.com> closes https://github.com/ryangjchandler/php-parser-rs/issues/130
429 lines
12 KiB
Plaintext
429 lines
12 KiB
Plaintext
[
|
|
Expression {
|
|
expr: Call {
|
|
target: Identifier {
|
|
name: "define",
|
|
},
|
|
args: [
|
|
Arg {
|
|
name: None,
|
|
value: LiteralString {
|
|
value: "a",
|
|
},
|
|
unpack: false,
|
|
},
|
|
Arg {
|
|
name: None,
|
|
value: Infix {
|
|
lhs: Variable {
|
|
name: "a",
|
|
},
|
|
op: Equals,
|
|
rhs: Variable {
|
|
name: "b",
|
|
},
|
|
},
|
|
unpack: false,
|
|
},
|
|
],
|
|
},
|
|
},
|
|
Expression {
|
|
expr: Call {
|
|
target: Identifier {
|
|
name: "define",
|
|
},
|
|
args: [
|
|
Arg {
|
|
name: None,
|
|
value: LiteralString {
|
|
value: "a",
|
|
},
|
|
unpack: false,
|
|
},
|
|
Arg {
|
|
name: None,
|
|
value: Infix {
|
|
lhs: Variable {
|
|
name: "a",
|
|
},
|
|
op: Identical,
|
|
rhs: Variable {
|
|
name: "b",
|
|
},
|
|
},
|
|
unpack: false,
|
|
},
|
|
],
|
|
},
|
|
},
|
|
Expression {
|
|
expr: Call {
|
|
target: Identifier {
|
|
name: "define",
|
|
},
|
|
args: [
|
|
Arg {
|
|
name: None,
|
|
value: LiteralString {
|
|
value: "a",
|
|
},
|
|
unpack: false,
|
|
},
|
|
Arg {
|
|
name: None,
|
|
value: Infix {
|
|
lhs: Variable {
|
|
name: "a",
|
|
},
|
|
op: NotEquals,
|
|
rhs: Variable {
|
|
name: "b",
|
|
},
|
|
},
|
|
unpack: false,
|
|
},
|
|
],
|
|
},
|
|
},
|
|
Expression {
|
|
expr: Call {
|
|
target: Identifier {
|
|
name: "define",
|
|
},
|
|
args: [
|
|
Arg {
|
|
name: None,
|
|
value: LiteralString {
|
|
value: "a",
|
|
},
|
|
unpack: false,
|
|
},
|
|
Arg {
|
|
name: None,
|
|
value: Infix {
|
|
lhs: Variable {
|
|
name: "a",
|
|
},
|
|
op: NotIdentical,
|
|
rhs: Variable {
|
|
name: "b",
|
|
},
|
|
},
|
|
unpack: false,
|
|
},
|
|
],
|
|
},
|
|
},
|
|
Expression {
|
|
expr: Call {
|
|
target: Identifier {
|
|
name: "define",
|
|
},
|
|
args: [
|
|
Arg {
|
|
name: None,
|
|
value: LiteralString {
|
|
value: "a",
|
|
},
|
|
unpack: false,
|
|
},
|
|
Arg {
|
|
name: None,
|
|
value: Infix {
|
|
lhs: Variable {
|
|
name: "a",
|
|
},
|
|
op: Add,
|
|
rhs: Variable {
|
|
name: "b",
|
|
},
|
|
},
|
|
unpack: false,
|
|
},
|
|
],
|
|
},
|
|
},
|
|
Expression {
|
|
expr: Call {
|
|
target: Identifier {
|
|
name: "define",
|
|
},
|
|
args: [
|
|
Arg {
|
|
name: None,
|
|
value: LiteralString {
|
|
value: "a",
|
|
},
|
|
unpack: false,
|
|
},
|
|
Arg {
|
|
name: None,
|
|
value: Infix {
|
|
lhs: Variable {
|
|
name: "a",
|
|
},
|
|
op: Sub,
|
|
rhs: Variable {
|
|
name: "b",
|
|
},
|
|
},
|
|
unpack: false,
|
|
},
|
|
],
|
|
},
|
|
},
|
|
Expression {
|
|
expr: Call {
|
|
target: Identifier {
|
|
name: "define",
|
|
},
|
|
args: [
|
|
Arg {
|
|
name: None,
|
|
value: LiteralString {
|
|
value: "a",
|
|
},
|
|
unpack: false,
|
|
},
|
|
Arg {
|
|
name: None,
|
|
value: Infix {
|
|
lhs: Variable {
|
|
name: "a",
|
|
},
|
|
op: Div,
|
|
rhs: Variable {
|
|
name: "b",
|
|
},
|
|
},
|
|
unpack: false,
|
|
},
|
|
],
|
|
},
|
|
},
|
|
Expression {
|
|
expr: Call {
|
|
target: Identifier {
|
|
name: "define",
|
|
},
|
|
args: [
|
|
Arg {
|
|
name: None,
|
|
value: LiteralString {
|
|
value: "a",
|
|
},
|
|
unpack: false,
|
|
},
|
|
Arg {
|
|
name: None,
|
|
value: Infix {
|
|
lhs: Variable {
|
|
name: "a",
|
|
},
|
|
op: BitwiseXor,
|
|
rhs: Variable {
|
|
name: "b",
|
|
},
|
|
},
|
|
unpack: false,
|
|
},
|
|
],
|
|
},
|
|
},
|
|
Expression {
|
|
expr: Call {
|
|
target: Identifier {
|
|
name: "define",
|
|
},
|
|
args: [
|
|
Arg {
|
|
name: None,
|
|
value: LiteralString {
|
|
value: "a",
|
|
},
|
|
unpack: false,
|
|
},
|
|
Arg {
|
|
name: None,
|
|
value: Infix {
|
|
lhs: Variable {
|
|
name: "a",
|
|
},
|
|
op: Mul,
|
|
rhs: Variable {
|
|
name: "b",
|
|
},
|
|
},
|
|
unpack: false,
|
|
},
|
|
],
|
|
},
|
|
},
|
|
Expression {
|
|
expr: Call {
|
|
target: Identifier {
|
|
name: "define",
|
|
},
|
|
args: [
|
|
Arg {
|
|
name: None,
|
|
value: LiteralString {
|
|
value: "a",
|
|
},
|
|
unpack: false,
|
|
},
|
|
Arg {
|
|
name: None,
|
|
value: Infix {
|
|
lhs: Variable {
|
|
name: "a",
|
|
},
|
|
op: RightShift,
|
|
rhs: Variable {
|
|
name: "b",
|
|
},
|
|
},
|
|
unpack: false,
|
|
},
|
|
],
|
|
},
|
|
},
|
|
Expression {
|
|
expr: Call {
|
|
target: Identifier {
|
|
name: "define",
|
|
},
|
|
args: [
|
|
Arg {
|
|
name: None,
|
|
value: LiteralString {
|
|
value: "a",
|
|
},
|
|
unpack: false,
|
|
},
|
|
Arg {
|
|
name: None,
|
|
value: Infix {
|
|
lhs: Variable {
|
|
name: "a",
|
|
},
|
|
op: LeftShift,
|
|
rhs: Variable {
|
|
name: "b",
|
|
},
|
|
},
|
|
unpack: false,
|
|
},
|
|
],
|
|
},
|
|
},
|
|
Expression {
|
|
expr: Call {
|
|
target: Identifier {
|
|
name: "define",
|
|
},
|
|
args: [
|
|
Arg {
|
|
name: None,
|
|
value: LiteralString {
|
|
value: "a",
|
|
},
|
|
unpack: false,
|
|
},
|
|
Arg {
|
|
name: None,
|
|
value: Infix {
|
|
lhs: Variable {
|
|
name: "a",
|
|
},
|
|
op: BitwiseOr,
|
|
rhs: Variable {
|
|
name: "b",
|
|
},
|
|
},
|
|
unpack: false,
|
|
},
|
|
],
|
|
},
|
|
},
|
|
Expression {
|
|
expr: Call {
|
|
target: Identifier {
|
|
name: "define",
|
|
},
|
|
args: [
|
|
Arg {
|
|
name: None,
|
|
value: LiteralString {
|
|
value: "a",
|
|
},
|
|
unpack: false,
|
|
},
|
|
Arg {
|
|
name: None,
|
|
value: Infix {
|
|
lhs: Variable {
|
|
name: "a",
|
|
},
|
|
op: BitwiseAnd,
|
|
rhs: Variable {
|
|
name: "b",
|
|
},
|
|
},
|
|
unpack: false,
|
|
},
|
|
],
|
|
},
|
|
},
|
|
Echo {
|
|
values: [
|
|
Infix {
|
|
lhs: Infix {
|
|
lhs: Variable {
|
|
name: "a",
|
|
},
|
|
op: Add,
|
|
rhs: Variable {
|
|
name: "b",
|
|
},
|
|
},
|
|
op: Mul,
|
|
rhs: Infix {
|
|
lhs: Infix {
|
|
lhs: Variable {
|
|
name: "c",
|
|
},
|
|
op: Div,
|
|
rhs: Variable {
|
|
name: "d",
|
|
},
|
|
},
|
|
op: Sub,
|
|
rhs: DynamicVariable {
|
|
name: Ternary {
|
|
condition: Infix {
|
|
lhs: LiteralString {
|
|
value: "foo",
|
|
},
|
|
op: Concat,
|
|
rhs: Variable {
|
|
name: "c",
|
|
},
|
|
},
|
|
then: Some(
|
|
LiteralInteger {
|
|
i: 4,
|
|
},
|
|
),
|
|
else: LiteralInteger {
|
|
i: 3,
|
|
},
|
|
},
|
|
},
|
|
},
|
|
},
|
|
],
|
|
},
|
|
]
|