• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: variable question?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: variable question?


  • Subject: Re: variable question?
  • From: Clark Cox <email@hidden>
  • Date: Mon, 31 Jan 2005 02:59:01 -0500

On Sun, 30 Jan 2005 11:16:52 -0800, Michael de Haan <email@hidden> wrote:
> int main (){
>
> int c=7, foo=8, d=7,e;
>      return 0;
> }
>
> I know this is a dumb question, but I'll ask it anyhow.
>
> The reason I am unable to view "e" in the debugger is because it has
> only been declared and not initialized?
> Or is there a setting I am missing.
> Tks in advance

When a compiler optimizes code, it is allowed to do anything, so long
as it doesn't change the observable behavior of the program. Since
your program does nothing, the compiler is free to generate *any*
program that does nothing. In fact, it would be perfectly legal for
the compiler to behave as if your entire program were:

int main()
{
  return 0;
}

, because it behaves identically to your original program.

--
Clark S. Cox III
email@hidden
http://www.livejournal.com/users/clarkcox3/
http://homepage.mac.com/clarkcox3/
 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

References: 
 >variable question? (From: Michael de Haan <email@hidden>)

  • Prev by Date: View mpeg2enc
  • Next by Date: Re: NSLog and deployment builds
  • Previous by thread: Re: variable question?
  • Next by thread: FILE -> NEW CLASS (Placement of newly created subclass)
  • Index(es):
    • Date
    • Thread