Re: [BUG][Code] crashing every 6 hours

From: George Greer (greerga@circlemud.org)
Date: 11/19/01


On Tue, 20 Nov 2001, John wrote:

>#define GET_RACE(ch)  (IS_MOB(ch) ? (ch)->mob_specials.race :
>(ch)->player_specials->saved.race)
[...]
>error C2106: '=' : left operand must be l-value

An expression isn't an l-value.  You can pull tricks like:

        #define GET_RACE(ch)  *(IS_MOB(ch) ? &xxx : &yyy)

See CHECK_PLAYER_SPECIAL in utils.h

--
George Greer
greerga@circlemud.org

--
   +---------------------------------------------------------------+
   | FAQ: http://qsilver.queensu.ca/~fletchra/Circle/list-faq.html |
   | Archives: http://post.queensu.ca/listserv/wwwarch/circle.html |
   +---------------------------------------------------------------+



This archive was generated by hypermail 2b30 : 12/06/01 PST