linux-c-programming.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* can't initialize a constant using another constant?
@ 2008-02-26 14:32 Shriramana Sharma
  2008-02-27  8:09 ` Kristof Provost
  2008-02-27 11:43 ` Glynn Clements
  0 siblings, 2 replies; 6+ messages in thread
From: Shriramana Sharma @ 2008-02-26 14:32 UTC (permalink / raw)
  To: Linux C Programming List

Dear list,

Quite some time since I wrote. I hope you are all keeping well. :)

A strange thing I ran across this evening. I was not allowed to do:

const double lunarSynodicMonth = 29.53059 ;
const double daysLunarPhaseAngleTakesPerDegree = lunarSynodicMonth / 360.0 ;

I got the following error:

wdf-karanas.c:17: error: initializer element is not constant
make: *** [wdf-karanas.o] Error 1

I would be grateful if anyone could shed some light. TIA.

Shriramana Sharma.


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2008-02-28  9:52 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-02-26 14:32 can't initialize a constant using another constant? Shriramana Sharma
2008-02-27  8:09 ` Kristof Provost
2008-02-27  8:33   ` Kristof Provost
2008-02-27 11:43 ` Glynn Clements
2008-02-27 23:35   ` Shriramana Sharma
2008-02-28  9:52     ` Glynn Clements

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).