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

org.wartremover.warts.EitherProjectionPartial.scala Maven / Gradle / Ivy

There is a newer version: 3.2.4
Show newest version
package org.wartremover
package warts

import scala.annotation.nowarn

@nowarn("msg=right-biased")
@nowarn("msg=Either.toOption.get")
@nowarn("msg=Either.swap.getOrElse")
object EitherProjectionPartial
    extends ExprMatch({
      case '{ (${ a }: Either.RightProjection[left, right]).get } =>
        "RightProjection#get is disabled - use RightProjection#toOption instead"
      case '{ (${ a }: Either.LeftProjection[left, right]).get } =>
        "LeftProjection#get is disabled - use LeftProjection#toOption instead"
    })




© 2015 - 2024 Weber Informatics LLC | Privacy Policy