John Messerly
e36fa2b3be
fix #26120 , sideways casts no longer supported
...
R=vsm@google.com
Review URL: https://codereview.chromium.org/2231273002 .
2016-08-12 14:32:36 -07:00
Konstantin Shcheglov
df4baa4332
Fix resolveRelativeUri() to handle correctly empty contained Uri(s).
...
This was breaking linking with `package` Uri(s).
I also added a new test that exhibits this behaviour.
R=brianwilkerson@google.com , paulberry@google.com
BUG=
Review URL: https://codereview.chromium.org/2242883003 .
2016-08-12 10:59:33 -07:00
Brian Wilkerson
c41427383b
Deprecate DirectoryBasedDartSdk and transition existing uses to the new API
...
R=scheglov@google.com
Review URL: https://codereview.chromium.org/2242853002 .
2016-08-12 09:18:12 -07:00
Brian Wilkerson
110c0f7e0e
Prototype for package-specific cache partitions
...
R=scheglov@google.com
Review URL: https://codereview.chromium.org/2237893002 .
2016-08-11 14:04:17 -07:00
Konstantin Shcheglov
fa11df13ca
Fix for updating documentationComment for top-level variables.
...
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org/2238443003 .
2016-08-10 10:29:12 -07:00
Brian Wilkerson
07850a6562
Remove false positive from override hint
...
R=scheglov@google.com
Review URL: https://codereview.chromium.org/2228233003 .
2016-08-10 06:12:41 -07:00
John Messerly
1c7aca0d6d
fix #25944 , improve Future.then inference
...
also fixes #25322 , return values of async functions are T | F<T>
R=leafp@google.com , vsm@google.com
Review URL: https://codereview.chromium.org/2208953002 .
2016-08-09 16:04:26 -07:00
Brian Wilkerson
b29c6bf330
Suppress follow-on errors when a file is imported with either a prefix or a show clause
...
R=scheglov@google.com
Review URL: https://codereview.chromium.org/2226613004 .
2016-08-09 11:11:39 -07:00
Konstantin Shcheglov
6df5ea27a5
Revert 6ad38498c8 (PARSED_UNIT).
...
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org/2231473002 .
2016-08-09 10:14:18 -07:00
Konstantin Shcheglov
6ad38498c8
Extract unresolved AST parsing (PARSED_UNIT1) from full parsing, which includes UriBasedDirective(s) resolution.
...
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org/2229603003 .
2016-08-08 14:45:27 -07:00
John Messerly
1bb6da7937
fix #26414 , infer return types of local functions
...
R=leafp@google.com
Review URL: https://codereview.chromium.org/2209293002 .
2016-08-05 07:25:14 -07:00
John Messerly
9599cd6f50
fix #26512 , correct handling of fuzzy arrows in strong mode LUB
...
R=leafp@google.com
Review URL: https://codereview.chromium.org/2215873002 .
2016-08-04 15:47:27 -07:00
Konstantin Shcheglov
52af64c7ff
Fix incremental resolution when inserting/removing empty lines before comments.
...
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org/2214943002 .
2016-08-04 11:48:05 -07:00
Brian Wilkerson
b888675b55
Move embedder locator and convert context builder to use the new API
...
R=scheglov@google.com
Review URL: https://codereview.chromium.org/2208503004 .
2016-08-04 10:41:53 -07:00
Brian Wilkerson
4dcb9b6196
Initial implementation for lazy compound assignment operators
...
R=scheglov@google.com
Review URL: https://codereview.chromium.org/2199323002 .
2016-08-02 09:16:17 -07:00
Konstantin Shcheglov
edcab027bc
Create synthetic FieldElement(s) (don't use non-synthetic ones) for non-synthetic class getters/setters.
...
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org/2199903002 .
2016-08-01 12:01:41 -07:00
Brian Wilkerson
16cc45417c
Make analyzer strong-mode clean
...
R=scheglov@google.com
Review URL: https://codereview.chromium.org/2196363003 .
2016-08-01 11:55:15 -07:00
Brian Wilkerson
51bda5ac48
Check for missing elements (issue 26987)
...
R=pquitslund@google.com
Review URL: https://codereview.chromium.org/2196483004 .
2016-07-29 13:19:55 -07:00
pq
722d4a13b0
Default trailing comma support to true ( #26647 ).
...
BUG=
R=brianwilkerson@google.com , scheglov@google.com
Review URL: https://codereview.chromium.org/2185873002 .
See: https://github.com/dart-lang/sdk/issues/26647 .
2016-07-27 09:42:12 -07:00
Konstantin Shcheglov
f4b1d502f3
Issue 26747. Report HintCode.UNDEFINED_SHOWN_NAME, but not HintCode.UNUSED_SHOWN_NAME for unresolved shown names.
...
R=pquitslund@google.com , brianwilkerson@google.com , srawlins@google.com
BUG= https://github.com/dart-lang/sdk/issues/26747
Review URL: https://codereview.chromium.org/2182593004 .
2016-07-26 10:36:29 -07:00
Konstantin Shcheglov
cc290c1dc0
Fix for false positive in field (not-)overriding.
...
Fields can also override setters.
R=pquitslund@google.com , brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org/2174423005 .
2016-07-25 22:49:01 -07:00
Konstantin Shcheglov
7808f167ec
Issue 26787. Report HintCode.OVERRIDE_ON_NON_OVERRIDING_GETTER for non-overriding fields.
...
R=pquitslund@google.com , brianwilkerson@google.com
BUG= https://github.com/dart-lang/sdk/issues/26787
Review URL: https://codereview.chromium.org/2182773002 .
2016-07-25 15:02:27 -07:00
Konstantin Shcheglov
f8c32c5ea1
Issue 26860. Report CompileTimeErrorCode.FIELD_INITIALIZER_OUTSIDE_CONSTRUCTOR for parameters of function typed constructor parameters.
...
R=pquitslund@google.com , brianwilkerson@google.com
BUG= https://github.com/dart-lang/sdk/issues/26860
Review URL: https://codereview.chromium.org/2178123003 .
2016-07-25 14:56:47 -07:00
pq
947a53193e
Cleanup unused imports.
...
BUG=
R=brianwilkerson@google.com
Review URL: https://codereview.chromium.org/2170913004 .
2016-07-21 13:25:00 -07:00
Brian Wilkerson
5cb949e513
Support references to operators in doc comments
...
R=scheglov@google.com
Review URL: https://codereview.chromium.org/2168833003 .
2016-07-21 09:13:02 -07:00
Konstantin Shcheglov
d02cfc433f
Fix for incremental resolution and strong mode comments.
...
Also run all incremental resolution tests in strong mode.
Fix for keeping strong mode results after incremental resolution.
R=brianwilkerson@google.com
BUG= https://github.com/dart-lang/sdk/issues/26911
Review URL: https://codereview.chromium.org/2164833003 .
2016-07-19 21:03:46 -07:00
Sam Rawlins
e60c1e4c59
Add an UNDEFINED_IDENTIFIER_AWAIT warning
...
BUG=https://github.com/dart-lang/sdk/issues/22625
R=brianwilkerson@google.com
Review URL: https://codereview.chromium.org/2156003004 .
2016-07-18 09:45:36 -07:00
John Messerly
8d2c6d033a
fix #25220 , infer generic type from constructor arguments
...
this makes it consistent in how constructors, generic functions, and literals are treated
includes changes in https://codereview.chromium.org/2115743002/
R=leafp@google.com
Review URL: https://codereview.chromium.org/2115173002 .
2016-07-12 16:16:25 -07:00
Brian Wilkerson
afd21330f7
Generalize the first argument in an assert to be an expression (issue 26865)
...
R=scheglov@google.com
Review URL: https://codereview.chromium.org/2140673004 .
2016-07-12 11:02:51 -07:00
Konstantin Shcheglov
ed887c09d1
Validate cache consistency asynchronously. Compute modification times of physical files in a separate isolate.
...
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org/2132073003 .
2016-07-08 15:01:05 -07:00
Konstantin Shcheglov
95fc17077b
When in-body incremantal resolution is performed, it should update REFERENCED_NAMES.
...
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org/2124413002 .
2016-07-07 14:04:10 -07:00
pq
aea4632375
Parser support for trailing commas ( #26647 ).
...
Adds parser support for trailing commas in parameter and argument lists.
Meta-tracking issue: https://github.com/dart-lang/sdk/issues/26644
In most cases, errors were preserved (and tested) across parsers with and without the flag set. (The exception is a formal paramater list with an extra comma, like `(a,,)` which with trailing comma support enabled only reports a missing identifier; needless to say this is captured in a test and is up for further debate.)
Amazingly (and for better or worse), turning this option on in the parser (`parseTrailingCommas = true`) produces NO errors in the analyzer and server tests.
BUG=26647
R=brianwilkerson@google.com
Review URL: https://codereview.chromium.org/2116853002 .
2016-07-01 13:50:06 -07:00
Sam Rawlins
1c30e2f20e
Clean up some supposedly failing tests
...
BUG=
R=brianwilkerson@google.com
Review URL: https://codereview.chromium.org/2093473002 .
2016-06-30 12:44:35 -07:00
Sam Rawlins
8a710c8589
ExitDetector: Examine continue when determining a 'do'
...
BUG=https://github.com/dart-lang/sdk/issues/26786
R=brianwilkerson@google.com , paulberry@google.com
Review URL: https://codereview.chromium.org/2102223002 .
2016-06-30 10:18:02 -07:00
Brian Wilkerson
9c5213a077
Generalize DartSdkManager to support embedder SDKs
...
R=pquitslund@google.com , scheglov@google.com
Review URL: https://codereview.chromium.org/2107793002 .
2016-06-28 13:48:57 -07:00
Konstantin Shcheglov
05f0b94dde
Fix for parsing not closed comment reference.
...
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org/2097233002 .
2016-06-27 08:48:23 -07:00
Konstantin Shcheglov
f8e2a6ced9
Token of an empty comment reference should end with EOF.
...
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org/2100553003 .
2016-06-25 09:07:13 -07:00
pq
38c132d604
Allow for library access to @protected protected members (linter#254).
...
R=brianwilkerson@google.com
Review URL: https://codereview.chromium.org/2100493002 .
Fixes: https://github.com/dart-lang/linter/issues/254
2016-06-24 15:05:33 -07:00
pq
f4c2a0faba
Analyzer support for @factory methods (linter#253).
...
R=brianwilkerson@google.com
Review URL: https://codereview.chromium.org/2096103002 .
Fixes: https://github.com/dart-lang/linter/issues/253 .
2016-06-24 14:41:00 -07:00
Konstantin Shcheglov
be5ebdb92d
More clean-ups after removing not-body incremenal resolution.
...
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org/2091023005 .
2016-06-24 11:29:19 -07:00
Konstantin Shcheglov
815c18e332
Remove DeclarationMarcher - incrementally resolve only BlockFunctionBody.
...
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org/2096763004 .
2016-06-23 18:08:51 -07:00
Sam Rawlins
1a3f7bbcc5
Fix instances where a loop 'always' exits, but also breaks, so it doesn't really exit.
...
BUG=https://github.com/dart-lang/sdk/issues/26755
R=brianwilkerson@google.com
Review URL: https://codereview.chromium.org/2091583002 .
2016-06-22 16:39:06 -07:00
Jaime Wren
279b2e39f6
Fix C&P error, rename ResourceUriResolverTest to BazelFileUriResolverTest
...
R=scheglov@google.com
Review URL: https://codereview.chromium.org/2082813002 .
2016-06-20 14:39:02 -07:00
Konstantin Shcheglov
e2afc0161b
Implement _SameResolutionValidator as AstComparator.
...
This required couple tweaks in AstComparator to make it possible to
override failing and comparision.
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org/2085553002 .
2016-06-20 09:17:28 -07:00
Konstantin Shcheglov
359e0d9d19
When copying TokenWithComment, use copy of its comments.
...
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org/2081603002 .
2016-06-20 09:09:35 -07:00
Jaime Wren
b7aff9c72f
Initial Bazel file resolver support.
...
R=brianwilkerson@google.com
Review URL: https://codereview.chromium.org/2079873002 .
2016-06-17 14:20:55 -07:00
Brian Wilkerson
5c97a88ddd
Remove embedder locator from analysis context
...
R=pquitslund@google.com , scheglov@google.com
Review URL: https://codereview.chromium.org/2078993002 .
2016-06-17 09:42:27 -07:00
Jaime Wren
f4ff1edcef
Provide direction to users of the now deprecated class FileUriResolver
...
R=brianwilkerson@google.com
Review URL: https://codereview.chromium.org/2078703002 .
2016-06-16 15:24:17 -07:00
Jaime Wren
7f244c8d39
Deprecate FileUriResolver and RelativeFileUriResolver in source_io.dart, replace the usages with ResourceUriResolver(PhysicalResourceProvider.INSTANCE).
...
R=brianwilkerson@google.com
Review URL: https://codereview.chromium.org/2060263006 .
2016-06-16 11:14:03 -07:00
pq
c113d65ad4
Don't flag improper @protected access in docs ( #26713 ).
...
BUG=
R=brianwilkerson@google.com
Review URL: https://codereview.chromium.org/2078493002 .
Fixes: https://github.com/dart-lang/sdk/issues/26713
2016-06-16 09:43:05 -07:00