fix bug in hooks...

...that prevented the language server from seing inner statements of functions
This commit is contained in:
Mark 2023-12-07 09:22:19 +01:00
parent d3164254b3
commit d70e7ec066

View File

@ -27,7 +27,9 @@ impl MersStatement for Chain {
return Err("can't init to statement type Chain".to_string().into());
}
let prev_enable_hooks = info.global.enable_hooks;
info.global.enable_hooks = false;
if self.as_part_of_include.is_some() {
info.global.enable_hooks = false;
}
let arg = self.first.check(info, None)?;
let func = self.chained.check(info, None)?;
info.global.enable_hooks = prev_enable_hooks;