Giter Site home page Giter Site logo

Preprocessor about stdlib HOT 4 CLOSED

fortran-lang avatar fortran-lang commented on May 23, 2024
Preprocessor

from stdlib.

Comments (4)

certik avatar certik commented on May 23, 2024

Yes, it's relevant to how files should be named whether .f90 or .F90, etc. I really don't like the .F90 suffix, as the capital letter signals some old FORTRAN style code. I wish the convention was the other way round, that .f90 gets automatically preprocessed.

It seems the discussion at #35 seems to converge towards trying jin2for, instead of using a preprocessor.

But #72 would need one. Although in my own codes I do not use a preprocessor and just do call assert(...). It does not print the line number, but that could be fixed by printing the whole stacktrace, there are libraries that can do that (although they might not work on all platforms).

Given resistance to standardize a preprocessor in j3-fortran/fortran_proposals#65, I don't know what the best recommended practice is.

from stdlib.

gronki avatar gronki commented on May 23, 2024

Preprocessing can be forced upon by -cpp option in most compilers. I imagine that is compiler dependent though.

I dislike uppercase .F90 too but I still use it in my projects as most compilers recognize this without the need for extra options. So I would imagine that would be the most fail-safe solution.

from stdlib.

certik avatar certik commented on May 23, 2024

See the discussion in this and following comments: #72 (comment). Where we decided to just use .f90, but pass an appropriate compiler option (such as -fpp) to pre-process the files.

from stdlib.

pdebuyl avatar pdebuyl commented on May 23, 2024

Hi @certik since I opened this issue, it became obvious that stdlib would rely on a preprocessor. I am thus closing the issue.

from stdlib.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.