tools/mpy-tool.py: Raise exception if trying to freeze relocatable mpy.

pull/1/head
Damien George 2019-12-10 14:57:12 +11:00
parent 111d1ffb64
commit fc97d6d1b5
1 changed files with 3 additions and 0 deletions

View File

@ -474,6 +474,9 @@ class RawCodeNative(RawCode):
assert 0
def freeze(self, parent_name):
if self.prelude[2] & ~0x0f:
raise FreezeError('unable to freeze code with relocations')
self.freeze_children(parent_name)
# generate native code data