[flang-commits] [clang] [flang] [flang][Frontend] Implement printing defined macros via -dM (PR #87627)

Peter Klausler via flang-commits flang-commits at lists.llvm.org
Tue Apr 9 11:19:34 PDT 2024


klausler wrote:

> How is this code used outside of LLVM? Why do people want to use _without_ LLVM? Just curious.

There are people who want to construct tools to analyze or restructure Fortran programs outside of the context of compilation, and need to have access to a good parse tree or symbol table.  Unlike most other languages, Fortran is weirdly hard to lex & parse, and tool writers would rather use an existing parser than do a partial job with something custom.  So as a general rule, I avoid using llvm utilities in parsing and semantics (esp. parsing) when the facilities in `std::` are capable and portable, and try to encourage others to do the same.

https://github.com/llvm/llvm-project/pull/87627


More information about the flang-commits mailing list