[dart2js] use more facades in emitter

Change-Id: Id41ee31b20ba721ce9a8a180f94a4878d9cc4b90
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/266864
Reviewed-by: Mayank Patke <fishythefish@google.com>
This commit is contained in:
Sigmund Cherem 2022-11-01 17:51:18 +00:00 committed by Commit Queue
parent 09cd5c5699
commit dd666239ae
4 changed files with 10 additions and 3 deletions

View file

@ -69,7 +69,7 @@ import 'package:front_end/src/api_unstable/dart2js.dart'
import '../common/elements.dart' show CommonElements;
import '../elements/types.dart';
import '../js/js.dart' as js;
import '../js_emitter/code_emitter_task.dart' show Emitter;
import '../js_emitter/interfaces.dart' show Emitter;
import '../js_model/type_recipe.dart'
show
TypeRecipe,

View file

@ -26,6 +26,13 @@ abstract class NativeEmitter {
Map<ClassEntity, List<ClassEntity>> get subtypes;
Map<ClassEntity, List<ClassEntity>> get directSubtypes;
Set<FunctionEntity> get nativeMethods;
List<jsAst.Statement> generateParameterStubStatements(
FunctionEntity member,
bool isInterceptedMethod,
jsAst.Name invocationName,
List<jsAst.Parameter> stubParameters,
List<jsAst.Expression> argumentsBuffer,
int indexOfLastOptionalArgumentInParameters);
}
abstract class ModularEmitter {

View file

@ -314,6 +314,7 @@ class NativeEmitter implements interfaces.NativeEmitter {
});
}
@override
List<jsAst.Statement> generateParameterStubStatements(
FunctionEntity member,
bool isInterceptedMethod,

View file

@ -26,8 +26,7 @@ import '../world.dart' show JClosedWorld;
import 'model.dart';
import 'interfaces.dart' show Emitter;
import 'native_emitter.dart';
import 'interfaces.dart' show Emitter, NativeEmitter;
class ParameterStubGenerator {
static final Set<Selector> emptySelectorSet = {};