Main Page | Data Structures | Directories | File List | Data Fields | Globals | Related Pages

tcstring.c File Reference

A few support functions necessary for tcregsub. More...

#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <strings.h>
#include <ctype.h>
#include <limits.h>
#include "tcrip.h"

Go to the source code of this file.

Defines

#define hex(x)   (((x)<0x3a)? ((x)-'0'): (((x)<0x60)? ((x)-0x37): ((x)-0x57)))
 Copyright (C) 2003 Michael Ahlberg, Måns Rullgård.
#define bsub(c, e)   case c: *d = e; s++; break
#define ext(n)

Functions

static const char * escape (char *d, const char *s)
char * tcstrexp (const char *s, const char *sd, const char *ed, char fs, char *(*lookup)(char *, void *), void *ld, int flags)
 Something evil that tcregsub needs.
int tcstresc (char *dst, const char *src)


Detailed Description

A few support functions necessary for tcregsub.

Definition in file tcstring.c.


Define Documentation

#define bsub c,
 )     case c: *d = e; s++; break
 

Referenced by escape().

#define ext  ) 
 

Value:

do {                            \
    int o = p - expo;                           \
    expo = realloc(expo, l += n);                       \
    p = expo + o;                               \
} while(0)

Referenced by tcstrexp().

#define hex  )     (((x)<0x3a)? ((x)-'0'): (((x)<0x60)? ((x)-0x37): ((x)-0x57)))
 

Copyright (C) 2003 Michael Ahlberg, Måns Rullgård.

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

Definition at line 65 of file tcstring.c.

Referenced by escape().


Function Documentation

static const char* escape char *  d,
const char *  s
[static]
 

Definition at line 68 of file tcstring.c.

References bsub, and hex.

Referenced by tcstresc(), and tcstrexp().

int tcstresc char *  dst,
const char *  src
 

Definition at line 378 of file tcstring.c.

References escape().

char* tcstrexp const char *  s,
const char *  sd,
const char *  ed,
char  fs,
char *(*)(char *, void *)  lookup,
void *  ld,
int  flags
 

Something evil that tcregsub needs.

Don't ask me.

Definition at line 125 of file tcstring.c.

References escape(), ext, tcregsub(), tcstrexp(), TCSTREXP_ESCAPE, TCSTREXP_FREE, and TCSTREXP_KEEPUNDEF.

Referenced by tcregsub(), and tcstrexp().


Generated on Sun May 15 21:50:48 2005 for FinFlect by  doxygen 1.4.1