Commit 7c499ce6 authored by gsamain's avatar gsamain Committed by Xavier Thompson

Forbid inheritance of non-activable bases for activable classes

parent a06bbf3a
......@@ -1541,6 +1541,8 @@ class CppClassNode(CStructOrUnionDefNode, BlockNode):
if self.activable:
activable_base = False
for base_type in base_types_list:
if not base_type.activable:
error(self.pos, "Activable class cannot inherit from not activable one.")
activable_base = activable_base or base_type.activable
if not activable_base:
from . import Builtin
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment