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

Unified Diff: pkg/analyzer/lib/src/generated/sdk_io.dart

Issue 185403018: Unroll 'synchronized {}' in java2dart. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Include fix from Java Created 6 years, 10 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « pkg/analyzer/lib/src/generated/resolver.dart ('k') | pkg/analyzer/test/generated/resolver_test.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/analyzer/lib/src/generated/sdk_io.dart
diff --git a/pkg/analyzer/lib/src/generated/sdk_io.dart b/pkg/analyzer/lib/src/generated/sdk_io.dart
index 63f2f0365c9451a0b1f60c1bfc6fc600478a065b..4381adfdadac3df0158398bd53a52ae9d8f92cfa 100644
--- a/pkg/analyzer/lib/src/generated/sdk_io.dart
+++ b/pkg/analyzer/lib/src/generated/sdk_io.dart
@@ -206,12 +206,10 @@ class DirectoryBasedDartSdk implements DartSdk {
* @return the file containing the Dartium executable
*/
JavaFile get dartiumExecutable {
- {
- if (_dartiumExecutable == null) {
- JavaFile file = new JavaFile.relative(dartiumWorkingDirectory, dartiumBinaryName);
- if (file.exists()) {
- _dartiumExecutable = file;
- }
+ if (_dartiumExecutable == null) {
+ JavaFile file = new JavaFile.relative(dartiumWorkingDirectory, dartiumBinaryName);
+ if (file.exists()) {
+ _dartiumExecutable = file;
}
}
return _dartiumExecutable;
@@ -289,17 +287,15 @@ class DirectoryBasedDartSdk implements DartSdk {
* @return the revision number of this SDK
*/
String get sdkVersion {
- {
- if (_sdkVersion == null) {
- _sdkVersion = DartSdk.DEFAULT_VERSION;
- JavaFile revisionFile = new JavaFile.relative(_sdkDirectory, _REVISION_FILE_NAME);
- try {
- String revision = revisionFile.readAsStringSync();
- if (revision != null) {
- _sdkVersion = revision;
- }
- } on JavaIOException catch (exception) {
+ if (_sdkVersion == null) {
+ _sdkVersion = DartSdk.DEFAULT_VERSION;
+ JavaFile revisionFile = new JavaFile.relative(_sdkDirectory, _REVISION_FILE_NAME);
+ try {
+ String revision = revisionFile.readAsStringSync();
+ if (revision != null) {
+ _sdkVersion = revision;
}
+ } on JavaIOException catch (exception) {
}
}
return _sdkVersion;
@@ -318,12 +314,10 @@ class DirectoryBasedDartSdk implements DartSdk {
* @return the file containing the VM executable
*/
JavaFile get vmExecutable {
- {
- if (_vmExecutable == null) {
- JavaFile file = new JavaFile.relative(new JavaFile.relative(_sdkDirectory, _BIN_DIRECTORY_NAME), vmBinaryName);
- if (file.exists()) {
- _vmExecutable = file;
- }
+ if (_vmExecutable == null) {
+ JavaFile file = new JavaFile.relative(new JavaFile.relative(_sdkDirectory, _BIN_DIRECTORY_NAME), vmBinaryName);
+ if (file.exists()) {
+ _vmExecutable = file;
}
}
return _vmExecutable;
« no previous file with comments | « pkg/analyzer/lib/src/generated/resolver.dart ('k') | pkg/analyzer/test/generated/resolver_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698