Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(273)

Unified Diff: pkg/kernel/lib/binary/ast_to_binary.dart

Issue 2767773004: Add Vector type to Kernel (Closed)
Patch Set: Add a note to return Run step in Closure Conversion test suite Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: pkg/kernel/lib/binary/ast_to_binary.dart
diff --git a/pkg/kernel/lib/binary/ast_to_binary.dart b/pkg/kernel/lib/binary/ast_to_binary.dart
index 918283f11bdbc6d2f9fa5c4bf28dbacfa72aaf07..6135c007a1f2f6980d617ac65618cfd0768f7bd9 100644
--- a/pkg/kernel/lib/binary/ast_to_binary.dart
+++ b/pkg/kernel/lib/binary/ast_to_binary.dart
@@ -741,6 +741,29 @@ class BinaryPrinter extends Visitor {
writeDeferredImportReference(node.import);
}
+ visitVectorCreation(VectorCreation node) {
+ writeByte(Tag.VectorCreation);
+ writeNode(node.length);
+ }
+
+ visitVectorGet(VectorGet node) {
+ writeByte(Tag.VectorGet);
+ writeNode(node.vectorExpression);
+ writeNode(node.index);
+ }
+
+ visitVectorSet(VectorSet node) {
+ writeByte(Tag.VectorSet);
+ writeNode(node.vectorExpression);
+ writeNode(node.index);
+ writeNode(node.value);
+ }
+
+ visitVectorCopy(VectorCopy node) {
+ writeByte(Tag.VectorCopy);
+ writeNode(node.vectorExpression);
+ }
+
writeStatementOrEmpty(Statement node) {
if (node == null) {
writeByte(Tag.EmptyStatement);
@@ -988,6 +1011,10 @@ class BinaryPrinter extends Visitor {
writeUInt30(_typeParameterIndexer[node.parameter]);
}
+ visitVectorType(VectorType node) {
+ writeByte(Tag.VectorType);
+ }
+
visitTypeParameter(TypeParameter node) {
writeStringReference(node.name ?? '');
writeNode(node.bound);

Powered by Google App Engine
This is Rietveld 408576698