All Downloads are FREE. Search and download functionalities are using the official Maven repository.

monocle.std.Map.scala Maven / Gradle / Ivy

The newest version!
package monocle.std

import monocle.Iso

object map extends MapOptics

trait MapOptics {
  def mapToSet[K]: Iso[Map[K, Unit], Set[K]] =
    Iso[Map[K, Unit], Set[K]](_.keySet)(_.map(k => (k, ())).toMap)
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy