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

checker: cleanup typeof (#9954)

This commit is contained in:
Enzo 2021-05-01 20:21:44 +02:00 committed by GitHub
parent ef63491a8c
commit 000d4d3064
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1979,10 +1979,6 @@ pub fn (mut c Checker) fn_call(mut call_expr ast.CallExpr) ast.Type {
if fn_name == 'main' {
c.error('the `main` function cannot be called in the program', call_expr.pos)
}
if fn_name == 'typeof' {
// TODO: impl typeof properly (probably not going to be a fn call)
return ast.string_type
}
mut has_generic := false // foo<T>() instead of foo<int>()
mut concrete_types := []ast.Type{}
for concrete_type in call_expr.concrete_types {