OLD | NEW |
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
4 | 4 |
5 /** | 5 /** |
6 * Takes a parsed and composed YAML document (what the spec calls the | 6 * Takes a parsed and composed YAML document (what the spec calls the |
7 * "representation graph") and creates native Dart objects that represent that | 7 * "representation graph") and creates native Dart objects that represent that |
8 * document. | 8 * document. |
9 */ | 9 */ |
10 class _Constructor extends _Visitor { | 10 class _Constructor extends _Visitor { |
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
49 if (anchors.containsKey(anchored.anchor)) return anchors[anchored.anchor]; | 49 if (anchors.containsKey(anchored.anchor)) return anchors[anchored.anchor]; |
50 } | 50 } |
51 | 51 |
52 /** Records that [value] is the Dart object representing [anchored]. */ | 52 /** Records that [value] is the Dart object representing [anchored]. */ |
53 setAnchor(_Node anchored, value) { | 53 setAnchor(_Node anchored, value) { |
54 if (anchored.anchor == null) return value; | 54 if (anchored.anchor == null) return value; |
55 anchors[anchored.anchor] = value; | 55 anchors[anchored.anchor] = value; |
56 return value; | 56 return value; |
57 } | 57 } |
58 } | 58 } |
OLD | NEW |