Lines Matching +defs:no +defs:code

25 #define BEG(no) (regs->beg[(no)])
26 #define END(no) (regs->end[(no)])
483 * <code>#inspect</code> actually produces the more natural version of
484 * the string than <code>#to_s</code>.
505 * <code>(?opts:source)</code> notation. This string can be fed back in to
506 * <code>Regexp::new</code> to a regular expression with the same semantics as
507 * the original. (However, <code>Regexp#==</code> may not return true when
509 * differ, as the example shows). <code>Regexp#inspect</code> produces a
675 * Regexp (see <code>Regexp::new</code> for details. Note that additional bits
677 * expression code. These extra bits are ignored if the options are passed to
678 * <code>Regexp::new</code>.
766 * If there are no named captures, an empty hash is returned.
831 * <code>MatchData</code> is the type of the special variable <code>$~</code>,
832 * and is the type of the object returned by <code>Regexp#match</code> and
833 * <code>Regexp.last_match</code>. It encapsulates all the results of a pattern
835 * <code>$&</code>, <code>$'</code>, <code>$`</code>, <code>$1</code>,
836 * <code>$2</code>, and so on.
1494 * Equivalent to the special variable <code>$`</code>.
1521 * Equivalent to the special variable <code>$'</code>.
1627 * Because <code>to_a</code> is called when expanding
1628 * <code>*</code><em>variable</em>, there's a useful assignment
1651 * Returns the array of captures; equivalent to <code>mtch.to_a[1..-1]</code>.
1691 * Match Reference -- <code>MatchData</code> acts as an array, and may be
1692 * accessed using the normal array indexing techniques. <code>mtch[0]</code>
1693 * is equivalent to the special variable <code>$&</code>, and returns the
1694 * entire matched string. <code>mtch[1]</code>, <code>mtch[2]</code>, and so
1811 * Returns a frozen copy of the string passed in to <code>match</code>.
1915 int code;
1930 case '\\': code = '\\'; break;
1931 case 'n': code = '\n'; break;
1932 case 't': code = '\t'; break;
1933 case 'r': code = '\r'; break;
1934 case 'f': code = '\f'; break;
1935 case 'v': code = '\013'; break;
1936 case 'a': code = '\007'; break;
1937 case 'e': code = '\033'; break;
1943 code = scan_oct(p, end < p+3 ? end-p : 3, &len);
1948 code = scan_hex(p, end < p+2 ? end-p : 2, &len);
1968 code = *p++;
1992 code = *p++;
2003 if (code < 0 || 0xff < code) {
2004 errcpy(err, "invalid escape code");
2009 code &= 0x1f;
2011 code |= 0x80;
2014 return code;
2070 check_unicode_range(unsigned long code, onig_errmsg_buffer err)
2072 if ((0xd800 <= code && code <= 0xdfff) || /* Surrogates */
2073 0x10ffff < code) {
2113 unsigned long code;
2119 code = ruby_scan_hex(p, end-p, &len);
2127 if (append_utf8(code, buf, encp, err) != 0)
2150 unsigned long code;
2156 code = ruby_scan_hex(p, 4, &len);
2161 if (append_utf8(code, buf, encp, err) != 0)
2207 no need to unescape anyway.
2337 rb_raise(rb_eArgError, "no arguments given");
2591 * the same character set code, and their <code>casefold?</code> values are the
2706 * If <code>=~</code> is used with a regexp literal with named captures,
2731 * A regexp interpolation, <code>#{}</code>, also disables
2797 * Match---Matches <i>rxp</i> against the contents of <code>$_</code>.
2798 * Equivalent to <code><i>rxp</i> =~ $_</code>.
2829 * Returns a <code>MatchData</code> object describing the match, or
2830 * <code>nil</code> if there was no match. This is equivalent to retrieving the
2831 * value of the special variable <code>$~</code> following a normal match.
2881 * Synonym for <code>Regexp.new</code>
2901 * When the +kcode+ parameter is `n' or `N' sets the regexp no encoding.
3068 * expression. Returns a new escaped string, or self if no characters are
3070 * <code>Regexp.new(Regexp.escape(<i>str</i>))=~<i>str</i></code> will be true.
3242 * Return a <code>Regexp</code> object that is the union of the given
3245 * Strings. If no patterns are given, returns <code>/(?!)/</code>.
3290 int no, clen;
3331 no = c - '0';
3349 no = name_to_backref_number(regs, regexp, name, name_end);
3363 no = 0;
3375 no = regs->num_regs-1;
3376 while (BEG(no) == -1 && no > 0) no--;
3377 if (no == 0) continue;
3389 if (no >= 0) {
3390 if (no >= regs->num_regs) continue;
3391 if (BEG(no) == -1) continue;
3392 rb_enc_str_buf_cat(val, RSTRING_PTR(src)+BEG(no), END(no)-BEG(no), src_enc);
3407 rb_warn("variable $KCODE is no longer effective");
3414 rb_warn("variable $KCODE is no longer effective; ignored");
3420 rb_warn("variable $= is no longer effective");
3427 rb_warn("variable $= is no longer effective; ignored");
3456 * variable <code>$~</code> (see Special global variables in Regexp for
3513 * A <code>Regexp</code> holds a regular expression, used to match a pattern
3514 * against strings. Regexps are created using the <code>/.../</code> and
3515 * <code>%r{...}</code> literals, and by the <code>Regexp::new</code>