nac3artiq: allows kernel function

This commit is contained in:
pca006132 2021-10-01 00:02:15 +08:00
parent 1d2a32b140
commit 8447aa3000
1 changed files with 2 additions and 1 deletions

View File

@ -129,7 +129,8 @@ impl Nac3 {
ref decorator_list, ..
} => decorator_list.iter().any(|decorator| {
if let ast::ExprKind::Name { id, .. } = decorator.node {
id.to_string() == "extern" || id.to_string() == "portable"
let id = id.to_string();
id == "extern" || id == "portable" || id == "kernel"
} else {
false
}