Ruby  2.0.0p451(2014-02-24revision45167)
re.h
Go to the documentation of this file.
1 /**********************************************************************
2 
3  re.h -
4 
5  $Author: nobu $
6  created at: Thu Sep 30 14:18:32 JST 1993
7 
8  Copyright (C) 1993-2007 Yukihiro Matsumoto
9 
10 **********************************************************************/
11 
12 #ifndef RUBY_RE_H
13 #define RUBY_RE_H 1
14 
15 #if defined(__cplusplus)
16 extern "C" {
17 #if 0
18 } /* satisfy cc-mode */
19 #endif
20 #endif
21 
22 #include <sys/types.h>
23 #include <stdio.h>
24 
25 #include "ruby/regex.h"
26 
27 #if defined __GNUC__ && __GNUC__ >= 4
28 #pragma GCC visibility push(default)
29 #endif
30 
31 typedef struct re_pattern_buffer Regexp;
32 
33 struct rmatch_offset {
34  long beg;
35  long end;
36 };
37 
38 struct rmatch {
40 
44 };
45 
46 struct RMatch {
47  struct RBasic basic;
49  struct rmatch *rmatch;
50  VALUE regexp; /* RRegexp */
51 };
52 
53 #define RMATCH(obj) (R_CAST(RMatch)(obj))
54 #define RMATCH_REGS(obj) (&(R_CAST(RMatch)(obj))->rmatch->regs)
55 
57 long rb_reg_search(VALUE, VALUE, long, int);
59 long rb_reg_adjust_startpos(VALUE, VALUE, long, int);
60 void rb_match_busy(VALUE);
63 
64 #if defined __GNUC__ && __GNUC__ >= 4
65 #pragma GCC visibility pop
66 #endif
67 
68 #if defined(__cplusplus)
69 #if 0
70 { /* satisfy cc-mode */
71 #endif
72 } /* extern "C" { */
73 #endif
74 
75 #endif /* RUBY_RE_H */
Definition: re.h:46
long rb_reg_adjust_startpos(VALUE, VALUE, long, int)
Definition: re.c:1321
VALUE regexp
Definition: re.h:50
unsigned long VALUE
Definition: ripper.y:104
struct RBasic basic
Definition: re.h:47
VALUE rb_reg_regsub(VALUE, VALUE, struct re_registers *, VALUE)
Definition: re.c:3286
struct re_registers regs
Definition: re.h:39
int char_offset_num_allocated
Definition: re.h:42
long beg
Definition: re.h:34
Definition: ripper.y:699
void rb_match_busy(VALUE)
Definition: re.c:1189
long rb_reg_search(VALUE, VALUE, long, int)
Definition: re.c:1352
struct rmatch * rmatch
Definition: re.h:49
Definition: re.h:38
VALUE str
Definition: re.h:48
VALUE rb_reg_quote(VALUE)
Definition: re.c:2965
regex_t * rb_reg_prepare_re(VALUE re, VALUE str)
Definition: re.c:1282
struct rmatch_offset * char_offset
Definition: re.h:43
long end
Definition: re.h:35
VALUE rb_reg_regcomp(VALUE)
Definition: re.c:2547
int char_offset_updated
Definition: re.h:41