| Index: pkg/compiler/lib/src/ssa/kernel_ast_adapter.dart
|
| diff --git a/pkg/compiler/lib/src/ssa/kernel_ast_adapter.dart b/pkg/compiler/lib/src/ssa/kernel_ast_adapter.dart
|
| index e43efdfe44bea5399e9627cff5e5083aabd86f7e..ae0f6b90d2e6987e26cb5a797b43edc9b567335a 100644
|
| --- a/pkg/compiler/lib/src/ssa/kernel_ast_adapter.dart
|
| +++ b/pkg/compiler/lib/src/ssa/kernel_ast_adapter.dart
|
| @@ -588,30 +588,35 @@ class KernelAstAdapter extends KernelElementAdapterMixin {
|
| return cls.thisType;
|
| }
|
|
|
| + native.BehaviorBuilder get nativeBehaviorBuilder =>
|
| + new native.ResolverBehaviorBuilder(_compiler);
|
| +
|
| /// Computes the native behavior for reading the native [field].
|
| // TODO(johnniwinther): Cache this for later use.
|
| native.NativeBehavior getNativeBehaviorForFieldLoad(ir.Field field) {
|
| ResolutionDartType type = getDartType(field.type);
|
| List<ConstantExpression> metadata = getMetadata(field.annotations);
|
| - return native.NativeBehavior.ofFieldLoad(CURRENT_ELEMENT_SPANNABLE, type,
|
| - metadata, typeLookup(resolveAsRaw: false), _compiler,
|
| + // TODO(johnniwinther): Provide the correct value for [isJsInterop].
|
| + return nativeBehaviorBuilder.buildFieldLoadBehavior(
|
| + type, metadata, typeLookup(resolveAsRaw: false),
|
| isJsInterop: false);
|
| }
|
|
|
| /// Computes the native behavior for writing to the native [field].
|
| // TODO(johnniwinther): Cache this for later use.
|
| native.NativeBehavior getNativeBehaviorForFieldStore(ir.Field field) {
|
| - ResolutionDartType type = getDartType(field.type);
|
| - return native.NativeBehavior.ofFieldStore(type, _compiler.resolution);
|
| + DartType type = getDartType(field.type);
|
| + return nativeBehaviorBuilder.buildFieldStoreBehavior(type);
|
| }
|
|
|
| /// Computes the native behavior for calling [procedure].
|
| // TODO(johnniwinther): Cache this for later use.
|
| native.NativeBehavior getNativeBehaviorForMethod(ir.Procedure procedure) {
|
| - ResolutionDartType type = getFunctionType(procedure.function);
|
| + DartType type = getFunctionType(procedure.function);
|
| List<ConstantExpression> metadata = getMetadata(procedure.annotations);
|
| - return native.NativeBehavior.ofMethod(CURRENT_ELEMENT_SPANNABLE, type,
|
| - metadata, typeLookup(resolveAsRaw: false), _compiler,
|
| + // TODO(johnniwinther): Provide the correct value for [isJsInterop].
|
| + return nativeBehaviorBuilder.buildMethodBehavior(
|
| + type, metadata, typeLookup(resolveAsRaw: false),
|
| isJsInterop: false);
|
| }
|
|
|
|
|