nitgg: correclty disable attr check with --no-check-attr-isset
authorJean Privat <jean@pryen.org>
Wed, 13 Aug 2014 13:59:08 +0000 (09:59 -0400)
committerJean Privat <jean@pryen.org>
Wed, 13 Aug 2014 13:59:08 +0000 (09:59 -0400)
Signed-off-by: Jean Privat <jean@pryen.org>

src/global_compiler.nit

index 322fcda..60b1c50 100644 (file)
@@ -675,7 +675,7 @@ class GlobalCompilerVisitor
                        var ta = a.intro.static_mtype.as(not null)
                        ta = self.resolve_for(ta, recv2)
                        var res2 = self.new_expr("((struct {t.c_name}*){recv})->{a.intro.c_name}", ta)
-                       if not ta isa MNullableType and not self.compiler.modelbuilder.toolcontext.opt_no_check_other.value then
+                       if not ta isa MNullableType and not self.compiler.modelbuilder.toolcontext.opt_no_check_attr_isset.value then
                                if ta.ctype == "val*" then
                                        self.add("if ({res2} == NULL) \{")
                                        self.add_abort("Uninitialized attribute {a.name}")