re.nim compiles again

This commit is contained in:
Araq 2013-05-01 00:28:11 +02:00
commit eaeb26f003

View file

@ -239,8 +239,9 @@ template `=~` *(s: string, pattern: TRegEx): expr =
## else: ## else:
## echo("syntax error") ## echo("syntax error")
## ##
bind maxSubPatterns
when not definedInScope(matches): when not definedInScope(matches):
var matches {.inject.}: array[0..re.maxSubPatterns-1, string] var matches {.inject.}: array[0..maxSubPatterns-1, string]
match(s, pattern, matches) match(s, pattern, matches)
# ------------------------- more string handling ------------------------------ # ------------------------- more string handling ------------------------------