Closed
Bug 233809
Opened 21 years ago
Closed 16 years ago
investigate /Za or /Zc:forScope compiler options to fix for loop scoping
Categories
(Firefox Build System :: General, defect)
Tracking
(Not tracked)
RESOLVED
WORKSFORME
People
(Reporter: dbaron, Unassigned)
Details
Attachments
(2 files, 1 obsolete file)
4.47 KB,
patch
|
Details | Diff | Splinter Review | |
2.24 KB,
patch
|
Details | Diff | Splinter Review |
We should investigate whether the compiler options that force MSVC to use the standard for-loop scoping rules work on compilers as old as VC6. See: http://msdn.microsoft.com/library/en-us/vccore/html/_core_.2f.za.2c_2f.ze.asp http://msdn.microsoft.com/library/en-us/vccore/html/vcrefzcforscope.asp And perhaps also the pragma if some embedder uses our code without our build system: http://msdn.microsoft.com/library/en-us/vccelng/htm/pragm_8.asp (This would leave the HP-UX compiler as the only one without correct for-loop scoping, I think.)
Reporter | ||
Comment 1•21 years ago
|
||
(See bug 233810 for options for the HP aCC compiler.)
Reporter | ||
Comment 2•21 years ago
|
||
Unfortunately, this option doesn't seem to be supported in MSVC 6.0.
Reporter | ||
Comment 3•21 years ago
|
||
this being /Zc:forScope. I should try /Za, I guess...
Reporter | ||
Comment 4•21 years ago
|
||
The compiler accepts -Za, but it gives errors in the string code...
Reporter | ||
Comment 5•21 years ago
|
||
The options for 6.0 are: http://msdn.microsoft.com/library/en-us/vccore98/HTML/_core_compiler_reference.asp
Reporter | ||
Comment 6•21 years ago
|
||
Comment 7•21 years ago
|
||
What was the nature of the errors in the string code?
Updated•20 years ago
|
Product: Browser → Seamonkey
Reporter | ||
Updated•18 years ago
|
Summary: investigate /Za or /Zc compiler options → investigate /Za or /Zc:forScope compiler options to fix for loop scoping
Reporter | ||
Comment 8•18 years ago
|
||
So if VC++ 7.1 is the oldest supported compiler on the trunk, we could add the -Zc:forScope option to the VC++ command line options and stop requiring tolerance for both for loop scoping rules on the trunk.
Product: Mozilla Application Suite → Core
Comment 9•18 years ago
|
||
Yes please.
Reporter | ||
Comment 10•18 years ago
|
||
My Windows build env is still VC6, so I'm not set up to build trunk. If somebody could try this, and check that a for loop scoping case that doesn't compile without it does compile with it, that would be great...
Reporter | ||
Comment 11•18 years ago
|
||
So this doesn't even seem to be a problem on VC8, but it would be nice if somebody tested this on VC7.1. But I'll actually attach another patch that touches only CXXFLAGS.
Reporter | ||
Comment 12•18 years ago
|
||
Attachment #231145 -
Attachment is obsolete: true
Reporter | ||
Comment 13•18 years ago
|
||
So it's actually not a problem on 7.1 either. The problem is on VC6, which doesn't even have this option. And we still have trunk tinderboxes building with VC6.
Reporter | ||
Comment 14•18 years ago
|
||
(And, for what it's worth, I no longer have a Windows build environment, nor the energy to try to set one up. I deleted my working VC6 environment tonight in an effort to install VC7.1. I installed it, but when it came to setting up the environment variables I couldn't figure out which environment variables had come from my setup of VC6, what was set by various installers, etc. So I deleted them all, plus the install of VC7.1. Windows isn't designed for installing and upgrading software.)
Reporter | ||
Updated•18 years ago
|
Assignee: dbaron → nobody
Comment 15•17 years ago
|
||
David, is this still "wanted" in any sense?
Comment 16•16 years ago
|
||
If this is only a problem with VC6, then it's not, because we only support VC7.1 or newer on trunk.
Status: NEW → RESOLVED
Closed: 16 years ago
Resolution: --- → WORKSFORME
Updated•6 years ago
|
Product: Core → Firefox Build System
You need to log in
before you can comment on or make changes to this bug.
Description
•