| OLD | NEW |
| 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 class Interceptors { | 5 class Interceptors { |
| 6 Compiler compiler; | 6 Compiler compiler; |
| 7 Interceptors(Compiler this.compiler); | 7 Interceptors(Compiler this.compiler); |
| 8 | 8 |
| 9 SourceString mapOperatorToMethodName(Operator op) { | 9 SourceString mapOperatorToMethodName(Operator op) { |
| 10 String name = op.source.stringValue; | 10 String name = op.source.stringValue; |
| (...skipping 420 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 431 Type type = cls.computeType(builder.compiler); | 431 Type type = cls.computeType(builder.compiler); |
| 432 cachedTypeOfThis = new HBoundedType.nonNull(type); | 432 cachedTypeOfThis = new HBoundedType.nonNull(type); |
| 433 } | 433 } |
| 434 res.guaranteedType = cachedTypeOfThis; | 434 res.guaranteedType = cachedTypeOfThis; |
| 435 } | 435 } |
| 436 return res; | 436 return res; |
| 437 } | 437 } |
| 438 | 438 |
| 439 HParameterValue getActivationParameter(Element element) { | 439 HParameterValue getActivationParameter(Element element) { |
| 440 // If the element is a parameter, we already have a | 440 // If the element is a parameter, we already have a |
| 441 // HParameterValue for it. | 441 // HParameterValue for it. We cannot create another one because |
| 442 // it could then have another name than the real parameter. And |
| 443 // the other one would not not it is just a copy of the real |
| 444 // parameter. |
| 442 if (element.isParameter()) return directLocals[element]; | 445 if (element.isParameter()) return directLocals[element]; |
| 443 | 446 |
| 444 return builder.activationVariables.putIfAbsent(element, () { | 447 return builder.activationVariables.putIfAbsent(element, () { |
| 445 HParameterValue parameter = new HParameterValue(element); | 448 HParameterValue parameter = new HParameterValue(element); |
| 446 builder.graph.entry.addAtExit(parameter); | 449 builder.graph.entry.addAtExit(parameter); |
| 447 return parameter; | 450 return parameter; |
| 448 }); | 451 }); |
| 449 } | 452 } |
| 450 | 453 |
| 451 /** | 454 /** |
| (...skipping 2950 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3402 <HInstruction>[target, input], | 3405 <HInstruction>[target, input], |
| 3403 HType.STRING)); | 3406 HType.STRING)); |
| 3404 return builder.pop(); | 3407 return builder.pop(); |
| 3405 } | 3408 } |
| 3406 | 3409 |
| 3407 HInstruction result(Node node) { | 3410 HInstruction result(Node node) { |
| 3408 flushLiterals(node); | 3411 flushLiterals(node); |
| 3409 return prefix; | 3412 return prefix; |
| 3410 } | 3413 } |
| 3411 } | 3414 } |
| OLD | NEW |