mirror of
https://github.com/github/codeql.git
synced 2025-12-20 10:46:30 +01:00
Should fix #2426. Essentially, we disregard expressions used inside annotations, if these annotations occur in a file that has `from __future__ import annotations`, as this prevents the annotations from being evaluated.
11 lines
157 B
Python
11 lines
157 B
Python
from __future__ import annotations
|
|
|
|
import dataclasses
|
|
import typing
|
|
|
|
import module2
|
|
|
|
@dataclasses.dataclass()
|
|
class Foo:
|
|
bars: typing.List[module2.Bar]
|