[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[task #15567] Converting hh:mm:ss and dd:mm:ss notations to degrees and

From: Mohammad Akhlaghi
Subject: [task #15567] Converting hh:mm:ss and dd:mm:ss notations to degrees and vice vesa
Date: Tue, 7 Apr 2020 18:07:26 -0400 (EDT)
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:74.0) Gecko/20100101 Firefox/74.0

Follow-up Comment #55, task #15567 (project gnuastro):

Thanks Kartik. I pulled the changes but still see that the commit message
title is two lines! Please correct it to be a single and complete line that is
shorter than 75 characters (which can be readable with `git log --oneline').

In the two `gal_units_decimal_to_dec' and `gal_units_decimal_to_ra', I noticed
that you have defined the variables in the middle of the functions. This isn't
a technical problem in modern C compilers, but it is a bad style ;-)! It makes
it so so hard to read the code! 

It is much better if all the variables are defined at the top of the function,
before any operation is done. When reading a code, someone can simply pull to
the top of the function and see all the various types used and variables
defined (which is itself valuable information before going into the details).

In the same two functions, the last element (`seconds' and `arc_seconds') is
floating point: in many cases we have sub-arcsecond accuracy ;-).


Reply to this item at:


  Message sent via Savannah

reply via email to

[Prev in Thread] Current Thread [Next in Thread]