| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
writeNode(node.thisExpression);Consider serializing receiver before `node.name` to match other invocation nodes and keep evaluation order consistent (receiver before value/arguments).
(also for other nodes)
Expression thisExpression;Considering calling this field `receiver` to match other nodes.
(also in other nodes)
{required Expression thisExpression})Consider making this parameter the first positional parameter in order to match other nodes - receiver is usually after `kind` (if any) and before `name`.
(also in other nodes)
thisExpression: new ThisExpression(),Nit: we don't follow CFE's non-standard "always use `new`" style in pkg/vm, so `new` can be omitted.
SkipExpression(); // skip this_expression.We should serialize receiver before `value` and use it with
```
instructions += BuildExpression();
```
at L2691 instead of `LoadLocal(parsed_function()->receiver_var())`.
(also for other nodes)
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
| Code-Review | +1 |
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
Thanks for taking a look and for the comments, Alex! I need some more of your guidance in updating `runtime/vm/compiler/frontend/kernel_binary_flowgraph.cc`.
writeNode(node.thisExpression);Consider serializing receiver before `node.name` to match other invocation nodes and keep evaluation order consistent (receiver before value/arguments).
(also for other nodes)
Good suggestion! I started applying it, but encountered an issue with modifying `runtime/vm/compiler/frontend/kernel_binary_flowgraph.cc`, which I describe in the comment on that file.
Considering calling this field `receiver` to match other nodes.
(also in other nodes)
Done
Consider making this parameter the first positional parameter in order to match other nodes - receiver is usually after `kind` (if any) and before `name`.
(also in other nodes)
Done
Nit: we don't follow CFE's non-standard "always use `new`" style in pkg/vm, so `new` can be omitted.
Done
SkipExpression(); // skip this_expression.We should serialize receiver before `value` and use it with
```
instructions += BuildExpression();
```
at L2691 instead of `LoadLocal(parsed_function()->receiver_var())`.(also for other nodes)
I made an attempt to update the code as you're suggesting, but I still can't make the VM to compile. I'd appreciate any help :) I've uploaded the state I ended up in in this CL.
Additionally, for that reading order to work, `receiver` should come before `value`, but after `name`, which contradicts the desire to put `receiver` before the `name` for uniformity with other invocation nodes.
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
SkipExpression(); // skip this_expression.Chloe StefantsovaWe should serialize receiver before `value` and use it with
```
instructions += BuildExpression();
```
at L2691 instead of `LoadLocal(parsed_function()->receiver_var())`.(also for other nodes)
I made an attempt to update the code as you're suggesting, but I still can't make the VM to compile. I'd appreciate any help :) I've uploaded the state I ended up in in this CL.
Additionally, for that reading order to work, `receiver` should come before `value`, but after `name`, which contradicts the desire to put `receiver` before the `name` for uniformity with other invocation nodes.
It turned out to be a bit more involved, but I think I figured that out. I uploaded a patchset with the necessary changes to this CL. (We might need to find another reviewer for the VM changes as I cannot approve my own changes.)
Maybe having a `name` before `receiver` could simplify VM's code a bit, but I think we should do this consistently on all invocation nodes if we decide it is worth doing (and separately from this CL).
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
I also added missing traversal of receiver nodes in visitors and setting parent pointers. There are still some front-end test failures, but all other bots are green.
writeNode(node.thisExpression);Consider serializing receiver before `node.name` to match other invocation nodes and keep evaluation order consistent (receiver before value/arguments).
Chloe Stefantsova(also for other nodes)
Alexander MarkovGood suggestion! I started applying it, but encountered an issue with modifying `runtime/vm/compiler/frontend/kernel_binary_flowgraph.cc`, which I describe in the comment on that file.
Done
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |