Earlier quoted context omitted.
"I don't know what the language of the year 2000 will look like, but I know it will be called Fortran." —Tony Hoare
I have seen this quote thrown around a lot and have never had the proper context to understand what Hoare was getting at. The quote is from 1982[1], which seems a bit too late for any “Fortran juggernaut” jokes to have been relevant, and even in 1982 I would have guessed that Fortran was considered a bit old-fashioned. Was he commenting on its comparatively simple design, compared to “flashier” languages like Pascal?…
Fortran Package Manager
41–50 of 73 posts
Re: Fortran Package Manager
#42For folks who have never used Fortran, how is the day to day life compared to Python or Java?
* Missing standard data structures, like hash maps. I just wish I had something like a Python dictionary built in.
* Strings are pretty awful. You can now have resizeable strings but using them is very painful (and buggy in gfortran). You'll have to constantly strip spaces off the ends of strings to even print them.
* Some of the compilers are very immature (gfortran), if using any fairly recent features (e.g. resizeable strings). I've hit several (still unfixed) compiler bugs and my code contains some terrible workarounds.
* Available libraries are hit and miss, particularly outside the numerical area.
* Linking to C/C++ is possible, but painful with the binding support.
* Documentation (including books) just isn't good compared to what's available for C/C++/Python, etc.
* No templates (would come in very handy for some routines which handle different numerical types).
* Ok for numerics, though can't use C/C++ intrinsics for AVX/SSE maths.
I suppose what I like better than C/C++ is the module system and built-in support for N dimensional arrays with proper slicing, etc. The allocatable array thing is quite nice - it's like smart pointers in C++.
Re: Fortran Package Manager
#43For folks who have never used Fortran, how is the day to day life compared to Python or Java?
It depends on what you are doing. If it is numerical work with matrix operations, then Fortran is fast and pretty intuitive. Some of the annoyances come from dealing with legacy code and mixing it with modern standards.
Re: Fortran Package Manager
#44Earlier quoted context omitted.
The intuition is similar to "why C over other languages?": speed. Many programmers treat C as the fastest/lowest-level cross-platform language, but Fortran sometimes has a slight edge (especially with specialised compilers, e.g. I remember Intel's producing very fast binaries). Although it's general-purpose, Fortran skews heavily towards numerical calculations, which is probably why it's not used much outside science…
But interfacing with Fortran from other languages is easy (well, barring some compiler assumptions that everyone seems to be making anyway). Why not leverage the general purpose strength of languages like Rust or C++ or Python (or even C), while still retaining access to the vast trove of numerical Fortran libraries? (Not that I'm judging, people should use whatever language they prefer).
Re: Fortran Package Manager
#45Earlier quoted context omitted.
"I don't know what the language of the year 2000 will look like, but I know it will be called Fortran." —Tony Hoare
I have seen this quote thrown around a lot and have never had the proper context to understand what Hoare was getting at. The quote is from 1982[1], which seems a bit too late for any “Fortran juggernaut” jokes to have been relevant, and even in 1982 I would have guessed that Fortran was considered a bit old-fashioned. Was he commenting on its comparatively simple design, compared to “flashier” languages like Pascal?…
Re: Fortran Package Manager
#46Just curious is Fotran Still being used in Newer Projects
Re: Fortran Package Manager
#47Earlier quoted context omitted.
Yes, but I think not as much as advocates of it would suggest.
Just like SQL, it suffices to rule on one specific use case to keep being used.
I get a bit annoyed by Fortran advocates complaining about people using C++/Python instead of it, when there aren't libraries for doing really basic things. I think Fpm is a really good step in the right direction though.
Re: Fortran Package Manager
#48As a side note. I've never used Fortran, but I see it around from time to time (R & Python packages that have fortran dependencies). Is Fortran seeing a bit of a resurgence? Is there any reason to use Fortran over say C, C++, Rust, or some other language? Or is it simply down to Fortran's maturity providing robust libraries in certain areas that other languages haven't?
Re: Fortran Package Manager
#49For folks who have never used Fortran, how is the day to day life compared to Python or Java?
Of course, you have to overcome decades worth of ``stuff'' but it certainly is the right tool for what I am doing. It has a purpose but there is a learning curve to getting things done the FORTRAN way.
Re: Fortran Package Manager
#50Earlier quoted context omitted.
Also Compared to Python Fortran is an old school compiled language - you have to get used to working with a compline/link cycle without the interactivity that Python has. This isn't any better or worse but does require a shift in mind set. Though I believe some people are trying to build a Fortan Repl
> Also Compared to Python Fortran is an old school compiled language - you have to get used to working with a compline/link cycle without the interactivity that Python has. I mean, yeah, Fortran is a bit old school, but being compiled is not exactly old school. Plenty of modern languages are compiled. I'd even say that Python and JS are the odd ones out from a modern perspective.