blob: 712975a79e37ba085521e9565626966800b556e1 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
|
// See LICENSE for license details.
package chisel3.util
import chisel3._
import scala.language.implicitConversions
object ImplicitConversions {
// The explicit fromIntToLiteral resolves an ambiguous conversion between fromIntToLiteral and
// UInt.asUInt.
implicit def intToUInt(x: Int): UInt = chisel3.core.fromIntToLiteral(x).asUInt
implicit def booleanToBool(x: Boolean): Bool = x.asBool
}
|