Mailing List Archive
tlug.jp Mailing List tlug archive tlug Mailing List Archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]argc loop . . . . . (was: Re: [tlug] Re: font encoding question)
- Date: Mon, 25 Jun 2007 10:33:00 -0400
- From: Jim <jep200404@example.com>
- Subject: argc loop . . . . . (was: Re: [tlug] Re: font encoding question)
- References: <14178ED3A898524FB036966D696494FB139B42@messenger.cv63.navy.mil> <87myyu68b6.fsf@uwakimon.sk.tsukuba.ac.jp>
"Stephen J. Turnbull" wrote: > for (i = 0; i <= argc; ++i) > printf ("There's nothing wrong with Unicode for Japanese.\n"); Even though there is no harm since argv[argc] is a null pointer and *argv[argc] is not accessed, "<= argc" is fingernails on a chalkboard, neverminding the novel use of argc to control non-argv stuff. If one is going to loop on argc, the C idiom is preferred: for (i=0;i<argc;i++) Also tolerable, but less readable, would be: while (*argv++!=(char *)0)
- Follow-Ups:
- argc loop . . . . . (was: Re: [tlug] Re: font encoding question)
- From: Stephen J. Turnbull
- References:
- [tlug] Re: font encoding question
- From: burlingk
- [tlug] Re: font encoding question
- From: Stephen J. Turnbull
Home | Main Index | Thread Index
- Prev by Date: Re: [tlug] Desktop Wars Query
- Next by Date: Re: Quoting for Thread Breaking Digest Replies (was Re: [tlug] Re: font encoding question)
- Previous by thread: [tlug] Re: font encoding question
- Next by thread: argc loop . . . . . (was: Re: [tlug] Re: font encoding question)
- Index(es):
Home Page Mailing List Linux and Japan TLUG Members Links