Sha256: 8a15264ad8e37cb442520076e652b599e80f435be72944c509e84752d1229f18

Contents?: true

Size: 1.04 KB

Versions: 33

Compression:

Stored size: 1.04 KB

Contents

/*
** $Id: lpcap.h,v 1.1 2013/03/21 20:25:12 roberto Exp $
*/

#if !defined(lpcap_h)
#define lpcap_h


#include "lptypes.h"


/* kinds of captures */
typedef enum CapKind {
  Cclose, Cposition, Cconst, Cbackref, Carg, Csimple, Ctable, Cfunction,
  Cquery, Cstring, Cnum, Csubst, Cfold, Cruntime, Cgroup
} CapKind;


typedef struct Capture {
  const char *s;  /* subject position */
  short idx;  /* extra info about capture (group name, arg index, etc.) */
  byte kind;  /* kind of capture */
  byte siz;  /* size of full capture + 1 (0 = not a full capture) */
} Capture;


typedef struct CapState {
  Capture *cap;  /* current capture */
  Capture *ocap;  /* (original) capture list */
  lua_State *L;
  int ptop;  /* index of last argument to 'match' */
  const char *s;  /* original string */
  int valuecached;  /* value stored in cache slot */
} CapState;


int runtimecap (CapState *cs, Capture *close, const char *s, int *rem);
int getcaptures (lua_State *L, const char *s, const char *r, int ptop);
int finddyncap (Capture *cap, Capture *last);

#endif


Version data entries

33 entries across 33 versions & 1 rubygems

Version Path
immunio-1.1.13 lua-hooks/ext/lpeg/lpcap.h
immunio-1.1.11 lua-hooks/ext/lpeg/lpcap.h
immunio-1.1.10 lua-hooks/ext/lpeg/lpcap.h
immunio-1.1.7 lua-hooks/ext/lpeg/lpcap.h
immunio-1.1.6 lua-hooks/ext/lpeg/lpcap.h
immunio-1.1.5 lua-hooks/ext/lpeg/lpcap.h
immunio-1.1.2 lua-hooks/ext/lpeg/lpcap.h
immunio-1.1.1 lua-hooks/ext/lpeg/lpcap.h
immunio-1.1.0 lua-hooks/ext/lpeg/lpcap.h
immunio-1.0.22 lua-hooks/ext/lpeg/lpcap.h
immunio-1.0.19 lua-hooks/ext/lpeg/lpcap.h
immunio-1.0.17 lua-hooks/ext/lpeg/lpcap.h
immunio-1.0.15 lua-hooks/ext/lpeg/lpcap.h
immunio-1.0.14 lua-hooks/ext/lpeg/lpcap.h
immunio-1.0.13 lua-hooks/ext/lpeg/lpcap.h
immunio-1.0.12 lua-hooks/ext/lpeg/lpcap.h
immunio-1.0.11 lua-hooks/ext/lpeg/lpcap.h
immunio-1.0.10 lua-hooks/ext/lpeg/lpcap.h
immunio-1.0.9 lua-hooks/ext/lpeg/lpcap.h
immunio-1.0.8 lua-hooks/ext/lpeg/lpcap.h