Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion Groups
General
GeneralPortable MacsHardwareNetworking
Applications
Mac ApplicationsEudoraFirefox / MozillaInternet ExplorerOutlook ExpressMS OfficeEntourageExcelPowerPointWordVirtual PCMedia PlayerOther MS Products
Programming
Mac ProgrammingCodeWarriorPerl
Country Specific
Australian Mac GroupUK Mac Group

Mac Forum / Programming / CodeWarrior / August 2003



Tip: Looking for answers? Try searching our database.

They need to fix CW 8 before selling us 9 / no Academic

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
bobito@abac.com - 20 Aug 2003 17:54 GMT
Does no Academic CW9 mean that this global variables bug is going to go
unfixed for a year or more, until CW10, for users of the Academic version of
CodeWarrior?  

Bob


MW Ron - 20 Aug 2003 18:35 GMT
>Does no Academic CW9 mean that this global variables bug is going to go
>unfixed for a year or more, until CW10, for users of the Academic version of
>CodeWarrior?  

There is no global variables BUG it is just an unimplemented feature.  I
know you feel differntly but I can not say this enough times it never
has worked for Mach-O  and it partially works with  and only with the
8.3 and OS X 10.2.x versions.  There are simple methods that have been
used for other IDE/Debuggers and other systems.

I appreciate that you are new to Mach-O and that you are used to having
features work in one way that do not work in this way any longer.  But
please understand you are developing on a totally different executable
format in a totally different system.  And no matter how many cosmetics
Apple and Metrowerks apply so you still have the same look and feel this
is a totally differnt product.  

Metrowerks is doing its best to provide features and needs that improve
our product for our users.  We consider feature request and add these as
fast as we can.  We look at complaints and give these a high priority.  
We are concerned that this feature did not work and have been working
hard to add it.  But at some point you have to quit fixing old things
and move on to new ideas and ways of doing things with new designs.  

Ron

Signature

        CodeWarrior Development Studio for Macintosh v9
Enhance Your Productivity and Shorten your Development Cycles
                <http://store.metrowerks.com/>
       Sales and Support 512-996-5300   800-377-5416    
Ron Liechty - MWRon@metrowerks.com - http://www.metrowerks.com

Tobias Giesen - 20 Aug 2003 21:25 GMT
Hi,

this intrigues me - what exactly is this problem all about?

Cheers,
Tobias
bobito@abac.com - 20 Aug 2003 23:51 GMT
> Hi,
>
> this intrigues me - what exactly is this problem all about?
>
> Cheers,
> Tobias

In CW 8, if you are building mach-O, global variables do not show up in the
variables pane at the upper right of the debugger window.

That pane has a switch that you can click from 'all' to 'auto'--in that case
globals will show up, but only on the specific line in which they are
referenced/changed. This may sound slightly useful but it isn't really.

The only way to see globals is to open the 'Global Variables' window, then
scroll to the top of it and click 'Global Variables' ,then scroll down the
(possibly hundreds) of global variables in the entire app to find the one
you want.  And you have to do this every time you run the program.

It just makes debugging a slower process than usual, and it is frustrating.
Also, I don't know how you are supposed to find the value of static locals.

Bob
Tobias Giesen - 21 Aug 2003 00:23 GMT
Hi,

I see. What I usually do is enter the few ones I need into the Expressions
window. That works, doesn't it?

Ideally an OOP application would have only one global variable, the main
application object ...

Cheers,
Tobias
Alex Curylo - 24 Aug 2003 20:32 GMT
> The only way to see globals is to open the 'Global Variables' window, then
> scroll to the top of it and click 'Global Variables' ,then scroll down the
> (possibly hundreds) of global variables in the entire app to find the one
> you want.  And you have to do this every time you run the program.

Well, I find an effective workaround is to just declare locals at the
beginning of the scope in question and assign them the global variables of
interest, assigning them back at the end if desired.

I think this also allows the optimizer to be a little more clever when
rearranging things like loops which depend on the now-local value. Although
somebody that actually knows jack about how the optimizer works might very
well find that a laughable misconception, I'm sure.

Signature

Alex Curylo -- alex@alexcurylo.com -- http://www.alexcurylo.com/

"Bar fight? I head for the safest place -- directly behind Al!"
   -- Greg Chapman

Andy Dent - 25 Aug 2003 21:07 GMT
> Well, I find an effective workaround is to just declare locals at the
> beginning of the scope in question

Adding my two-cents worth of possibly-urban-myth about helping
optimisers, I particularly like copying to const locals. This also has
benefits in clarifying code and catching the odd stupid mistake.

(Sometimes I wonder if it's a good thing to confess in newsgroups my
obsession/need to code in a manner that catches stupid misteaks :-)

Signature

Andy Dent BSc  MACS  AACM
OOFILE - Database, Reports, Graphs, GUI for c++ on Mac, Unix & Windows
PP2MFC - PowerPlant->MFC portability
http://www.oofile.com.au/

Thomas Engelmeier - 26 Aug 2003 17:40 GMT
> Adding my two-cents worth of possibly-urban-myth about helping
> optimisers, I particularly like copying to const locals. This also has
> benefits in clarifying code and catching the odd stupid mistake.
>
> (Sometimes I wonder if it's a good thing to confess in newsgroups my
> obsession/need to code in a manner that catches stupid misteaks :-)

*grin* I guess everyone has some pecularities in this regard. I make
e.g. sure the source parameter for string copies etc. is const so the
compiler would catch any swapped( order parameter ); . Not that this
could happen in reality ;-)

Regards,
  Tom_E
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.