Add missing generic on _FunctionMatcher field (#124)
Fixes #122
Remove redundant type annotation on list literal.
diff --git a/lib/src/having_matcher.dart b/lib/src/having_matcher.dart
index cde28af..6a5fd46 100644
--- a/lib/src/having_matcher.dart
+++ b/lib/src/having_matcher.dart
@@ -11,13 +11,13 @@
/// by calls to [TypeMatcher.having].
class HavingMatcher<T> implements TypeMatcher<T> {
final TypeMatcher<T> _parent;
- final List<_FunctionMatcher> _functionMatchers;
+ final List<_FunctionMatcher<T>> _functionMatchers;
HavingMatcher(TypeMatcher<T> parent, String description,
Object Function(T) feature, Object matcher,
- [Iterable<_FunctionMatcher> existing])
+ [Iterable<_FunctionMatcher<T>> existing])
: _parent = parent,
- _functionMatchers = <_FunctionMatcher>[
+ _functionMatchers = [
...?existing,
_FunctionMatcher<T>(description, feature, matcher)
];