Re: Fortran bashing in the MATLAB newsgroup



Damian wrote:
As an example of item 1, if you're talking to C/C++ programmers,
you'll spend a lot of time trying to explain why a Fortran "pointer"
is much safer and less of an impediment to optimization than a C/C++
pointer.

Just as a side-note: I used to program heavily C++ but looked into Fortran for curiosity some half year ago and really like the ideas and new concepts as well as subtle differences there (similar to my surprise and astonishment when I learned Scheme and Prolog as languages totally different from the good, old imperative C(++) style which was all I knew by that time).

However, I just attended a Fortran 95 course at my university and most guys there were either no real programmers and just forced by their curriculum to be there or C programmers, and I had a talk with some student who just could not understand how and why one can return arrays in Fortran (as this is a difficulty and needs work-around tricks in C)... To the level that he wanted to look at the assembly and tree-dump generated by gfortran to find out. And another one could not get rid of the image of C pointers and did not really understand the Fortran logic there. I can very well imagine that the majority of C, C++, Java programmers and those using other related languages just don't "want" to think of other paradigmas or even differences in the meaning of "pointer" as it is in Fortran.

Daniel

--
Done: Bar-Sam-Val-Wiz, Dwa-Elf-Hum-Orc, Cha-Law, Fem-Mal
Underway: Ran-Gno-Neu-Fem
To go: Arc-Cav-Hea-Kni-Mon-Pri-Rog-Tou
.



Relevant Pages

  • Re: Fortran article in Wikipedia
    ... > as those developed by others, which was especially true of FORTRAN ... compiler diagnostics compared to Fortran H although neither did the ... WatFor first appeared on IBM 7040s where the undefined variable ... > pointer causes an exception to be raised. ...
    (comp.lang.fortran)
  • Re: Calling C from FORTRAN
    ... This as a preparation for communication with regular Fortran object ... I stripped the ISO_C_BINDINGS use clauses from the interfacing Module ... POINTER, INTENT:: src, dst ... In the headerfile projPJ is introduced as follows (i.e. ...
    (comp.lang.fortran)
  • Re: Fortran and .NET (C#)
    ... pointer is destroyed, just like Fortran ALLOCATABLE. ... > return the address of the first element when returning an array. ...
    (comp.lang.fortran)
  • Re: Down-cast a polymorphic pointer?
    ... which just translate calls from Fortran to class methods. ... class, pointer:: ch ... type:: cbase ... and the subroutine GetAnObject is better implemented in Fortran ...
    (comp.lang.fortran)
  • Re: Fortran based MEX w/ COMMON/SAVE
    ... I believe dat (pointer to the array) and the ... SAVE at the begining of each subroutine is a bit unusual to me. ... > to unload it if there isn't a Fortran END or STOP statement. ... interaction w/ Matlab). ...
    (comp.soft-sys.matlab)