From 60a7d8b00f2d2094fae594084917ba89ab338f39 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Alexis=20Laferri=C3=A8re?= Date: Wed, 26 Aug 2015 10:09:46 -0400 Subject: [PATCH] contrib/objcwrapper: intro `ObjcMethod::is_init` MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Alexis Laferrière --- contrib/objcwrapper/src/objc_model.nit | 3 +++ 1 file changed, 3 insertions(+) diff --git a/contrib/objcwrapper/src/objc_model.nit b/contrib/objcwrapper/src/objc_model.nit index b2465c5..46589c9 100644 --- a/contrib/objcwrapper/src/objc_model.nit +++ b/contrib/objcwrapper/src/objc_model.nit @@ -48,6 +48,9 @@ class ObjcMethod # Return type as a `String` var return_type: String is noinit, writable + + # Does this method look like a constructor/method? + fun is_init: Bool do return params.first.name.has_prefix("init") end # Attribute of an `ObjcClass` -- 1.7.9.5