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

Side by Side Diff: test/codegen/opassign.dart

Issue 1988503002: Move generated files to gen/. (Closed) Base URL: https://github.com/dart-lang/dev_compiler.git@master
Patch Set: Revise. Created 4 years, 7 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
« no previous file with comments | « test/codegen/notnull.dart ('k') | test/codegen/syncstar_syntax.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 // Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file
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.
4
5 get index {
6 print('called "index" getter');
7 return 0;
8 }
9
10 final _foo = new Foo();
11 get foo {
12 print('called "foo" getter');
13 return _foo;
14 }
15
16 class Foo { int x = 100; }
17
18 main() {
19 var f = { 0: 40 };
20 print('should only call "index" 2 times:');
21 ++f[index];
22 forcePostfix(f[index]++);
23
24 print('should only call "foo" 2 times:');
25 ++foo.x;
26 forcePostfix(foo.x++);
27
28 print('op assign test, should only call "index" twice:');
29 f[index] += f[index];
30 }
31
32 // Postfix generates as prefix if the value isn't used. This method prevents it.
33 forcePostfix(x) {}
OLDNEW
« no previous file with comments | « test/codegen/notnull.dart ('k') | test/codegen/syncstar_syntax.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698