1package utils 2 3import chisel3._ 4 5/** 6 * Produce named UInt(x.W) 7 * 8 * @example {{{ 9 * object Fflags extends NamedUInt(5) 10 * val fflags = Fflags() 11 * }}} 12 */ 13abstract class NamedUInt(int : Int) { 14 def apply(): UInt = UInt(width.W) 15 16 def width: Int = int 17} 18