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

Side by Side Diff: frog/value.dart

Issue 9222015: fix break in r3504 (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: gen minfrog Created 8 years, 11 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « frog/tests/frog/frog.status ('k') | tests/language/language.status » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 interface CallingContext { 6 interface CallingContext {
7 MemberSet findMembers(String name); 7 MemberSet findMembers(String name);
8 CounterLog get counters(); 8 CounterLog get counters();
9 Library get library(); 9 Library get library();
10 bool get isStatic(); 10 bool get isStatic();
(...skipping 26 matching lines...) Expand all
37 // TODO(jimhug): Can we remove span? 37 // TODO(jimhug): Can we remove span?
38 PureStaticValue(Type type, SourceSpan span, 38 PureStaticValue(Type type, SourceSpan span,
39 [this.isConst = false, this.isType = false]): 39 [this.isConst = false, this.isType = false]):
40 super(type, null, span); 40 super(type, null, span);
41 41
42 Member getMem(CallingContext context, String name, Node node) { 42 Member getMem(CallingContext context, String name, Node node) {
43 var member = type.getMember(name); 43 var member = type.getMember(name);
44 44
45 if (member == null) { 45 if (member == null) {
46 world.warning('can not find "$name" on "${type.name}"', node.span); 46 world.warning('can not find "$name" on "${type.name}"', node.span);
47 return null;
47 } 48 }
48 49
49 if (isType && !member.isStatic) { 50 if (isType && !member.isStatic) {
50 world.error('can not refer to instance member as static', node.span); 51 world.error('can not refer to instance member as static', node.span);
51 } 52 }
52 53
53 return member; 54 return member;
54 } 55 }
55 56
56 Value get_(CallingContext context, String name, Node node) { 57 Value get_(CallingContext context, String name, Node node) {
(...skipping 1554 matching lines...) Expand 10 before | Expand all | Expand 10 after
1611 } 1612 }
1612 return super.unop(kind, context, node); 1613 return super.unop(kind, context, node);
1613 } 1614 }
1614 Value binop(int kind, var other, CallingContext context, var node) { 1615 Value binop(int kind, var other, CallingContext context, var node) {
1615 if (value != null) { 1616 if (value != null) {
1616 return replaceValue(value.binop(kind, _unwrap(other), context, node)); 1617 return replaceValue(value.binop(kind, _unwrap(other), context, node));
1617 } 1618 }
1618 return super.binop(kind, other, context, node); 1619 return super.binop(kind, other, context, node);
1619 } 1620 }
1620 } 1621 }
OLDNEW
« no previous file with comments | « frog/tests/frog/frog.status ('k') | tests/language/language.status » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698