mirror of
https://github.com/dart-lang/sdk
synced 2024-10-14 09:01:42 +00:00
2d12821cba
Change-Id: I762538437b8f68f20c149b737cbe65f212c5c3b5 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/142370 Commit-Queue: Johnni Winther <johnniwinther@google.com> Reviewed-by: Lasse R.H. Nielsen <lrn@google.com>
16 lines
564 B
Dart
16 lines
564 B
Dart
// Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
|
|
// for details. All rights reserved. Use of this source code is governed by a
|
|
// BSD-style license that can be found in the LICENSE file.
|
|
|
|
library dart.test.symbol_map_helper;
|
|
|
|
// TODO(ahe): Update map literals to avoid this method.
|
|
Map<Symbol, dynamic>? symbolToStringMap(Map<String, dynamic> map) {
|
|
if (map == null) return null;
|
|
Map<Symbol, dynamic> result = new Map<Symbol, dynamic>();
|
|
map.forEach((name, value) {
|
|
result[new Symbol(name)] = value;
|
|
});
|
|
return result;
|
|
}
|