Skip to content

Commit de79a29

Browse files
authored
Run dartfmt --fix (flutter#8)
Drops optional new and const.
1 parent 9d1ad40 commit de79a29

File tree

2 files changed

+12
-12
lines changed

2 files changed

+12
-12
lines changed

lib/term_glyph.dart

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,10 @@ import 'src/generated/glyph_set.dart';
1010
import 'src/generated/unicode_glyph_set.dart';
1111

1212
/// A [GlyphSet] that always returns ASCII glyphs.
13-
const GlyphSet asciiGlyphs = const AsciiGlyphSet();
13+
const GlyphSet asciiGlyphs = AsciiGlyphSet();
1414

1515
/// A [GlyphSet] that always returns Unicode glyphs.
16-
const GlyphSet unicodeGlyphs = const UnicodeGlyphSet();
16+
const GlyphSet unicodeGlyphs = UnicodeGlyphSet();
1717

1818
/// Returns [asciiGlyphs] if [ascii] is `true` or [unicodeGlyphs] otherwise.
1919
///

tool/generate.dart

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -8,13 +8,13 @@ import 'package:csv/csv.dart';
88
import 'package:meta/meta.dart';
99

1010
void main() {
11-
var csv = new CsvCodec(eol: "\n");
12-
var data = csv.decoder.convert(new File("data.csv").readAsStringSync());
11+
var csv = CsvCodec(eol: "\n");
12+
var data = csv.decoder.convert(File("data.csv").readAsStringSync());
1313

1414
// Remove comments and empty lines.
1515
data.removeWhere((row) => row.length < 3);
1616

17-
new Directory("lib/src/generated").createSync(recursive: true);
17+
Directory("lib/src/generated").createSync(recursive: true);
1818

1919
_writeGlyphSetInterface(data);
2020
_writeGlyphSet(data, ascii: false);
@@ -29,8 +29,8 @@ void main() {
2929

3030
/// Writes `lib/src/generated/glyph_set.dart`.
3131
void _writeGlyphSetInterface(List<List> data) {
32-
var file = new File("lib/src/generated/glyph_set.dart")
33-
.openSync(mode: FileMode.write);
32+
var file =
33+
File("lib/src/generated/glyph_set.dart").openSync(mode: FileMode.write);
3434
file.writeStringSync(r"""
3535
// Copyright (c) 2018, the Dart project authors. Please see the AUTHORS file
3636
// for details. All rights reserved. Use of this source code is governed by a
@@ -84,9 +84,9 @@ void _writeGlyphSetInterface(List<List> data) {
8484
/// If [ascii] is `true`, this writes the ASCII glyph set. Otherwise it writes
8585
/// the Unicode glyph set.
8686
void _writeGlyphSet(List<List> data, {@required bool ascii}) {
87-
var file = new File(
88-
"lib/src/generated/${ascii ? "ascii" : "unicode"}_glyph_set.dart")
89-
.openSync(mode: FileMode.write);
87+
var file =
88+
File("lib/src/generated/${ascii ? "ascii" : "unicode"}_glyph_set.dart")
89+
.openSync(mode: FileMode.write);
9090

9191
var className = "${ascii ? "Ascii" : "Unicode"}GlyphSet";
9292
file.writeStringSync("""
@@ -126,8 +126,8 @@ void _writeGlyphSet(List<List> data, {@required bool ascii}) {
126126

127127
/// Writes `lib/src/generated/top_level.dart`.
128128
void _writeTopLevel(List<List> data) {
129-
var file = new File("lib/src/generated/top_level.dart")
130-
.openSync(mode: FileMode.write);
129+
var file =
130+
File("lib/src/generated/top_level.dart").openSync(mode: FileMode.write);
131131

132132
file.writeStringSync("""
133133
// Copyright (c) 2018, the Dart project authors. Please see the AUTHORS file

0 commit comments

Comments
 (0)