Is it possible to write a macro that gets an expression, and then for every function that should inline, replaces it by the function body? This way I could use my inlinable functions and write something like @inline_expand@turbo expr.
My bad, you’re right. Then it would not work if there’s any dispatch going on. However, in my case I just want to write some functions, basically as an alias to make the code a bit cleaner and semantically easier to understand. The macro could scan the source code to find the function body in this case.
Note for your hypothetical macro to fulfil its purpose it would need to be expanded before the outer @turbo. I think (but do not know) that the outermost macro is expanded first. If that is the case then even your hypothetical macro solution could not work.
I assumed the same thing but it does seem to work, I’m not a great fan of the syntax though. Moreover I’m fine with writing a macro that wraps around @turbo.