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

Unified Diff: lib/static.dart

Issue 1016913002: pkg/smoke: support latest analyzer version and formatted code (Closed) Base URL: https://github.com/dart-lang/smoke@master
Patch Set: updates Created 5 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
« no previous file with comments | « lib/src/implementation.dart ('k') | lib/static_debug.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: lib/static.dart
diff --git a/lib/static.dart b/lib/static.dart
index 8c840e5b7a4271f91490a553f14545e525591345..d31f369d0266d30e2ce0fe535884d330f25ec906 100644
--- a/lib/static.dart
+++ b/lib/static.dart
@@ -39,18 +39,13 @@ class StaticConfiguration {
/// A map from strings to symbols (the reverse of [names]).
final Map<String, Symbol> _symbols = {};
-
/// Whether to check for missing declarations, otherwise, return default
/// values (for example a missing parent class can be treated as Object)
final bool checkedMode;
- StaticConfiguration({
- Map<Symbol, Getter> getters,
- Map<Symbol, Setter> setters,
- Map<Type, Type> parents,
- Map<Type, Map<Symbol, Declaration>> declarations,
- Map<Type, Map<Symbol, Function>> staticMethods,
- Map<Symbol, String> names,
+ StaticConfiguration({Map<Symbol, Getter> getters, Map<Symbol, Setter> setters,
+ Map<Type, Type> parents, Map<Type, Map<Symbol, Declaration>> declarations,
+ Map<Type, Map<Symbol, Function>> staticMethods, Map<Symbol, String> names,
this.checkedMode: true})
: getters = getters != null ? getters : {},
setters = setters != null ? setters : {},
@@ -58,7 +53,9 @@ class StaticConfiguration {
declarations = declarations != null ? declarations : {},
staticMethods = staticMethods != null ? staticMethods : {},
names = names != null ? names : {} {
- this.names.forEach((k, v) { _symbols[v] = k; });
+ this.names.forEach((k, v) {
+ _symbols[v] = k;
+ });
}
void addAll(StaticConfiguration other) {
@@ -68,7 +65,9 @@ class StaticConfiguration {
_nestedAddAll(declarations, other.declarations);
_nestedAddAll(staticMethods, other.staticMethods);
names.addAll(other.names);
- other.names.forEach((k, v) { _symbols[v] = k; });
+ other.names.forEach((k, v) {
+ _symbols[v] = k;
+ });
}
static _nestedAddAll(Map a, Map b) {
@@ -279,7 +278,6 @@ class GeneratedSymbolConverterService implements SymbolConverterService {
Symbol nameToSymbol(String name) => _symbols[name];
}
-
/// Exception thrown when trynig to access something that should be there, but
/// the code generator didn't include it.
class MissingCodeException implements Exception {
« no previous file with comments | « lib/src/implementation.dart ('k') | lib/static_debug.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698