-- (octave .~ n) a `octaveEq` a
octave :: (Semitones t, Transpose t) => Lens' t Int
octave = lens (div12 . steps) setOctave
  where
    setOctave :: (Semitones t, Transpose t) => t -> Int -> t
    setOctave s b = shift x s
      where x = 12 * (b - div12 (steps s))
      
    {-
      set :: t -> Int -> t
      set s b = div12 (steps s) + x = b
      x = b - div12 (steps s)
    -}