Commit Graph

1316 Commits

Author SHA1 Message Date
Eric Traut
75f54ec438 Fixed bug in error reporting for f-strings. 2019-10-02 22:52:07 -07:00
Eric Traut
8cfff9659f Fixed bug where unpack operation was not allowed in RHS of simple assignment.
Added support for unpack operation in return and yield expression.
2019-10-02 22:20:20 -07:00
Eric Traut
8b6c825fec Fixed bug that caused Callable type not to be assignable to generic Type[_T] parameter. 2019-09-30 11:01:10 -07:00
Eric Traut
532b3783e7 Fixed bug resulted in the second (optional) parameter of assert statements to go unanalyzed. 2019-09-29 21:59:43 -07:00
Eric Traut
e84a89b09a Simplified sourceFile module. 2019-09-29 18:53:31 -07:00
Eric Traut
1ecb17f7c6 Simplified method in Symbol module. 2019-09-29 18:53:23 -07:00
Eric Traut
41613c3192 Simplified getTypeForDeclaration method. 2019-09-28 22:26:28 -07:00
Eric Traut
e82288512c Published 1.0.67 2019-09-28 20:15:21 -07:00
Eric Traut
912071710b Combined expression type cache fields. 2019-09-28 20:11:52 -07:00
Eric Traut
4f2f66e275 Removed unused imports. 2019-09-28 19:43:32 -07:00
Eric Traut
dac2253965 Merge branch 'move_declarations3' 2019-09-28 19:40:10 -07:00
Eric Traut
3770ec3c0e Updated dependencies to latest version. 2019-09-28 19:40:02 -07:00
Eric Traut
0be098827c Fixed regression - back links were not being added for assignment parse nodes. 2019-09-28 19:36:15 -07:00
Eric Traut
cba65978c7 Moved more of declarations to binder. 2019-09-28 18:30:24 -07:00
Eric Traut
4a132e5421 Started to move declarations from analyzer to binder. 2019-09-28 16:33:11 -07:00
Eric Traut
1a46a94cf7 Fixed regression in binder that caused errors to be reported when anayzing builtins.pyi - don't add built-in types that are already declared in builtins.pyi. 2019-09-28 13:21:25 -07:00
Eric Traut
9f91e8bf22 Added support for the implicit "__class__" symbol that is added to all methods. 2019-09-28 10:04:59 -07:00
Eric Traut
9887a069d5 Fixed bug in type checker's handling of assignments to indexed expressions. It was not properly validating that the assigned type was appropriate. 2019-09-28 01:22:29 -07:00
Eric Traut
07229574c4 Removed types from declarations in preparation for moving most declaration creation from analyzer to binder. 2019-09-28 00:49:02 -07:00
Eric Traut
436ae7f4fc Fixed regression in lambda code. 2019-09-28 00:12:20 -07:00
Eric Traut
30c593be88 Moved evaluation of lambda expressions from type analyzer to expression evaluator. 2019-09-26 22:51:55 -07:00
Eric Traut
c612677547 Removed unused import. 2019-09-26 22:51:18 -07:00
Eric Traut
3d9c094918 Added support for enableTypeIngoreComments switch. 2019-09-26 19:50:07 -07:00
Eric Traut
294cc3d12c Fixed some typos in documentation. 2019-09-26 19:38:48 -07:00
Eric Traut
e0e87b3eb7 Implemented support for # type: ignore comments. 2019-09-26 19:20:07 -07:00
Eric Traut
e221d413b0 Published 1.0.66 2019-09-26 19:19:41 -07:00
Eric Traut
4bc97471d9 Fixed path parsing bugs that affect Windows platform. 2019-09-26 00:15:05 -07:00
Eric Traut
168629cc92 Fixed bug in handling of enums when using index operator. 2019-09-25 23:30:37 -07:00
Eric Traut
3f3e33e201 Added another test case. 2019-09-25 12:46:31 -07:00
Eric Traut
dc3014e000 Fixed recent regression (interaction between "expected type" logic for list/set/dict literals and type var matching) that caused the type checker to miss some errors. 2019-09-25 12:42:21 -07:00
Eric Traut
fc0f0d8e8b Fixed broken unit tests. 2019-09-25 00:05:49 -07:00
Eric Traut
6965c7c8a6 Improved compliance with PEP 484 by honoring "numeric tower" for all assignments.
Added support for comparison fallbacks (e.g. if < isn't supported, try >).
Generally improved handling of binary operators.
Solidified the rules for when to introduce a new member variable in a child class, overriding the same variable in the parent class.
2019-09-24 23:57:24 -07:00
Eric Traut
abc7a6a433 Made small improvement to completion provider. 2019-09-24 15:14:20 -07:00
Eric Traut
ece3d08002 Fixed handling of Tuple to match mypy behavior (and a clarified understanding of PEP 484). 2019-09-24 10:02:32 -07:00
Eric Traut
4c0003f663 Published 1.0.65 2019-09-23 22:30:33 -07:00
Eric Traut
2f0e3e2fdf Implemented alternative syntax for TypedDict. 2019-09-23 22:09:27 -07:00
Eric Traut
213427ea53 Fixed bug that caused public member variables with declared (annotated Literal types) to not accept a literal assigned value. 2019-09-23 20:36:27 -07:00
Eric Traut
f2dd164391 Fixed a few bugs in isDerivedFrom and _canAssignClassWithTypeArgs that caused some type violations to go unreported. 2019-09-23 20:20:58 -07:00
Eric Traut
e88a6e98f4 Changed Tuple to default to Tuple[...] rather than Tuple[] 2019-09-23 20:19:53 -07:00
Eric Traut
43f6b792bc Added hack in parser to avoid generating parse errors for strings inside of a Literal[] index statement. 2019-09-23 08:33:47 -07:00
Eric Traut
efc8ecf421 Started to implement support for TypedDict. 2019-09-23 00:32:07 -07:00
Eric Traut
9f283ee508 Updated typing_extensions.pyi file to reflect the latest in typeshed. 2019-09-22 19:06:37 -07:00
Eric Traut
ee1b911f42 Fixed small issue in combine method of datetime.pyi typeshed file. 2019-09-22 17:47:25 -07:00
Eric Traut
ca88b50d42 Simplified __add__ method in tuple. 2019-09-22 17:38:44 -07:00
Eric Traut
7b0aa89729 Updated typestub fallbacks to the latest typestubs from typeshed. 2019-09-22 17:09:40 -07:00
Eric Traut
36db2c8d53 Fixed type checks for functions and classes, which should be compatible with 'object'. 2019-09-22 17:09:18 -07:00
Eric Traut
d5e13278dc Published 1.0.64 2019-09-21 22:57:07 -07:00
Eric Traut
04c387e5f2 Removed console from AnalyzerFileInfo.
Fixed bug in type analyzer that caused some type checks relating to parameters to be missed.
Added to heuristic to determine when to strip literal type for private class member types.
2019-09-21 22:52:22 -07:00
Eric Traut
57ca2da3e6 Implemented type analysis support for comparison chaining. 2019-09-21 20:55:07 -07:00
Eric Traut
a109484776 Handled case where base type of call expression evaluates to a TypeVar type. 2019-09-21 20:29:13 -07:00