mirror of
https://github.com/vlang/v.git
synced 2023-08-10 21:13:21 +03:00
checker: allow EnumName(number) casts only inside unsafe{} blocks (#15932)
This commit is contained in:
@@ -212,7 +212,7 @@ pub fn (mut stmt Stmt) bind(typ int, buffer voidptr, buf_len u32) {
|
||||
|
||||
pub fn (mut stmt Stmt) bind_res(fields &C.MYSQL_FIELD, dataptr []&u8, lens []u32, num_fields int) {
|
||||
for i in 0 .. num_fields {
|
||||
len := FieldType(unsafe { fields[i].@type }).get_len()
|
||||
len := unsafe { FieldType(fields[i].@type).get_len() }
|
||||
stmt.res << C.MYSQL_BIND{
|
||||
buffer_type: unsafe { fields[i].@type }
|
||||
buffer: dataptr[i]
|
||||
|
||||
Reference in New Issue
Block a user