scc

simple c99 compiler
git clone git://git.simple-cc.org/scc
Log | Files | Refs | Submodules | README | LICENSE

strlen.c (127B)


      1 #include <string.h>
      2 
      3 #undef strlen
      4 
      5 size_t
      6 strlen(const char *s)
      7 {
      8 	const char *t;
      9 
     10 	for (t = s; *t; ++t)
     11 		;
     12 	return t - s;
     13 }