OLD | NEW |
---|---|
1 dart_library.library('notnull', null, /* Imports */[ | 1 dart_library.library('notnull', null, /* Imports */[ |
2 'dart_sdk' | 2 'dart_sdk' |
3 ], function(exports, dart_sdk) { | 3 ], function(exports, dart_sdk) { |
4 'use strict'; | 4 'use strict'; |
5 const core = dart_sdk.core; | 5 const core = dart_sdk.core; |
6 const dart = dart_sdk.dart; | 6 const dart = dart_sdk.dart; |
7 const dartx = dart_sdk.dartx; | 7 const dartx = dart_sdk.dartx; |
8 const notnull = Object.create(null); | 8 const notnull = Object.create(null); |
9 notnull.intAssignments = function() { | 9 notnull.intAssignments = function() { |
10 let i = 0; | 10 let i = 0; |
(...skipping 137 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
148 s = s; | 148 s = s; |
149 core.print(s + 1); | 149 core.print(s + 1); |
150 }; | 150 }; |
151 dart.fn(notnull.nonNullableCycle, dart.void, []); | 151 dart.fn(notnull.nonNullableCycle, dart.void, []); |
152 notnull.Foo = class Foo extends core.Object { | 152 notnull.Foo = class Foo extends core.Object { |
153 Foo() { | 153 Foo() { |
154 this.intField = null; | 154 this.intField = null; |
155 this.varField = null; | 155 this.varField = null; |
156 } | 156 } |
157 f(o) { | 157 f(o) { |
158 core.print(1 + dart.notNull(dart.as(this.varField, core.num)) + 2); | 158 core.print(1 + dart.asNotNull(this.varField, core.num) + 2); |
Jennifer Messerly
2016/05/10 23:42:12
`num` and `String` are a couple of other ones I wa
| |
159 while (dart.notNull(dart.as(dart.dsend(this.varField, '<', 10), core.bool) )) { | 159 while (dart.test(dart.dsend(this.varField, '<', 10))) { |
160 this.varField = dart.dsend(this.varField, '+', 1); | 160 this.varField = dart.dsend(this.varField, '+', 1); |
161 } | 161 } |
162 while (dart.notNull(dart.as(dart.dsend(this.varField, '<', 10), core.bool) )) | 162 while (dart.test(dart.dsend(this.varField, '<', 10))) |
163 this.varField = dart.dsend(this.varField, '+', 1); | 163 this.varField = dart.dsend(this.varField, '+', 1); |
164 core.print(1 + dart.notNull(this.intField) + 2); | 164 core.print(1 + dart.notNull(this.intField) + 2); |
165 while (dart.notNull(this.intField) < 10) { | 165 while (dart.notNull(this.intField) < 10) { |
166 this.intField = dart.notNull(this.intField) + 1; | 166 this.intField = dart.notNull(this.intField) + 1; |
167 } | 167 } |
168 while (dart.notNull(this.intField) < 10) | 168 while (dart.notNull(this.intField) < 10) |
169 this.intField = dart.notNull(this.intField) + 1; | 169 this.intField = dart.notNull(this.intField) + 1; |
170 core.print(1 + dart.notNull(o.intField) + 2); | 170 core.print(1 + dart.notNull(o.intField) + 2); |
171 while (dart.notNull(o.intField) < 10) { | 171 while (dart.notNull(o.intField) < 10) { |
172 o.intField = dart.notNull(o.intField) + 1; | 172 o.intField = dart.notNull(o.intField) + 1; |
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
254 notnull.localEscapes(); | 254 notnull.localEscapes(); |
255 notnull.controlFlow(); | 255 notnull.controlFlow(); |
256 notnull.cascadesOnNull(); | 256 notnull.cascadesOnNull(); |
257 notnull.nullableCycle(); | 257 notnull.nullableCycle(); |
258 notnull.nonNullableCycle(); | 258 notnull.nonNullableCycle(); |
259 }; | 259 }; |
260 dart.fn(notnull.main); | 260 dart.fn(notnull.main); |
261 // Exports: | 261 // Exports: |
262 exports.notnull = notnull; | 262 exports.notnull = notnull; |
263 }); | 263 }); |
OLD | NEW |