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

all: remove byteptr and charptr; replace them with &byte and &char

This commit is contained in:
Alexander Medvednikov
2021-04-04 17:43:32 +03:00
parent 8dd4a63913
commit 57e6138a61
32 changed files with 250 additions and 226 deletions

View File

@@ -178,13 +178,13 @@ fn encode_bool(val bool) &C.cJSON {
}
fn encode_string(val string) &C.cJSON {
return C.cJSON_CreateString(charptr(val.str))
return C.cJSON_CreateString(&char(val.str))
}
// ///////////////////////
// user := decode_User(json_parse(js_string_var))
fn json_parse(s string) &C.cJSON {
return C.cJSON_Parse(charptr(s.str))
return C.cJSON_Parse(&char(s.str))
}
// json_string := json_print(encode_User(user))