Cosmoglobe/Commander

Get rid of comm_hdf_mod.f90.in?

Opened this issue · 5 comments

hke commented

Should we get rid of comm_hdf_mod.f90.in, and just adopt the static .f90 version as the baseline solution?

There are some hidden issues in the static version that I think still need to be fixed. @MetinSa and I discovered that the character array functionality was broken until recently, for example. Then again, without the tempita running, we can just make manual edits.

hke commented

Not sure I understand this... The version that is generated with tempita is the one that is compiled into the code. So if we just store that .f90 file between compilations, I don't see how this can change any functionality? It's just that the file isn't automatically generated every time?

Well when we wanted to write strings to the output chains file, we made edits to the .in file, which changed the .f90 file... I doubt there are many issues left here, but I'd prefer to keep the .in file just for transparency and also in case we do find something else worth fixing

I think having the functionality to re-generate the file is useful, so that if we need to add support for another datatype for example, we don't have to manually write 15 new functions that are almost identical. But removing the re-generation from the default build chain might be a good idea, as it still sometimes causes problems with the make file and requires a make clean

The ideal solution is to keep this file as it is but not have tempita run during compilation by default. It would be good to confirm if this was currently the case, or how one actually runs this file at all.