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

Issue 1829573002: Fix all strong mode warnings in protoc-plugin (Closed)

Created:
4 years, 9 months ago by skybrian
Modified:
4 years, 8 months ago
Reviewers:
vsm, Leaf, Søren Gjesse
CC:
reviews_dartlang.org, Søren Gjesse
Base URL:
git@github.com:dart-lang/dart-protoc-plugin.git@master
Target Ref:
refs/heads/master
Visibility:
Public.

Description

Fix all strong mode warnings in protoc-plugin Includes changes to the plugin, the generated code, the benchmarks, and the tests. Also, fix the benchmarks to work again. It has a hacky parser for .pubspec-lock files that didn't work after the format changed. Also, dartfmt modified files. Committed: https://github.com/dart-lang/dart-protoc-plugin/commit/23a67b48fc1ad532e7786345ce8b7b3adebd8f14

Patch Set 1 #

Total comments: 25

Patch Set 2 : post review updates #

Patch Set 3 : sync to head #

Total comments: 7

Patch Set 4 : remove type declaration from getters #

Patch Set 5 : regenerate pb.dart files #

Unified diffs Side-by-side diffs Delta from patch set Stats (+1677 lines, -941 lines) Patch
A .analysis_options View 1 chunk +2 lines, -0 lines 0 comments Download
M benchmark/lib/benchmarks/get_strings.dart View 2 chunks +1 line, -2 lines 0 comments Download
M benchmark/lib/benchmarks/has_strings.dart View 1 chunk +1 line, -1 line 0 comments Download
M benchmark/lib/benchmarks/int32_json.dart View 2 chunks +3 lines, -2 lines 0 comments Download
M benchmark/lib/benchmarks/int64_json.dart View 2 chunks +3 lines, -2 lines 0 comments Download
M benchmark/lib/benchmarks/repeated_int32_json.dart View 2 chunks +3 lines, -2 lines 0 comments Download
M benchmark/lib/benchmarks/repeated_int64_json.dart View 2 chunks +3 lines, -2 lines 0 comments Download
M benchmark/lib/benchmarks/repeated_string_json.dart View 1 chunk +1 line, -1 line 0 comments Download
M benchmark/lib/benchmarks/set_strings.dart View 1 chunk +1 line, -1 line 0 comments Download
M benchmark/lib/benchmarks/string_json.dart View 1 chunk +1 line, -1 line 0 comments Download
M benchmark/lib/dashboard_model.dart View 2 chunks +5 lines, -5 lines 0 comments Download
M benchmark/lib/dashboard_view.dart View 1 4 chunks +5 lines, -5 lines 0 comments Download
M bin/protoc_plugin_bazel.dart View 1 chunk +1 line, -1 line 0 comments Download
M lib/const_generator.dart View 1 chunk +2 lines, -2 lines 0 comments Download
M lib/enum_generator.dart View 3 chunks +18 lines, -19 lines 0 comments Download
M lib/extension_generator.dart View 1 2 chunks +8 lines, -11 lines 0 comments Download
M lib/file_generator.dart View 1 8 chunks +17 lines, -20 lines 0 comments Download
M lib/message_generator.dart View 1 2 3 10 chunks +73 lines, -40 lines 0 comments Download
M lib/options.dart View 1 4 chunks +10 lines, -10 lines 0 comments Download
M lib/protobuf_field.dart View 1 2 chunks +18 lines, -17 lines 0 comments Download
M lib/src/descriptor.pb.dart View 1 2 3 4 40 chunks +333 lines, -332 lines 0 comments Download
M lib/src/plugin.pb.dart View 1 2 3 4 5 chunks +26 lines, -26 lines 0 comments Download
M pubspec.yaml View 1 1 chunk +2 lines, -2 lines 0 comments Download
M test/bazel_test.dart View 2 chunks +2 lines, -2 lines 0 comments Download
M test/enum_generator_test.dart View 2 chunks +17 lines, -16 lines 0 comments Download
M test/file_generator_test.dart View 1 2 3 10 chunks +114 lines, -117 lines 0 comments Download
M test/generated_message_test.dart View 12 chunks +756 lines, -129 lines 0 comments Download
M test/message_generator_test.dart View 1 2 3 3 chunks +43 lines, -42 lines 0 comments Download
M test/message_test.dart View 6 chunks +77 lines, -75 lines 0 comments Download
M test/service_test.dart View 1 chunk +2 lines, -2 lines 0 comments Download
M test/validate_fail_test.dart View 2 chunks +129 lines, -54 lines 0 comments Download

Messages

Total messages: 29 (6 generated)
skybrian
4 years, 9 months ago (2016-03-23 02:43:31 UTC) #4
vsm
https://chromiumcodereview.appspot.com/1829573002/diff/1/benchmark/lib/dashboard_model.dart File benchmark/lib/dashboard_model.dart (right): https://chromiumcodereview.appspot.com/1829573002/diff/1/benchmark/lib/dashboard_model.dart#newcode47 benchmark/lib/dashboard_model.dart:47: Iterator it = report == null ? [].iterator : ...
4 years, 9 months ago (2016-03-23 17:20:24 UTC) #6
skybrian
Thanks, looks like this is going to take more work. I'll get back to this ...
4 years, 9 months ago (2016-03-23 18:02:39 UTC) #7
Leaf
https://chromiumcodereview.appspot.com/1829573002/diff/1/benchmark/lib/dashboard_model.dart File benchmark/lib/dashboard_model.dart (right): https://chromiumcodereview.appspot.com/1829573002/diff/1/benchmark/lib/dashboard_model.dart#newcode47 benchmark/lib/dashboard_model.dart:47: Iterator it = report == null ? [].iterator : ...
4 years, 9 months ago (2016-03-23 18:10:00 UTC) #8
skybrian
Apparently fixing analyzer warnings and running tests isn't enough to verify that strong mode works. ...
4 years, 9 months ago (2016-03-23 18:34:17 UTC) #9
vsm
On 2016/03/23 18:34:17, skybrian wrote: > Apparently fixing analyzer warnings and running tests isn't enough ...
4 years, 9 months ago (2016-03-23 19:30:33 UTC) #10
vsm
On 2016/03/23 19:30:33, vsm wrote: > On 2016/03/23 18:34:17, skybrian wrote: > > Apparently fixing ...
4 years, 9 months ago (2016-03-23 19:34:22 UTC) #11
Søren Gjesse
dbc. https://chromiumcodereview.appspot.com/1829573002/diff/1/lib/file_generator.dart File lib/file_generator.dart (right): https://chromiumcodereview.appspot.com/1829573002/diff/1/lib/file_generator.dart#newcode123 lib/file_generator.dart:123: throw ("FAILURE: File with an absolute path is ...
4 years, 8 months ago (2016-03-29 09:04:13 UTC) #13
skybrian
Updated. This now depends on some more changes to dart protobuf [1]. I bumped the ...
4 years, 8 months ago (2016-04-01 02:00:15 UTC) #14
Leaf
https://chromiumcodereview.appspot.com/1829573002/diff/1/benchmark/lib/dashboard_model.dart File benchmark/lib/dashboard_model.dart (right): https://chromiumcodereview.appspot.com/1829573002/diff/1/benchmark/lib/dashboard_model.dart#newcode47 benchmark/lib/dashboard_model.dart:47: Iterator it = report == null ? [].iterator : ...
4 years, 8 months ago (2016-04-01 18:13:52 UTC) #15
skybrian
https://chromiumcodereview.appspot.com/1829573002/diff/40001/lib/src/descriptor.pb.dart File lib/src/descriptor.pb.dart (right): https://chromiumcodereview.appspot.com/1829573002/diff/40001/lib/src/descriptor.pb.dart#newcode66 lib/src/descriptor.pb.dart:66: String get name => $_get/*<String>*/(0, 1, ''); On 2016/04/01 ...
4 years, 8 months ago (2016-04-01 19:47:48 UTC) #16
Leaf
https://chromiumcodereview.appspot.com/1829573002/diff/40001/lib/src/descriptor.pb.dart File lib/src/descriptor.pb.dart (right): https://chromiumcodereview.appspot.com/1829573002/diff/40001/lib/src/descriptor.pb.dart#newcode66 lib/src/descriptor.pb.dart:66: String get name => $_get/*<String>*/(0, 1, ''); On 2016/04/01 ...
4 years, 8 months ago (2016-04-01 19:57:22 UTC) #17
skybrian
https://chromiumcodereview.appspot.com/1829573002/diff/40001/lib/src/descriptor.pb.dart File lib/src/descriptor.pb.dart (right): https://chromiumcodereview.appspot.com/1829573002/diff/40001/lib/src/descriptor.pb.dart#newcode66 lib/src/descriptor.pb.dart:66: String get name => $_get/*<String>*/(0, 1, ''); On 2016/04/01 ...
4 years, 8 months ago (2016-04-01 20:11:45 UTC) #18
Leaf
https://chromiumcodereview.appspot.com/1829573002/diff/40001/lib/src/descriptor.pb.dart File lib/src/descriptor.pb.dart (right): https://chromiumcodereview.appspot.com/1829573002/diff/40001/lib/src/descriptor.pb.dart#newcode66 lib/src/descriptor.pb.dart:66: String get name => $_get/*<String>*/(0, 1, ''); On 2016/04/01 ...
4 years, 8 months ago (2016-04-01 20:22:18 UTC) #19
skybrian
On 2016/04/01 20:22:18, Leaf wrote: > https://chromiumcodereview.appspot.com/1829573002/diff/40001/lib/src/descriptor.pb.dart > File lib/src/descriptor.pb.dart (right): > > https://chromiumcodereview.appspot.com/1829573002/diff/40001/lib/src/descriptor.pb.dart#newcode66 > ...
4 years, 8 months ago (2016-04-01 20:35:03 UTC) #20
skybrian
On 2016/04/01 20:35:03, skybrian wrote: > On 2016/04/01 20:22:18, Leaf wrote: > > > https://chromiumcodereview.appspot.com/1829573002/diff/40001/lib/src/descriptor.pb.dart ...
4 years, 8 months ago (2016-04-01 20:45:51 UTC) #21
Leaf
https://chromiumcodereview.appspot.com/1829573002/diff/40001/lib/src/descriptor.pb.dart File lib/src/descriptor.pb.dart (right): https://chromiumcodereview.appspot.com/1829573002/diff/40001/lib/src/descriptor.pb.dart#newcode66 lib/src/descriptor.pb.dart:66: String get name => $_get/*<String>*/(0, 1, ''); On 2016/04/01 ...
4 years, 8 months ago (2016-04-01 20:50:19 UTC) #22
skybrian
Thanks. As you'd expect, I'm getting a lot more warnings now. I don't know how ...
4 years, 8 months ago (2016-04-01 21:47:35 UTC) #23
Leaf
On 2016/04/01 21:47:35, skybrian wrote: > Thanks. As you'd expect, I'm getting a lot more ...
4 years, 8 months ago (2016-04-01 22:08:50 UTC) #24
skybrian
On 2016/04/01 22:08:50, Leaf wrote: > On 2016/04/01 21:47:35, skybrian wrote: > > Thanks. As ...
4 years, 8 months ago (2016-04-01 22:12:39 UTC) #25
skybrian
https://chromiumcodereview.appspot.com/1829573002/diff/40001/lib/src/descriptor.pb.dart File lib/src/descriptor.pb.dart (right): https://chromiumcodereview.appspot.com/1829573002/diff/40001/lib/src/descriptor.pb.dart#newcode66 lib/src/descriptor.pb.dart:66: String get name => $_get/*<String>*/(0, 1, ''); On 2016/04/01 ...
4 years, 8 months ago (2016-04-01 23:09:17 UTC) #26
Leaf
On 2016/04/01 22:12:39, skybrian wrote: > On 2016/04/01 22:08:50, Leaf wrote: > > On 2016/04/01 ...
4 years, 8 months ago (2016-04-01 23:19:42 UTC) #27
skybrian
4 years, 8 months ago (2016-04-04 17:09:17 UTC) #29
Message was sent while issue was closed.
Committed patchset #5 (id:80001) manually as
23a67b48fc1ad532e7786345ce8b7b3adebd8f14 (presubmit successful).

Powered by Google App Engine
This is Rietveld 408576698