mjklemm wrote: > Thanks! Mostly looks good, but I have a question: > > > This leads to the problem that _QQmain and _QQEnvironmentDefaults (as of > > the time of this PR) are symbols marked as used, while main is being > > defined. > > Sorry for being pedantic, but not sure I follow. `FortranMain` defines > `main`, which calls `_QQmain`. However, the latter wouldn't be available in a > library, right?
Yes, that's correct. The `main` symbol calls `_QQmain`, which happens to be the entry point for the Fortran program unit. > Also, not sure what defines `_QQEnvironmentDefaults ` and what exactly makes > it problematic? The `main` etrypoint also calls `_QQEnvironmentDefaults` to treat `argc`, `argv`, etc. So, when `main` is included in the shared object, so will be those symbols are used symbols, which makes no sense. > Btw, would you mind adding a note to the driver docs? Sure, I was planning to do this for the previous PR already but got distracted. Can you point me to the right place to add this? Thanks! https://github.com/llvm/llvm-project/pull/75816 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits