The current way of detecting a main method, might break when the source contains a string with a fn main() {.
At the same time it fails to detect main functions that are generated via macros.
I think it would make sense to have a flag that allows the user to force or prevent wrapping, as truly reliably detecting a main seems impossible.