mirror of
https://github.com/vlang/v.git
synced 2023-08-10 21:13:21 +03:00
check integer const overflow at compilation
This commit is contained in:
@ -133,6 +133,10 @@ pub fn (s string) int() int {
|
||||
return C.atoi(s.str)
|
||||
}
|
||||
|
||||
pub fn (s string) i64() i64 {
|
||||
return C.atoll(s.str)
|
||||
}
|
||||
|
||||
pub fn (s string) f32() f32 {
|
||||
return C.atof(s.str)
|
||||
}
|
||||
|
Reference in New Issue
Block a user