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

checker: check generic method call args mismatch (#10669)

This commit is contained in:
yuyi
2021-07-05 15:14:00 +08:00
committed by GitHub
parent 972542d6ee
commit c4b5805890
4 changed files with 25 additions and 8 deletions

View File

@ -306,15 +306,15 @@ fn test_read_raw_at() ? {
f.write_raw(another_permission) ?
f.close()
f = os.open_file(tfile, 'r') ?
mut at := 3
mut at := u64(3)
p := f.read_raw_at<Point>(at) ?
at += int(sizeof(Point))
at += sizeof(Point)
b := f.read_raw_at<byte>(at) ?
at += int(sizeof(byte))
at += sizeof(byte)
c := f.read_raw_at<Color>(at) ?
at += int(sizeof(Color))
at += sizeof(Color)
x := f.read_raw_at<Permissions>(at) ?
at += int(sizeof(Permissions))
at += sizeof(Permissions)
f.close()
assert p == another_point