Logo Search packages:      
Sourcecode: sam2p version File versions

SimBuffer::B & SimBuffer::B::appendHppq ( const Flat other  ) 

Make `other' upper case (English), plus change all non-alpha chars to underscore.

Definition at line 1026 of file gensi.cpp.

References SimBuffer::Flat::beg, SimBuffer::Flat::len, and vi_grow2().

                                                             {
  vi_grow2(0, other.len, 0, 0);
  char *pend=const_cast<char*>(beg)+len;
  register char c, *p=pend-other.len;
  memcpy(p, other.beg, other.len);
  for (;p!=pend;pend++) {
    c=*p;
    *p++=(
      (c>='a' && c<='z') ? (char)(c-'a'+'A') :
      (c>='A' && c<='Z') ? c :
                           '_'
    );
  }
  return *this;
}


Generated by  Doxygen 1.6.0   Back to index