aboutsummaryrefslogtreecommitdiff
path: root/crowbar_reference_compiler
diff options
context:
space:
mode:
authorMelody Horn <melody@boringcactus.com>2020-12-23 00:53:58 -0700
committerMelody Horn <melody@boringcactus.com>2020-12-23 00:53:58 -0700
commit960e8c898dc0826d6dd5991f087fcd9d3ee6fcd1 (patch)
tree77fd2ff1fd1de6e153fe88bbaca5838ab129e098 /crowbar_reference_compiler
parentc7de22f575607a7966b6b592dbf81bd3f867a2e4 (diff)
downloadreference-compiler-960e8c898dc0826d6dd5991f087fcd9d3ee6fcd1.tar.gz
reference-compiler-960e8c898dc0826d6dd5991f087fcd9d3ee6fcd1.zip
fix some typing edge cases
Diffstat (limited to 'crowbar_reference_compiler')
-rw-r--r--crowbar_reference_compiler/ast.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/crowbar_reference_compiler/ast.py b/crowbar_reference_compiler/ast.py
index 37ce0da..142fa8e 100644
--- a/crowbar_reference_compiler/ast.py
+++ b/crowbar_reference_compiler/ast.py
@@ -347,7 +347,7 @@ class HeaderFile:
def get_declarations(self) -> List[Declaration]:
included_declarations = [x.get_declarations() for x in self.includes]
- own_declarations = [x for x in self.contents if isinstance(x, Declaration)]
+ own_declarations: List[Declaration] = [x for x in self.contents if isinstance(x, Declaration)]
all_declarations = included_declarations + [own_declarations]
return [x for l in all_declarations for x in l]
@@ -359,7 +359,7 @@ class ImplementationFile:
def get_declarations(self) -> List[Declaration]:
included_declarations = [x.get_declarations() for x in self.includes]
- own_declarations = [x for x in self.contents if isinstance(x, Declaration)]
+ own_declarations: List[Declaration] = [x for x in self.contents if isinstance(x, Declaration)]
all_declarations = included_declarations + [own_declarations]
return [x for l in all_declarations for x in l]