From 82278c3a5aa93204c963a63cc3cfefea1d0fb3fd Mon Sep 17 00:00:00 2001 From: Melody Horn Date: Sun, 28 Mar 2021 01:45:52 -0600 Subject: lay down boilerplate for function calls of all the obnoxious GNUisms, this will probably wind up being the largest. especially if huge makefiles (e.g. Linux) use most of the functions that GNU offers, meaning we have to implement most of them to be Linuxable --- src/makefile/functions.rs | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100644 src/makefile/functions.rs (limited to 'src/makefile/functions.rs') diff --git a/src/makefile/functions.rs b/src/makefile/functions.rs new file mode 100644 index 0000000..bc39886 --- /dev/null +++ b/src/makefile/functions.rs @@ -0,0 +1,31 @@ +use super::token::TokenString; + +pub(crate) fn call(name: &str, args: &[TokenString]) -> TokenString { + match name { + // Text Functions + "filter" => todo!(), + "filter-out" => todo!(), + "sort" => todo!(), + + // File Name Functions + "notdir" => todo!(), + "basename" => todo!(), + "addprefix" => todo!(), + "wildcard" => todo!(), + + // foreach + "foreach" => todo!(), + + // call + "call" => todo!(), + + // eval + "eval" => todo!(), + + // shell + "shell" => todo!(), + + // fallback + _ => panic!("function not implemented: {}", name), + } +} -- cgit v1.2.3