1
0
mirror of https://github.com/vlang/v.git synced 2023-08-10 21:13:21 +03:00

all: disallow pointer arithmetic for AssignStmt, PostfixExpr outside unsafe{} (#5581)

This commit is contained in:
Nick Treleaven
2020-07-01 13:50:17 +01:00
committed by GitHub
parent 5eb76606ae
commit e7339fec15
6 changed files with 68 additions and 33 deletions

View File

@ -234,7 +234,9 @@ pub fn (s Socket) send(buf byteptr, len int) ?int {
if dlen <= 0 {
break
}
dptr += sbytes
unsafe {
dptr += sbytes
}
}
return len
}