diff options
author | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 1999-10-25 11:35:44 -0200 |
---|---|---|
committer | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 1999-10-25 11:35:44 -0200 |
commit | bbab974717f9802066f56b939d4f053acc865f24 (patch) | |
tree | 8e982a1e6b3ffb533c9f419ff984ce985ee991d7 | |
parent | 910836fb53cb80e93de666526714bc51f2c63510 (diff) | |
download | lua-bbab974717f9802066f56b939d4f053acc865f24.tar.gz lua-bbab974717f9802066f56b939d4f053acc865f24.tar.bz2 lua-bbab974717f9802066f56b939d4f053acc865f24.zip |
details (comments)
-rw-r--r-- | lstrlib.c | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -1,5 +1,5 @@ | |||
1 | /* | 1 | /* |
2 | ** $Id: lstrlib.c,v 1.33 1999/08/10 12:55:56 roberto Exp roberto $ | 2 | ** $Id: lstrlib.c,v 1.34 1999/08/16 20:52:00 roberto Exp roberto $ |
3 | ** Standard library for strings and pattern-matching | 3 | ** Standard library for strings and pattern-matching |
4 | ** See Copyright Notice in lua.h | 4 | ** See Copyright Notice in lua.h |
5 | */ | 5 | */ |
@@ -334,12 +334,12 @@ static const char *match (const char *s, const char *p, struct Capture *cap) { | |||
334 | if (isdigit((unsigned char)(*(p+1)))) { /* capture? */ | 334 | if (isdigit((unsigned char)(*(p+1)))) { /* capture? */ |
335 | s = match_capture(s, *(p+1), cap); | 335 | s = match_capture(s, *(p+1), cap); |
336 | if (s == NULL) return NULL; | 336 | if (s == NULL) return NULL; |
337 | p+=2; goto init; /* else return match(p+2, s, cap) */ | 337 | p+=2; goto init; /* else return match(s, p+2, cap) */ |
338 | } | 338 | } |
339 | else if (*(p+1) == 'b') { /* balanced string? */ | 339 | else if (*(p+1) == 'b') { /* balanced string? */ |
340 | s = matchbalance(s, p+2, cap); | 340 | s = matchbalance(s, p+2, cap); |
341 | if (s == NULL) return NULL; | 341 | if (s == NULL) return NULL; |
342 | p+=4; goto init; /* else return match(p+4, s, cap); */ | 342 | p+=4; goto init; /* else return match(s, p+4, cap); */ |
343 | } | 343 | } |
344 | else goto dflt; /* case default */ | 344 | else goto dflt; /* case default */ |
345 | case '\0': /* end of pattern */ | 345 | case '\0': /* end of pattern */ |