$BJdB-(B($B$$$$$o$1(B?)003


#include$BK:$l$K$D$$$F(B(2001/5/29)

5/29$BF|IU$G$^$?@58mI=$,A}?#$7$F$7$^$$$^$7$?!#(B $B

$B$5$F!"$J$<$3$N$h$&$J%_%9$,H/@8$7$F$7$^$C$?$+$J$N$G$9$,!#(B

$B;d$O!"$3$NK\$N%5%s%W%k%W%m%0%i%`$r(BGCC$B$G%3%s%Q%$%k$7$?$N$G$9$,!"(B GCC$B$K$O$$$/$D$+(Bbuilt-in function$B$H$$$&$b$N$,$"$j$^$7$F!"(B $B$=$l$i$K$D$$$F$O%3%s%Q%$%i$,FCJL07$$$r$7$F$$$^$9!#(B $BIQHK$K;H$&4X?t$K$D$$$F%$%s%i%$%sE83+$9$k$J$I$N0U?^$,$"$k$N$G$7$g$&!#(B

GCC$B$N%^%K%e%"%k$h$j(B:

  -fno-builtin
    Don't recognize built-in functions that do not  be-
    gin  with  two leading underscores.  Currently, the
    functions affected include _exit, abort, abs, allo-
    ca,  cos,  exit,  fabs,  labs, memcmp, memcpy, sin,
    sqrt, strcmp, strcpy, and strlen.

$B$=$l$O$$$$$N$G$9$,!"(Bbuilt-in function$B$K$D$$$F$O!"(B -Wall$B%*%W%7%g%s$G7Y9p%l%Y%k$r>e$2$F$b!"(B $B%W%m%H%?%$%W@k8@$,$J$$$H$-$K7Y9p$rH/$7$J$$$N$G$9!#(B $B7Y9p$r=P$7$F$b$i$&$?$a$K$O!"(B-fno-builtin$B%*%W%7%g%s$rIU$1$kI,MW$,$"$j$^$9!#(B

$B$*$+$2$G!"

$B$=$l$K$7$F$b!"(BList1-5$B$G(Bctype.h$B$,H4$1$F$$$k$N$OFf$G$9$,(B... $B%3%s%Q%$%k8e!"869F$K0\$7$?8e$G?($C$F$7$^$C$?$+$b!#(B

$B$4LBOG$r$*$+$1$7$?$3$H$H!"BP1~$,CY$l$^$7$?$3$H$K$D$$$F$*OM$S$$$?$7$^$9!#(B 4$B:~$G=$@5M=Dj$G$9!#(B

$B!VBNEv$?$j!A!W$NJ}$O!"(Bbcc32$B$bDL$7$F$"$k$N$G$3$NLdBj$O$J$$$O$:$G$9!#(B


$B%]%$%s%?1i;;$r;H$&$H$-(B(2001/8/27)

$B$A$g$C$H8E$$OC$K$J$C$F$7$^$$$^$9$,!"(B $BF.$o$J$$%W%m%0%i%^(B$B!W$N(B2001/8/6$B7G:\J,(B $B!V$B$K!"0J2<$N$h$&$J5-=R$,$"$j$^$9!#(B

$BOC$OBX$o$C$F!"(BC$B$N%]%$%s%?$NOC$G!"(B $B%]%$%s%?(B($BFC$K%]%$%s%?1i;;(B)$B$O=PMh$k8B$j;H$o$J$$$h$&$K$7$^$7$g$&!"(B $B$C$F9M$(J}$,$"$j$^$9!#=PMh$k8B$jG[NsMWAG$N7A$GI=8=$7$^$7$g$&!"$H$$$&!#(B
$B$^$"!"%]%$%s%?$O$A$c$s$HM}2r$7$F;H$o$J$$$H(B($BM}2r$7$F;H$C$F$b(B?) $B%P%0$N29>2$K$J$j$,$A$@$7!"L5M}$K;H$&I,MW$OL5$$$N$+$bCN$l$^$;$s$,!"(B $B$G$b!"%]%$%s%?$r;H$&$H!"%3!<%I$,C;$/$J$C$F8+$d$9$/$J$k$s$8$c$J$$$+!"(B $B$C$F>l9g$b$"$j$^$7$F!D!#(B
$B$?$H$($P!"$3$s$J$N(B

    for (i = 0; hogehoge[i].fuga[0] != '\0'; i++)
        printf("%s\n", hogehoge[i].fuga);

$B$H!"$3$s$J$N(B

    for (p = hogehoge; *p->fuga != '\0'; p++)
        printf("%s\n", p->fuga);

$B$,$"$C$?$i!"8e$NNc$r9M$($k$N$bLLE]$@$+$i$3$N$^$^$K$7$F$*$3$&(B $B"+

$B!V(BC$B8@8l(B $B%]%$%s%?40A4@)GF!W$G$O!"(B $B!V(B3-3-5 $B%]%$%s%?1i;;$J$s$+;H$&$N$O$d$a$F$7$^$*$&!W(B $B$J$s$F>O$b$"$C$?$j$9$k$o$1$G!";d$O!"(BLepton$B$5$s$*$C$7$c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;k$9$k(B */
  for (line = buf; isspace(line); line++)
      ;

  /* $B0J8e$O!"(Bline$B$,G[Ns$G$"$k$+$N$h$&$K;H$($k(B */

$B$3$l$r%]%$%s%?1i;;$J$7$G=q$3$&$H$9$k$H!"(B $B0J2<$N$h$&$KJLES%k!<%W%+%&%s%?$rF3F~$7$J$1$l$P$J$j$^$;$s!#(B

  char buf[1024];
  char *line;
  int  i;
  (I%%%(B
  /* $B9TF,$N6uGr$rL5;k$9$k(B */
  for (i = 0; isspace(buf[i]); i++)
      ;
  line = &buf[i];

  /* $B0J8e$O!"(Bline$B$,G[Ns$G$"$k$+$N$h$&$K;H$($k(B */

$B$3$l$O$3$l$GJL$KLdBj$J$$$h$&$J5$$b$7$^$9$,(B... $B$3$NDxEY$N$3$H$G%m!<%+%kJQ?t$r$R$H$DA}$d$9$N$O(B $B7y$@$H$$$&$N$b$o$+$j$^$9!#(B

$B7k6I!"G[Ns$r!V$^$H$b$JG[Ns!W$H$7$F;H$&8B$j$K$*$$$F(B $B%]%$%s%?1i;;$OITMW$@$,!"(B $B!V$^$H$b$JG[Ns$G$O$G$-$J$$N"5;E*$J;H$$J}!W$r(B $B$9$k>l9g$K$O!"%]%$%s%?1i;;$r;H$C$?$[$&$,$9$C$-$j=q$1$k$3$H$,$"$k!"(B $B$H$$$&$3$H$N$h$&$J5$$,$7$^$9!#(B

Java$B$N%[%o%$%H%Z!<%Q!<(B

http://java.sun.com/docs/overviews/java/java-overview-1.html

$B$G$O!"!V(BInstead of pointer arithmetic, Java has true arrays.$B!W(B $B$D$^$j!"!V(BJava$B$K$O%]%$%s%?1i;;$J$s$F$$$$2C8:$G%"%V$J$$5!G=$NBe$o$j$K!"(B $B$A$c$s$H$7$?K\Ev$NG[Ns$,$"$k$s$@$<$$!#$9$4$$$@$m!W(B($B0ULu(B)$B$H(B $B8X$i$7$2$K=q$$$F$"$k$o$1$G$9$,!"$3$&$$$&!V$^$H$b$JG[Ns!W$G$O!"(B $B!V%]%$%s%?(Bline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