header.py

changeset 56
ed6d39c59e56
parent 54
0c686d10eb49
child 59
0f3e70a2bb4b
--- a/header.py	Sat Jun 01 10:47:27 2019 +0300
+++ b/header.py	Sat Jun 01 10:47:58 2019 +0300
@@ -43,7 +43,14 @@
     linetypes.ConditionalLine,
 ]
 
+def is_invertnext(entry):
+    return isinstance(entry, linetypes.MetaCommand) \
+        and entry.text == "BFC INVERTNEXT"
+
 def is_suitable_header_object(entry):
+    if is_invertnext(entry):
+        # BFC INVERTNEXT is not a header command anymore.
+        return False
     return not any(
         isinstance(entry, linetype)
         for linetype in [

mercurial