Google
  Web www.spinics.net

Re: scoping issue

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


Jason_Haynberg wrote:
> This strikes me as a bug.  What do you think?  
> It seems the first program should get the same error as the second?

Your first program is equivalent to

main()
{
  {
    int i;
    for (i = 0; i < 5; i++) {
      cout << i << endl;
      double i = 10.0;
      cout << i << endl;
    }
  }
}

Andrew.

[Linux C Programming]     [C Programming]     [Kernel List]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]     [C++ How to Program]

Add to Google