mirror of
https://github.com/vlang/v.git
synced 2023-08-10 21:13:21 +03:00
v2: handle var decl & assign stmt together 1st step combining
This commit is contained in:
@@ -370,6 +370,10 @@ pub fn (t &Table) check(got, expected Type) bool {
|
||||
if got_type_sym.is_number() && exp_type_sym.is_number() {
|
||||
return true
|
||||
}
|
||||
// check hack in checker IndexExpr line #691
|
||||
if type_is_ptr(got) && got_type_sym.kind == .byte && exp_type_sym.kind == .byteptr {
|
||||
return true
|
||||
}
|
||||
// TODO
|
||||
// if got_type_sym.kind == .array && exp_type_sym.kind == .array {
|
||||
// return true
|
||||
|
||||
@@ -98,7 +98,7 @@ pub fn new_type_ptr(idx int, nr_muls int) Type {
|
||||
}
|
||||
|
||||
pub const (
|
||||
number_idxs = [int_type_idx, byte_type_idx, u64_type_idx]
|
||||
number_idxs = [int_type_idx, byte_type_idx, u32_type_idx, u64_type_idx]
|
||||
)
|
||||
|
||||
/*
|
||||
|
||||
Reference in New Issue
Block a user