home *** CD-ROM | disk | FTP | other *** search
- :Title=Scope resolution operator
- :Priority=3 Major
- :Status=New
- :Type=C++ Compiler
- :SubType=
- :Method=System Test
- :Property1=0
- :Property2=0
- :Property3=0
- :Property4=0
- :Originator=Tom Tester
- :Investigator=
- :Resolver=
- :Verifier=
- :OrigDate=04-Jun-95
- :EstInvHours= 0.0
- :ActInvHours= 0.0
- :EstResHours= 0.0
- :ActResHours= 0.0
- :EstVerHours= 0.0
- :ActVerHours= 0.0
- :ModDate=06-Jun-95
- Version: 4.135
-
- The scope resolusion operator is not resolving scope as it should. Consider the code.
-
- int a;
-
- main()
- {
- int a;
- a = 3;
- cout << "local a = " << a << "\n"
- cout << "global a = " << :: << "\n"
- }
- The code results in the output:
-
- local a = 2
- global a = 2
-
- The output should be
-
- local a = 3
- global a = 2
-
-
-