-
Notifications
You must be signed in to change notification settings - Fork 46
Description
error: Couldn't infer type parameter 'N extends Built<N, NB>'.
Tried to infer 'AppState' for 'N extends Built<N, NB>' which doesn't work:
Type parameter 'N extends Built<N, NB>' declared to extend 'Built<AppState, NB extends Builder<N, NB>>'.
The type 'AppState' was inferred from:
Parameter 'nested' declared as 'NestedReducerBuilder<AppState, AppStateBuilder, N, NB>'
but argument is 'NestedReducerBuilder<AppState, AppStateBuilder, AppState, AppStateBuilder>'.
Consider passing explicit type argument(s) to the generic.
(could_not_infer at [xxx] lib/engine/app_reducers.dart:35)
code:
final appReducerBuilder = ReducerBuilder<AppState, AppStateBuilder>()
..combineNested(aReducerBuilder) etc...
final debugReducerBuilder = NestedReducerBuilder<AppState, AppStateBuilder,
DebugState, DebugStateBuilder>((s) => s.debugState, (b) => b.debugState)
..add(DebugActionsNames.toggleShowPerformanceOverlayAction,
_toggleShowPerformanceOverlay)
..add(DebugActionsNames.toggleStaggeredTileUseFit,
_toggleStaggeredTileUseExtent)
..add(DebugActionsNames.toggleApiEnvironment, _toggleTestEnvironment)
..add(DebugActionsNames.toggleMotiveDetectorDebug, _toggleMotionDetectorDebug);