Breaking news: #LFortran, a #compiler for the two people who still write #Fortran, has achieved the monumental feat of compiling #fpm. 🎉🤦‍♂️ Excited developers publish a novella-length blog post, as if anyone is going to read all 1401 words about yet another compiler doing what compilers do. 📚💤
https://lfortran.org/blog/2026/02/lfortran-compiles-fpm/ #Development #News #TechCommunity #HackerNews #ngated
LFortran compiles fpm

LFortran can now compile fpm, the Fortran Package Manager. We opened up an issue for it in April 2025, when we started focusing on it as a priority. We closed it on February 7, 2026. fpm is the most complex project that we now successfully built and run. It is an interesting project: it is not computational, but rather a system project which exercises running other programs, reading environment variables, command-line argument parsing, reading and writing files, directories, parsing enough Fortran to understand dependencies, etc. It uses almost all modern Fortran features: classes, inheritance, allocatable components, constructors, arrays of classes, select type, associate, automatic LHS (left-hand side) reallocation, strings, arrays of strings and it exposed dozens and dozens of bugs and missing features in LFortran. And we have now implemented them all. As a result, LFortran is really close to beta, and we are advancing our progress bar to 9/10.

LFortran
LFortran compiles fpm

LFortran can now compile fpm, the Fortran Package Manager. We opened up an issue for it in April 2025, when we started focusing on it as a priority. We closed it on February 7, 2026. fpm is the most complex project that we now successfully built and run. It is an interesting project: it is not computational, but rather a system project which exercises running other programs, reading environment variables, command-line argument parsing, reading and writing files, directories, parsing enough Fortran to understand dependencies, etc. It uses almost all modern Fortran features: classes, inheritance, allocatable components, constructors, arrays of classes, select type, associate, automatic LHS (left-hand side) reallocation, strings, arrays of strings and it exposed dozens and dozens of bugs and missing features in LFortran. And we have now implemented them all. As a result, LFortran is really close to beta, and we are advancing our progress bar to 9/10.

LFortran

The #LFortran compiler (alpha stage) now compiles the #Fortran Package Manager #fpm:
https://lfortran.org/blog/2026/02/lfortran-compiles-fpm/

Beta version before the end of 2026?
https://fortran-lang.discourse.group/t/lfortran-compiles-fpm/10744

LFortran compiles fpm

LFortran can now compile fpm, the Fortran Package Manager. We opened up an issue for it in April 2025, when we started focusing on it as a priority. We closed it on February 7, 2026. fpm is the most complex project that we now successfully built and run. It is an interesting project: it is not computational, but rather a system project which exercises running other programs, reading environment variables, command-line argument parsing, reading and writing files, directories, parsing enough Fortran to understand dependencies, etc. It uses almost all modern Fortran features: classes, inheritance, allocatable components, constructors, arrays of classes, select type, associate, automatic LHS (left-hand side) reallocation, strings, arrays of strings and it exposed dozens and dozens of bugs and missing features in LFortran. And we have now implemented them all. As a result, LFortran is really close to beta, and we are advancing our progress bar to 9/10.

LFortran
LFortran compiles LAPACK

Every respectable Fortran compiler must be able to compile LAPACK, probably the most famous and influential Fortran library. Christopher Albert spent most of December 2025 to get it working, it took about 70 PRs (pull requests). For context, LFortran is composed of about 4,500 merged PRs at GitHub plus another 1,800 merged PRs at GitLab (before we switched to GitHub), total of 6,300 PRs. So 70 PRs is about 1% of all the PRs, very impressive effort!

LFortran
🚀🎉 Bravo, LFortran! You managed to "innovatively" compile #PRIMA — again. 🎩✨ How many developers does it take to write 1138 words on something that has been done a thousand times before? Apparently, all of them. 🙄🔧
https://lfortran.org/blog/2025/03/lfortran-compiles-prima/ #LFortran #compilation #developer #humor #innovation #coding #HackerNews #ngated
LFortran compiles PRIMA

We’re thrilled to share that LFortran can now successfully compile and execute libprima/PRIMA. PRIMA marks the eighth production-grade, third-party code that LFortran has compiled with bit-for-bit alignment to GFortran’s output. This milestone brings us closer to our goal of compiling 10 such codes—an essential step toward achieving a beta-quality compiler. About PRIMA PRIMA is a package developed by Zaikun Zhang for solving general nonlinear optimization problems without using derivatives. It provides the reference implementation for Powell’s derivative-free optimization methods, i.e., COBYLA, UOBYQA, NEWUOA, BOBYQA, and LINCOA. PRIMA means Reference Implementation for Powell’s methods with Modernization and Amelioration, P for Powell. The package is written in Fortran and is widely used in the scientific community for solving optimization problems.

LFortran
LFortran compiles PRIMA

We’re thrilled to share that LFortran can now successfully compile and execute libprima/PRIMA. PRIMA marks the eighth production-grade, third-party code that LFortran has compiled with bit-for-bit alignment to GFortran’s output. This milestone brings us closer to our goal of compiling 10 such codes—an essential step toward achieving a beta-quality compiler. About PRIMA PRIMA is a package developed by Zaikun Zhang for solving general nonlinear optimization problems without using derivatives. It provides the reference implementation for Powell’s derivative-free optimization methods, i.e., COBYLA, UOBYQA, NEWUOA, BOBYQA, and LINCOA. PRIMA means Reference Implementation for Powell’s methods with Modernization and Amelioration, P for Powell. The package is written in Fortran and is widely used in the scientific community for solving optimization problems.

LFortran
Why does Lfortran use conda?

I guess this is 50% a question and 50% a rant. The first time I tried to install LFortran I gave up because I couldn’t figure out a way to install it without conda. It was very frustrating. Today I tried again and this time I bit the bullet and installed conda. I don’t understand why a Fortran compiler needs conda. It’s bad enough that it needs Python, but apparently the Python I already have in my Linux system is not enough and I need to install 9.23 GB to get a whole other separate install o...

Fortran Discourse
@vmagnin I see from the link below that "#LFortran (as of today) can compile 6 out of 18 Fortran packages in #SciPy" and is asking for input on this issue to start using LFortran to compile SciPy to #WASM and for further testing: https://github.com/emscripten-forge/recipes/issues/684
Use LFortran to compile any Fortran to WASM · Issue #684 · emscripten-forge/recipes

LFortran (as of today) can compile 6 out of 18 Fortran packages in SciPy: lfortran/lfortran#2743, and we keep working on compiling the rest. At the same time, I think it's a good time to start usin...

GitHub

LFortran can now compile one example in Minpack and get exactly the same answer as GFortran. A small step for an end user, but a huge step for us, as we got one production code running end to end.

The next steps are to harden everything.

LFortran is still (advanced) alpha.

https://twitter.com/lfortranorg/status/1601253953869844482

#lfortran #fortran

LFortran on Twitter

“Big milestone: LFortran can now get bit to bit exact floating point answers as GFortran for one test program of Minpack. We have it. We have to harden everything, and implement all of Fortran, but Minpack is the first production code that now works! https://t.co/o9HhsYOgmE”

Twitter
You can try #Fortran with online #compilers:
- On the Fortran Playground https://play.fortran-lang.org/ you can learn Fortran by compiling (and editing) various examples.
- On Godbolt Compiler Explorer https://godbolt.org/, you can use several versions of #GFortran, Intel #ifort, Intel #ifx and #Flang. And you can read the assembler code.
- On https://dev.lfortran.org/ you can play with the #LFortran compiler (development in progress) and see its intermediate representations.
Playground