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

Side by Side Diff: tests/language/function_test.dart

Issue 10871071: - Change "static final" to "static const" in the tests/ directory. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 8 years, 3 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 | « tests/language/final_syntax_test.dart ('k') | tests/language/inst_field_initializer_test.dart » ('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) 2011, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2011, 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 // Tests function statements and expressions. 5 // Tests function statements and expressions.
6 6
7 class Bug4089219 { 7 class Bug4089219 {
8 int x; 8 int x;
9 var f; 9 var f;
10 10
11 Bug4089219(int i) : this.x = i { 11 Bug4089219(int i) : this.x = i {
12 f = () => x; 12 f = () => x;
13 } 13 }
14 } 14 }
15 15
16 class Bug4342163 { 16 class Bug4342163 {
17 final m; 17 final m;
18 Bug4342163(int a) : this.m = (() => a) {} 18 Bug4342163(int a) : this.m = (() => a) {}
19 } 19 }
20 20
21 class StaticFunctionDef { 21 class StaticFunctionDef {
22 static final int one = 1; 22 static const int one = 1;
23 static var fn1; 23 static var fn1;
24 static var fn2; 24 static var fn2;
25 static var fn3; 25 static var fn3;
26 26
27 static init() { 27 static init() {
28 fn1 = () { return one; }; 28 fn1 = () { return one; };
29 fn2 = () { return (() { return one; })(); }; 29 fn2 = () { return (() { return one; })(); };
30 fn3 = () { 30 fn3 = () {
31 final local = 1; 31 final local = 1;
32 return (() { return local; })(); 32 return (() { return local; })();
(...skipping 316 matching lines...) Expand 10 before | Expand all | Expand 10 after
349 fooIntString = foo; 349 fooIntString = foo;
350 350
351 uf = uf2; 351 uf = uf2;
352 uf2 = uf; 352 uf2 = uf;
353 } 353 }
354 } 354 }
355 355
356 main() { 356 main() {
357 FunctionTest.testMain(); 357 FunctionTest.testMain();
358 } 358 }
OLDNEW
« no previous file with comments | « tests/language/final_syntax_test.dart ('k') | tests/language/inst_field_initializer_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698