Fixed messages to use proper numbers

This commit is contained in:
obscuren
2014-09-26 13:32:54 +02:00
parent 9ed8dc7384
commit 68119d0929
3 changed files with 54 additions and 55 deletions

View File

@ -63,6 +63,10 @@ func (val *Value) Uint() uint64 {
return uint64(Val)
} else if Val, ok := val.Val.(uint64); ok {
return Val
} else if Val, ok := val.Val.(float32); ok {
return uint64(Val)
} else if Val, ok := val.Val.(float64); ok {
return uint64(Val)
} else if Val, ok := val.Val.(int); ok {
return uint64(Val)
} else if Val, ok := val.Val.(uint); ok {