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

check unused and unmodified vars in all modules, not just main

This commit is contained in:
Alexander Medvednikov
2019-12-06 15:24:53 +03:00
parent bdaa421e8a
commit c8d111924d
31 changed files with 133 additions and 119 deletions

View File

@ -133,7 +133,7 @@ pub mut:
}
// Should be called by main at the end of the compilation process, to cleanup
pub fn (v mut V) finalize_compilation(){
pub fn (v &V) finalize_compilation(){
// TODO remove
if v.pref.autofree {
/*
@ -1184,7 +1184,7 @@ pub fn set_vroot_folder(vroot_path string) {
// Preparation for the compiler module:
// VEXE env variable is needed so that compiler.vexe_path()
// can return it later to whoever needs it:
mut vname := if os.user_os() == 'windows' { 'v.exe' } else { 'v' }
vname := if os.user_os() == 'windows' { 'v.exe' } else { 'v' }
os.setenv('VEXE', os.realpath( [vroot_path, vname].join(os.path_separator) ), true)
}