Refactor RespondToFormatExceptionsTransformer (dart-lang/json_rpc_2#60)

Remove some implicit dynamic.

- Add a generic type on the transformer.
- Use the original `channel` argument to access the `sink` rather than
  assign to an intermediate transformed channel variable.
- Add a `test` argument to the `handleError` call to avoid having to
  rethrow and change stack traces on other error types.
- Read the `message` and `source` fields from a variable which has a
  static type.
- Add an explicit `dynamic` on one argument type which must be dynamic.
1 file changed
tree: ddbaa470672c301092d464a67863efe4b1d29d53
  1. pkgs/