NewIntValue creates a new Value with an int value.
(x int64)
| 102 | |
| 103 | // NewIntValue creates a new Value with an int value. |
| 104 | func NewIntValue(x int64) *Value { |
| 105 | res := newPtr() |
| 106 | res.Elem().Set(reflect.ValueOf(x)) |
| 107 | return NewValue(res) |
| 108 | } |
| 109 | |
| 110 | // IsInt returns true if the value is an int. |
| 111 | func (v *Value) IsInt() bool { |