Implement foundation for detecting partially defined vars (#13601)
This diff lays the foundation for detecting partially defined variables.
Think of the following situation:
```
if foo():
x = 1
print(x) # Error: "x" may be undefined.
```
Now, mypy will generate the error in such a case.
Note that this diff is not complete. It still generates a lot of false
positives. Running it on mypy itself generated 182 errors.
Therefore, this feature is disabled by default and the error code
must be explicitly enabled. I will implement it in multiple PRs.