Merge branch 'master' into plugins

This commit is contained in:
Stephen Chung
2020-07-29 14:17:40 +08:00
11 changed files with 192 additions and 108 deletions

View File

@@ -300,11 +300,9 @@ impl CallableFunction {
/// Get the access mode.
pub fn access(&self) -> FnAccess {
match self {
CallableFunction::Plugin(_) => FnAccess::Public,
CallableFunction::Pure(_)
| CallableFunction::Method(_)
| CallableFunction::Iterator(_) => FnAccess::Public,
CallableFunction::Script(f) => f.access,
Self::Plugin(_) => FnAccess::Public,
Self::Pure(_) | Self::Method(_) | Self::Iterator(_) => FnAccess::Public,
Self::Script(f) => f.access,
}
}
/// Get a reference to a native Rust function.