Created
March 26, 2012 07:33
-
-
Save adam-singer/2203703 to your computer and use it in GitHub Desktop.
Dartium reports error on try catch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#import('dart:html'); | |
/* | |
Internal error: 'file:///Users/adam/Documents/DartEditor/dart/dart-sdk/lib/frog/file_system_dom.dart': Error: line 40 pos 15: type 'e' is not loaded | |
} catch(e) { | |
^ | |
$ diff file_system_dom.dart file_system_dom.dart.original | |
40c40 | |
< } catch(var e) { | |
--- | |
> } catch(e) { | |
*/ | |
#import('/Users/adam/Documents/DartEditor/dart/dart-sdk/lib/frog/file_system_dom.dart'); | |
class frogTest { | |
frogTest() { | |
} | |
void run() { | |
write("Hello World!"); | |
DomFileSystem fileSystem = new DomFileSystem("/"); | |
fileSystem.writeString("/mySourceFile.dart", "main() {print('hello');}"); | |
write(fileSystem.readAll("/mySourceFile.dart")); | |
write("Good bye world!"); | |
} | |
void write(String message) { | |
// the HTML library defines a global "document" variable | |
document.query('#status').innerHTML = "${document.query('#status').innerHTML}<br/> ${message}"; | |
} | |
} | |
void main() { | |
new frogTest().run(); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html> | |
<head> | |
<title>frogTest</title> | |
</head> | |
<body> | |
<h1>frogTest</h1> | |
<h2 id="status"></h2> | |
<script type="application/dart" src="frogTest.dart"></script> | |
<script src="http://dart.googlecode.com/svn/branches/bleeding_edge/dart/client/dart.js"></script> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment