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

Side by Side Diff: sdk/lib/_internal/js_runtime/lib/js_helper.dart

Issue 2896393003: Remove factory body in *.fromEnvironment, and implement this same behavior (Closed)
Patch Set: turn warning into a hint Created 3 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
OLDNEW
1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2013, 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 library _js_helper; 5 library _js_helper;
6 6
7 import 'dart:_js_embedded_names' 7 import 'dart:_js_embedded_names'
8 show 8 show
9 DEFERRED_LIBRARY_URIS, 9 DEFERRED_LIBRARY_URIS,
10 DEFERRED_LIBRARY_HASHES, 10 DEFERRED_LIBRARY_HASHES,
(...skipping 1793 matching lines...) Expand 10 before | Expand all | Expand 10 after
1804 * expression context. 1804 * expression context.
1805 */ 1805 */
1806 throwExpression(ex) { 1806 throwExpression(ex) {
1807 JS('void', 'throw #', wrapException(ex)); 1807 JS('void', 'throw #', wrapException(ex));
1808 } 1808 }
1809 1809
1810 throwRuntimeError(message) { 1810 throwRuntimeError(message) {
1811 throw new RuntimeError(message); 1811 throw new RuntimeError(message);
1812 } 1812 }
1813 1813
1814 throwUnsupportedError(message) {
1815 throw new UnsupportedError(message);
1816 }
1817
1814 throwAbstractClassInstantiationError(className) { 1818 throwAbstractClassInstantiationError(className) {
1815 throw new AbstractClassInstantiationError(className); 1819 throw new AbstractClassInstantiationError(className);
1816 } 1820 }
1817 1821
1818 // This is used in open coded for-in loops on arrays. 1822 // This is used in open coded for-in loops on arrays.
1819 // 1823 //
1820 // checkConcurrentModificationError(a.length == startLength, a) 1824 // checkConcurrentModificationError(a.length == startLength, a)
1821 // 1825 //
1822 // is replaced in codegen by: 1826 // is replaced in codegen by:
1823 // 1827 //
(...skipping 1977 matching lines...) Expand 10 before | Expand all | Expand 10 after
3801 // unneeded code. 3805 // unneeded code.
3802 class _UnreachableError extends AssertionError { 3806 class _UnreachableError extends AssertionError {
3803 _UnreachableError(); 3807 _UnreachableError();
3804 String toString() => "Assertion failed: Reached dead code"; 3808 String toString() => "Assertion failed: Reached dead code";
3805 } 3809 }
3806 3810
3807 @NoInline() 3811 @NoInline()
3808 void assertUnreachable() { 3812 void assertUnreachable() {
3809 throw new _UnreachableError(); 3813 throw new _UnreachableError();
3810 } 3814 }
OLDNEW
« no previous file with comments | « sdk/lib/_internal/js_runtime/lib/core_patch.dart ('k') | tests/compiler/dart2js/mock_libraries.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698