use crate::codegen::ir::mir::func::MirFuncMode;
pub(crate) fn has_port_argument(mode: MirFuncMode) -> bool {
!matches!(mode, MirFuncMode::Sync)
}
#[cfg(test)]
mod tests {
use super::*;
#[test]
fn distinguishes_function_modes_that_require_ports() {
assert!(has_port_argument(MirFuncMode::Normal));
assert!(!has_port_argument(MirFuncMode::Sync));
}
}