[Home] [Downloads] [Search] [Help/forum]

Gammon Software Solutions forum

See www.mushclient.com/spam for dealing with forum spam. Please read the MUSHclient FAQ!

[Folder]  Entire forum
-> [Folder]  SMAUG
. -> [Folder]  SMAUG coding
. . -> [Subject]  New Linux, New GCC, New Warnings

Home  |  Users  |  Search  |  FAQ
Username:
Register forum user name
Password:
Forgotten password?

New Linux, New GCC, New Warnings

[Reply to this subject]  Reply to this subject   [New subject]  Start a new subject   [Refresh] Refresh page


Pages: 1  2  3 

Posted by David Haley   USA  (3,881 posts)  [Biography] bio   Moderator
Date Reply #30 on Wed 16 Jan 2008 08:11 AM (UTC)  quote  ]
Message
SMAUG (and similar) code is notorious for having, err, somewhat sketchy code constructs. Some of these have already started cropping up as common errors, such as the 'invalid lvalue cast' one that comes up from time to time. SMAUG also uses const very poorly, and in fact generally doesn't use it at all. This makes life very complicated when you want to start doing things properly with 'const' in functions like one_argument, because it makes every calling location report an error unless it was using const (and most of them don't) -- but then fixing those just causes the error (or warning) to propagate backwards further.

I still think that forcing people to program correctly is a good thing, because many bugs are caused by things like this -- mishandling of strings, for instance, that wouldn't have happened had they been properly const'ed. But Samson is right in that this will cause all kinds of trouble for fixing it. It's a case where the small cost way back when to do things the right way would have prevented the very large cost most people are going to be faced with now if they upgrade gcc versions.

</soapbox> :-)

David Haley aka Ksilyan
Head Programmer,
Legends of the Darkstone

http://david.the-haleys.org
[Go to top] top

The dates and times for posts above are shown in Universal Co-ordinated Time (UTC).

To show them in your local time you can join the forum, and then set the 'time correction' field in your profile to the number of hours difference between your location and UTC time.


8,208 views.

This is page 3, subject is 3 pages long:  [Previous page]  1  2  3 

[Reply to this subject]  Reply to this subject   [New subject]  Start a new subject   [Refresh] Refresh page

Go to topic:           Search the forum


[Go to top] top

[Home]

Written by Nick Gammon - 5K

Comments to: Gammon Software support
[RH click to get RSS URL] Forum RSS feed ( http://www.gammon.com.au/rss/forum.xml )

[Best viewed with any browser - 2K]    [Internet Contents Rating Association (ICRA) - 2K]    [Web site powered by FutureQuest.Net]