summaryrefslogtreecommitdiff
path: root/src/main/scala/Chisel
diff options
context:
space:
mode:
authorPalmer Dabbelt2015-12-30 23:25:20 -0800
committerPalmer Dabbelt2015-12-30 23:25:20 -0800
commit0bc61c32673fac7a5583af4ffe71e4e0dac42a13 (patch)
tree56b3b11ca1e3f551db8027fb11e31b05670911cd /src/main/scala/Chisel
parentefd6a0a04d3616c03d27ce7745f46daaea8c6b90 (diff)
Add '=/=' to bits, which does the same as '!='
It looks like this is in Chisel2 now, and some stuff in uncore is using it. IIRC, we decided that this was the correct thing to do for some Scala style reasons.
Diffstat (limited to 'src/main/scala/Chisel')
-rw-r--r--src/main/scala/Chisel/Bits.scala1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/main/scala/Chisel/Bits.scala b/src/main/scala/Chisel/Bits.scala
index b6ee6d1a..e001f864 100644
--- a/src/main/scala/Chisel/Bits.scala
+++ b/src/main/scala/Chisel/Bits.scala
@@ -302,6 +302,7 @@ sealed class UInt private[Chisel] (dir: Direction, width: Width, lit: Option[ULi
def <= (other: UInt): Bool = compop(LessEqOp, other)
def >= (other: UInt): Bool = compop(GreaterEqOp, other)
def != (other: UInt): Bool = compop(NotEqualOp, other)
+ def =/= (other: UInt): Bool = compop(NotEqualOp, other)
def === (other: UInt): Bool = compop(EqualOp, other)
def unary_! : Bool = this === Bits(0)