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

markused: fix C compilation failures on -skip-unused -profile

This commit is contained in:
Delyan Angelov 2022-07-11 10:56:13 +03:00
parent 81d694b1f8
commit 94e35b710c

View File

@ -186,6 +186,14 @@ pub fn mark_used(mut table ast.Table, pref &pref.Preferences, ast_files []&ast.F
all_fn_root_names << k all_fn_root_names << k
continue continue
} }
if pref.is_prof {
if k.starts_with('time.vpc_now') || k.starts_with('v.profile.') {
// needed for -profile
all_fn_root_names << k
continue
}
}
if method_receiver_typename == '&sync.Channel' { if method_receiver_typename == '&sync.Channel' {
all_fn_root_names << k all_fn_root_names << k
continue continue