Must casting destroy lvalueness?

John Gilmore gnu at hoptoad.uucp
Wed Oct 29 15:41:23 AEST 1986


One interesting thing for people who don't understand this issue to do is
to ask yourself what the compiler should do for a construct like:

	int i = 17;
	((double)i)++;

Again, don't post your favorite answer to the net.  Just think about it.

PS:  When you're done that one, try:

	double i = 17;
	((int)i)++;
-- 
John Gilmore  {sun,ptsfa,lll-crg,ihnp4}!hoptoad!gnu   jgilmore at lll-crg.arpa
  Overheard at a funeral: "I know this may be an awkward time, but do
  you recall him ever mentioning source code?"		-- Charles Addams



More information about the Comp.lang.c mailing list