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

ch.ethz.acl.passera.unsigned.UInt.scala Maven / Gradle / Ivy

The newest version!
package ch.ethz.acl.passera.unsigned

class UInt(val intValue: Int) extends AnyVal with Serializable with SmallUInt[UInt] {
  override def toUInt = this
  override def intRep = intValue
}

object UInt {
  def MinValue = UInt(0)
  def MaxValue = UInt(~0)

  def apply(x: Int) = new UInt(x)
  def unapply(x: UInt) = Some(x.intValue)
}





© 2015 - 2025 Weber Informatics LLC | Privacy Policy