Re: Redoing Advance...

From: Daniel A. Koepke (dkoepke@circlemud.org)
Date: 11/09/01


On Fri, 9 Nov 2001, Daniel A. Koepke wrote:

> That's what str_cmp() is for.  Also, of course, a strcmp() on just the
> cases of all-caps and all-lowers is not sufficient, since there may be
> random casing within the string.  E.g., "iMmoRtal".  In any regard,
> you should use str_cmp().

As an addendum, I should note that one_argument() doesn't preserve case,
so strcmp(arg, "immortal") is sufficient.  You still may prefer the use of
str_cmp() for clarity, though.  (Or for safety, just in case you someday
remove the lowercasing from one_argument().)

-dak

--
   +---------------------------------------------------------------+
   | 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