add comment about why the new check has been added
authorLuke Kenneth Casson Leighton <lkcl@lkcl.net>
Sat, 6 May 2023 09:07:28 +0000 (10:07 +0100)
committerLuke Kenneth Casson Leighton <lkcl@lkcl.net>
Fri, 2 Jun 2023 18:51:17 +0000 (19:51 +0100)
src/openpower/decoder/power_fields.py

index 892af1d86d1bd4236ace6dd0c993c925d7be609f..bb6a8efbe30cd362b08c0e5bde646705cd0e3549 100644 (file)
@@ -501,16 +501,16 @@ class DecodeFields:
                     form.append(l)
                     if len(form) <= 1:
                         continue
+                    # check separators line up with header
                     for i, ch in enumerate(l):
                         if ch != '|':
                             continue
                         if i >= len(form[0]) or form[0][i] != '|':
                             col = len(txt[lineno]) - len(txt[lineno].lstrip())
                             col += i + 1
-                            raise SyntaxError(
-                                "form line field separator ('|') "
-                                "with no corresponding separator in header",
-                                (self.fname, lineno + 1, col, txt[lineno]))
+                            raise SyntaxError("form line field separator ('|') "
+                                    "with no corresponding separator in header",
+                                    (self.fname, lineno + 1, col, txt[lineno]))
             if not reading_data:
                 assert l[0] == '#'
                 heading = l[1:].strip()