From 21934a7525d4b849683778f2f91b802c9b866e69 Mon Sep 17 00:00:00 2001 From: Michael Buesch Date: Sun, 12 Aug 2018 10:34:48 +0200 Subject: cython-patch: Rename magic comment Signed-off-by: Michael Buesch --- awlsim/core/cpu.py | 2 +- awlsim/core/lstack.py | 6 +++--- misc/setup_cython.py | 6 +++--- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/awlsim/core/cpu.py b/awlsim/core/cpu.py index ca05e664..72b8ebd7 100644 --- a/awlsim/core/cpu.py +++ b/awlsim/core/cpu.py @@ -2305,7 +2305,7 @@ class S7CPU(object): #+cdef " -> ..." if len(elems) > elemsMax else "")) frame = self.activeLStack.topFrame ret.extend(self.__dumpLStackFrame(" L: ", frame)) - frame = frame.prevFrame if frame else None #@cy-NoneToNULL + frame = frame.prevFrame if frame else None #+NoneToNULL ret.extend(self.__dumpLStackFrame(" VL: ", frame)) else: ret.append(" Calls: None") diff --git a/awlsim/core/lstack.py b/awlsim/core/lstack.py index 880df0d6..dd70e793 100644 --- a/awlsim/core/lstack.py +++ b/awlsim/core/lstack.py @@ -59,7 +59,7 @@ class LStackAllocator(object): #+cdef #@cy def __init__(self, uint32_t maxSize): # maxSize -> max size of the L-stack, in bytes. - self.topFrame = None #@cy-NoneToNULL + self.topFrame = None #+NoneToNULL self.resize(maxSize) # Reset all allocations on the L-stack. @@ -81,7 +81,7 @@ class LStackAllocator(object): #+cdef oldFrame = frame self.topFrame = frame = frame.prevFrame - oldFrame.prevFrame = None #@cy-NoneToNULL + oldFrame.prevFrame = None #+NoneToNULL self.__frameFreeSet.add(oldFrame) #@nocy #@cy PyMem_Free(oldFrame) @@ -124,7 +124,7 @@ class LStackAllocator(object): #+cdef else: self.topFrameOffset = make_AwlOffset(0, 0) - frame.prevFrame = None #@cy-NoneToNULL + frame.prevFrame = None #+NoneToNULL self.__frameFreeSet.add(frame) #@nocy #@cy PyMem_Free(frame) diff --git a/misc/setup_cython.py b/misc/setup_cython.py index ed9c5303..dbc55f85 100644 --- a/misc/setup_cython.py +++ b/misc/setup_cython.py @@ -96,7 +96,7 @@ def pyCythonPatch(fromFile, toFile): for line in infd.read().decode("UTF-8").splitlines(True): stripLine = line.strip() - if stripLine.endswith("#