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

Side by Side Diff: tests/language_strong/constructor_duplicate_initializers_test.dart

Issue 2763823002: Move spaces from before comments to within comments (Closed)
Patch Set: Fix comments Created 3 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 unified diff | Download patch
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 // Check that initializers are not duplicated 4 // Check that initializers are not duplicated
5 5
6 6
7 class Class { 7 class Class {
8 Class(var v) 8 Class(var v)
9 : field_ = v 9 : field_ = v
10 // Test against duplicate final field initializaion in initializing list. 10 // Test against duplicate final field initializaion in initializing list.
11 , field_ = 2 /// 01: compile-time error 11 , field_ = 2 // /// 01: compile-time error
12 ; 12 ;
13 Class.field(this.field_) 13 Class.field(this.field_)
14 // Test against duplicate final field initialization between initializing 14 // Test against duplicate final field initialization between initializing
15 // formals and initializer list. 15 // formals and initializer list.
16 : field_ = 2 /// 02: compile-time error 16 : field_ = 2 // /// 02: compile-time error
17 ; 17 ;
18 // Test against duplicate final field initialization in initializing formals. 18 // Test against duplicate final field initialization in initializing formals.
19 Class.two_fields(this.field_ 19 Class.two_fields(this.field_
20 , this.field_ /// 03: compile-time error 20 , this.field_ /// 03: compile-time error
21 ); 21 );
22 final field_; 22 final field_;
23 } 23 }
24 24
25 main() { 25 main() {
26 new Class(42); 26 new Class(42);
27 new Class.field(42); 27 new Class.field(42);
28 new Class.two_fields(42 28 new Class.two_fields(42
29 , 42 /// 03: continued 29 , 42 // /// 03: continued
30 ); 30 );
31 } 31 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698