From: Alexandre Terrasa Date: Wed, 20 Apr 2016 05:54:21 +0000 (-0400) Subject: core: fix warnings in re X-Git-Url: http://nitlanguage.org core: fix warnings in re Signed-off-by: Alexandre Terrasa --- diff --git a/lib/core/re.nit b/lib/core/re.nit index 917ec4f..0ac109c 100644 --- a/lib/core/re.nit +++ b/lib/core/re.nit @@ -183,7 +183,7 @@ class Regex # Cache of a single `regmatch_t` to prevent many calls to `malloc` private var native_match: NativeMatchArray is lazy do native_match_is_init = true - return new NativeMatchArray.malloc(native.re_nsub+1) + return new NativeMatchArray.malloc(native.as(not null).re_nsub+1) end private var native_match_is_init = false