Hi! Maintainer of MacroTools.jl and author of splitdef/combinedef here. MacroTools is not actively developed ATM, but it’s been around for a long time, and basically it does what it says it does? It’s one of the most used packages in the ecosystem, so the bugs have been ironed out.
ExprTools offers a splitdef/combinedef with very similar interfaces. There was talk to merge the two five years ago, but that didn’t happen. Not clear what the benefits are in 2025. I’m not aware of any outstanding bug in splitdef.
There’s also MLStyle.jl which can do it. It comes with a benchmark! The graph looks off, but looking at the data behind it, it seems to be that MLStyle is faster for small-ish expressions, but slower for big ones? But that’s only precompilation time, so pretty small potatoes unless you have a widely used macro. It’s used in the SciML space; that’s a good recommendation in its favor.
One important point regardless: if your macro is returning function definitions, consider using @qq begin instead of quote, so that line numbers are correct (then go-to-definition and stacktraces become much more useful).