DavidTruby wrote: > Great work David, thanks! Could you add some documentation explaining _where_ > `main` would be coming from in the case of mixed-source compilation? In fact, > is that tested anywhere? > > Also, IMHO it would be good to advertise this on Discourse (thinking > specifically about `-fno-fortran-main`).
In mixed-source compilation where there's no `program` statement in Fortran then main should be provided by whatever other language you're linking to. In the example of C/C++ that would just mean defining `main` yourself. In the case where there's a `program` statement in the Fortran we're now defining `main` by declaring it through MLIR. I've already posted about this on discourse, you can see the discussion here: https://discourse.llvm.org/t/rfc-link-to-fortran-main-using-embedded-linker-flags/77596. I should have put that in the PR comment! https://github.com/llvm/llvm-project/pull/89938 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits