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

Unified Diff: pkg/analyzer/lib/src/summary/base.dart

Issue 1691923002: Make summary format stable when adding getters to idl. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 4 years, 10 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
« no previous file with comments | « no previous file | pkg/analyzer/lib/src/summary/format.dart » ('j') | pkg/analyzer/lib/src/summary/idl.dart » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/analyzer/lib/src/summary/base.dart
diff --git a/pkg/analyzer/lib/src/summary/base.dart b/pkg/analyzer/lib/src/summary/base.dart
index a04476bcab54e72ff300c47afdff564dd138bdbe..c4a4cdb8a6aeac9b622bd2099f44e0842a69574a 100644
--- a/pkg/analyzer/lib/src/summary/base.dart
+++ b/pkg/analyzer/lib/src/summary/base.dart
@@ -8,6 +8,21 @@
library analyzer.src.summary.base;
/**
+ * Annotation used in the summary IDL to indicate the id of a field. The set
+ * of ids used by a class must cover the contiguous range from 0 to N-1, where
+ * N is the number of fields.
+ *
+ * In order to preserve forwards and backwards compatibility, id numbers must
+ * be stable between releases. So when new fields are added they should take
+ * the next available id without renumbering other fields.
+ */
+class Id {
+ final int value;
+
+ const Id(this.value);
+}
+
+/**
* Instances of this class represent data that has been read from a summary.
*/
abstract class SummaryClass {
« no previous file with comments | « no previous file | pkg/analyzer/lib/src/summary/format.dart » ('j') | pkg/analyzer/lib/src/summary/idl.dart » ('J')

Powered by Google App Engine
This is Rietveld 408576698