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

Unified Diff: utils/css/source.dart

Issue 10919146: Get rid of a lot of () for getters. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 3 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 | « utils/archive/utils.dart ('k') | utils/css/token.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: utils/css/source.dart
diff --git a/utils/css/source.dart b/utils/css/source.dart
index 38be4a687f0222e0629dbdef6cb45ab28c0c3398..3875c7b5df571a21be363a808d103cc191811f6f 100644
--- a/utils/css/source.dart
+++ b/utils/css/source.dart
@@ -30,7 +30,7 @@ class SourceFile implements Comparable {
SourceFile(this.filename, this._text);
- String get text() => _text;
+ String get text => _text;
set text(String newText) {
if (newText != _text) {
@@ -40,7 +40,7 @@ class SourceFile implements Comparable {
}
}
- List<int> get lineStarts() {
+ List<int> get lineStarts {
if (_lineStarts == null) {
var starts = [0];
var index = 0;
@@ -145,7 +145,7 @@ class SourceSpan implements Comparable {
SourceSpan(this.file, this.start, this.end);
/** Returns the source text corresponding to this [Span]. */
- String get text() {
+ String get text {
return file.text.substring(start, end);
}
@@ -153,23 +153,23 @@ class SourceSpan implements Comparable {
return file.getLocationMessage(message, start, end: end, includeText: true);
}
- int get line() {
+ int get line {
return file.getLine(start);
}
- int get column() {
+ int get column {
return file.getColumn(line, start);
}
- int get endLine() {
+ int get endLine {
return file.getLine(end);
}
- int get endColumn() {
+ int get endColumn {
return file.getColumn(endLine, end);
}
- String get locationText() {
+ String get locationText {
var line = file.getLine(start);
var column = file.getColumn(line, start);
return '${file.filename}:${line + 1}:${column + 1}';
« no previous file with comments | « utils/archive/utils.dart ('k') | utils/css/token.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698