| Index: runtime/vm/intermediate_language.h
|
| ===================================================================
|
| --- runtime/vm/intermediate_language.h (revision 28731)
|
| +++ runtime/vm/intermediate_language.h (working copy)
|
| @@ -302,6 +302,9 @@
|
| // Create non-nullable Int type.
|
| static CompileType Int();
|
|
|
| + // Create non-nullable String type.
|
| + static CompileType String();
|
| +
|
| // Perform a join operation over the type lattice.
|
| void Union(CompileType* other);
|
|
|
| @@ -650,6 +653,7 @@
|
| M(CheckArrayBound) \
|
| M(Constraint) \
|
| M(StringFromCharCode) \
|
| + M(StringInterpolate) \
|
| M(InvokeMathCFunction) \
|
| M(GuardField) \
|
| M(IfThenElse) \
|
| @@ -3649,6 +3653,34 @@
|
| };
|
|
|
|
|
| +class StringInterpolateInstr : public TemplateDefinition<1> {
|
| + public:
|
| + StringInterpolateInstr(Value* value, intptr_t token_pos)
|
| + : token_pos_(token_pos), function_(Function::Handle()) {
|
| + SetInputAt(0, value);
|
| + }
|
| +
|
| + Value* value() const { return inputs_[0]; }
|
| + intptr_t token_pos() const { return token_pos_; }
|
| +
|
| + virtual CompileType ComputeType() const;
|
| + // Issues a static call to Dart code whihc calls toString on objects.
|
| + virtual EffectSet Effects() const { return EffectSet::All(); }
|
| + virtual bool CanDeoptimize() const { return true; }
|
| + virtual bool MayThrow() const { return true; }
|
| +
|
| + const Function& CallFunction() const;
|
| +
|
| + DECLARE_INSTRUCTION(StringInterpolate)
|
| +
|
| + private:
|
| + const intptr_t token_pos_;
|
| + Function& function_;
|
| +
|
| + DISALLOW_COPY_AND_ASSIGN(StringInterpolateInstr);
|
| +};
|
| +
|
| +
|
| class StoreIndexedInstr : public TemplateDefinition<3> {
|
| public:
|
| StoreIndexedInstr(Value* array,
|
|
|