Isn't it redundant for Control.Lens.Setter to wrap types in functors?
<p>I'm watching the <code>Control.Lens</code> introduction <a href="https://www.youtube.com/watch?v=cefnmjtAolY" rel="noreferrer">video</a>.<br>
It makes me wonder why is it needed for the <code>Setter</code> type to wrap things in functors.<br>
It's (roughly) defined like this:</p>

<pre><code>type Control.Lens.Setter s t a b = (Functor f) =&gt; (a -&gt; f a) -&gt; s -&gt; f t
</code></pre>

<p>Let's say I have a data called <code>Point</code> that's defined like this:</p>

<pre><code>data Point = Point { _x :: Int, _y :: Int } deriving Show
</code></pre>

<p>Then I can write my own <code>xlens</code> like this:</p>

<pre><code>type MySetter s t a b = (a -&gt; b) -&gt; s -&gt; t
xlens :: MySetter Point Point Int Int
xlens f p = p { _x = f (_x p) }
</code></pre>

<p>And I can use it like this:</p>

<pre><code>p = Point 100 200
xlens (+1) p -- Results in Point { _x = 101, _y = 200 }
</code></pre>

<p>By using <code>Control.Lens</code>, the same effect is achieved by:</p>

<pre><code>over x (+1) p
</code></pre>

<p>where the following stands:</p>

<pre><code>x :: Functor f =&gt; (Int -&gt; f Int) -&gt; Point -&gt; f Point
over :: Setter Point Point Int Int -&gt; (Int -&gt; Int) -&gt; Point -&gt; Point
</code></pre>

<p>So my question is, since the same effect can be achieved in a simpler manner, why <code>Control.Lens</code> wraps things in functors? It looks redundant to me, since my <code>xlens</code> does the same as <code>Control.Lens</code>'s <code>over x</code>.</p>

<p>Just for the record, I can also chain my lenses in the same manner:  </p>

<pre><code>data Atom = Atom { _element :: String, _pos :: Point } deriving Show
poslens :: MySetter Atom Atom Point Point
poslens f a = a { _pos = f (_pos a) }

a = Atom "Oxygen" p
(poslens . xlens) :: (Int -&gt; Int) -&gt; Atom -&gt; Atom
(poslens . xlens) (+1) a -- Results in Atom "Oxygen" (Point 101 200)
</code></pre>