lua simple_inheritance like JR's javascript version