# File lib/ruby-vpi/integer.rb, line 62
62:   def pack aPackedWidth
63:     bits = length
64:     bits += 1 if self > 0 # positive integers also have a sign bit (zero)
65: 
66:     unless aPackedWidth >= bits
67:       raise ArgumentError, "packed width #{aPackedWidth} must be at least #{bits} for integer #{self}"
68:     end
69: 
70:     extend_sign(bits, aPackedWidth)
71:   end