Simplify Input typeclass.
Add limited map-scan fusion.