elua: get rid of a warning
authorDaniel Kolesa <quaker66@gmail.com>
Thu, 17 Apr 2014 15:24:57 +0000 (16:24 +0100)
committerDaniel Kolesa <d.kolesa@samsung.com>
Tue, 10 Jun 2014 14:48:48 +0000 (15:48 +0100)
src/bin/elua/modules/lualian.lua

index ea03c04..ed35f2f 100644 (file)
@@ -505,8 +505,8 @@ local gen_class = function(classn)
     local mixins   = {}
     local ct = eolian.class_type
     for i, v in ipairs(inherits) do
-        local tp = eolian.class_type_get(v)
-        if tp == ct.REGULAR or tp == ct.ABSTRACT or v == "Eo_Base" then
+        local tp = (v ~= "Eo_Base") and eolian.class_type_get(v) or ct.REGULAR
+        if tp == ct.REGULAR or tp == ct.ABSTRACT then
             if parent then
                 error(classn .. ": more than 1 parent!")
             end