Commit Graph

15277 Commits

Author SHA1 Message Date
Paul Berry cefc4cc768 Perform type inference on explicitly typed fields.
R=scheglov@google.com

Review-Url: https://codereview.chromium.org/2905123002 .
2017-05-25 13:22:26 -07:00
Brian Wilkerson f65c7ecbdf Fix a recent regression with nested contexts
R=scheglov@google.com

Review-Url: https://codereview.chromium.org/2903303002 .
2017-05-25 13:17:08 -07:00
Brian Wilkerson 1c8b59dc31 Update status pages to show package map and plugins
R=scheglov@google.com

Review-Url: https://codereview.chromium.org/2904983003 .
2017-05-25 12:51:19 -07:00
Brian Wilkerson 50d0857f82 Add result interfaces used by AnalysisSession
R=scheglov@google.com

Review-Url: https://codereview.chromium.org/2908543002 .
2017-05-25 12:50:08 -07:00
Paul Berry 1e45167514 Update strong mode expectations to reflect kernel type parameter conventions.
When outputting the name of a type parameter, Kernel follows two
special conventions:

- It fully qualifies the name of the type parameter with respect to
  the scope of its declaration; so for example a type parameter `T` of
  a class `C` in a library `lib` might be annotated as `lib::C::T`.

- Within a factory constructor, type parameters of the class are
  annotated as though they are type parameters of the factory
  constructor (this is because factory constructors are represented in
  kernel as static methods).

This CL adjusts the strong mode type inference tests to reflect this
behavior (and modifies analyzer's front_end_inference_test so that
follows the kernel conventions).

R=scheglov@google.com

Review-Url: https://codereview.chromium.org/2909503004 .
2017-05-25 11:11:14 -07:00
Brian Wilkerson 013411c10b Allow plugins to provide completions for non-dart files
R=maxkim@google.com, scheglov@google.com

Review-Url: https://codereview.chromium.org/2910463002 .
2017-05-25 10:53:07 -07:00
Brian Wilkerson 7f5e1f260f Add a getNavigation request for plugins
R=mfairhurst@google.com, scheglov@google.com

Review-Url: https://codereview.chromium.org/2908523002 .
2017-05-25 10:51:24 -07:00
Vijay Menon 570f6de05b Remove unsafe flag from ddc sdk
One small step for man...

R=rnystrom@google.com

Review-Url: https://codereview.chromium.org/2910473002 .
2017-05-25 10:50:17 -07:00
Kevin Moore 2248502611 Add .gitignore to pkg/analyzer directory
R=pquitslund@google.com

Review-Url: https://codereview.chromium.org/2905883002 .
2017-05-25 09:57:48 -07:00
Alan Knight 0bb2d5e548 Update DDC html libraries to match SDK
BUG=
R=vsm@google.com

Review-Url: https://codereview.chromium.org/2899083007 .
2017-05-25 09:33:23 -07:00
Paul Berry 560cf61b3b Add type inference logic for cascade expressions.
R=ahe@google.com, scheglov@google.com

Review-Url: https://codereview.chromium.org/2903243002 .
2017-05-25 09:30:26 -07:00
Peter von der Ahé 9b4bc8b0ff Read file names from libraries.json, not URIs.
R=danrubel@google.com, scheglov@google.com

Review-Url: https://codereview.chromium.org/2906673002 .
2017-05-25 16:20:05 +02:00
Peter von der Ahé bcb2ea962b Complain about function literals not being constant expressions.
R=paulberry@google.com

Review-Url: https://codereview.chromium.org/2899343002 .
2017-05-25 16:02:30 +02:00
Peter von der Ahé 27761fd369 Read SDK and patches from a JSON file.
R=sigmund@google.com

Review-Url: https://codereview.chromium.org/2895983002 .
2017-05-25 15:57:57 +02:00
Paul Berry 8a92a2a79c Infer the types of initializing formals from the corresponding fields.
This inference is enabled for both strong and non-strong mode, since
it is mandated by the Dart 1.0 spec.

R=ahe@google.com, scheglov@google.com

Review-Url: https://codereview.chromium.org/2908453002 .
2017-05-25 04:47:44 -07:00
Dan Rubel 54d6e3a1c5 cleanup fasta token classes
* replace fasta.SymbolToken --> analyzer.Token
* replace fasta.BeginGroupToken --> analyzer.BeginToken
* replace fasta.SymbolToken.eof --> analyzer.Token.eof

R=scheglov@google.com

Review-Url: https://codereview.chromium.org/2899043006 .
2017-05-25 07:26:50 -04:00
danrubel 498a39ed61 delete obsolete scanner roundtrip test
Review-Url: https://codereview.chromium.org/2900303003 .
2017-05-24 21:07:25 -04:00
Konstantin Shcheglov 97d587520c Add LimitedBinaryPrinter, tests and switch incremental generator to it.
R=ahe@google.com, kmillikin@google.com, paulberry@google.com, sigmund@google.com
BUG=

Review-Url: https://codereview.chromium.org/2896493002 .
2017-05-24 16:17:28 -07:00
Konstantin Shcheglov 2b8fd9dee8 Transform async code only for source libraries.
R=ahe@google.com, kmillikin@google.com, paulberry@google.com, sigmund@google.com
BUG=

Review-Url: https://codereview.chromium.org/2905463002 .
2017-05-24 15:51:18 -07:00
Brian Wilkerson 6bff3433b7 Add navigation support in plugins
R=scheglov@google.com

Review-Url: https://codereview.chromium.org/2902193002 .
2017-05-24 15:06:18 -07:00
Dan Rubel 136698a734 remove fasta <--> analyzer token translation
R=ahe@google.com, scheglov@google.com

Review-Url: https://codereview.chromium.org/2902813005 .
2017-05-24 17:34:08 -04:00
Dan Rubel dff793d05f update lazy assignment operators
and remove scanLazyAssignmentOperators flag

R=ahe@google.com

Review-Url: https://codereview.chromium.org/2903063003 .
2017-05-24 17:05:02 -04:00
Vijay Menon 2187f5232d DDC cleanup
R=jacobr@google.com, jakemac@google.com

Review-Url: https://codereview.chromium.org/2902103005 .
2017-05-24 13:01:10 -07:00
Alan Knight b4b02daade Include DDC fixes to dart:html in the main version
BUG=
R=jacobr@google.com, vsm@google.com

Review-Url: https://codereview.chromium.org/2899173002 .
2017-05-24 12:49:13 -07:00
Vijay Menon 5919a12038 Library root fix for win
R=jakemac@google.com

Jacob: do we need a fix in jsDebuggingLibraryName too?  could that code be refactored - it looks like it duplicates a lot of logic.
Review-Url: https://codereview.chromium.org/2899363002 .
2017-05-24 12:10:47 -07:00
Paul Berry a21b9e5638 Remove AstFactory from the front end.
R=ahe@google.com, scheglov@google.com

Review-Url: https://codereview.chromium.org/2904673003 .
2017-05-24 11:28:12 -07:00
Sigmund Cherem 9fd47a08d1 Address follow up comments
R=ahe@google.com

Review-Url: https://codereview.chromium.org/2902643002 .
2017-05-24 11:20:40 -07:00
Sigmund Cherem 5f8bc4feb2 fasta: revert check for null fileUri in the error reporting of the verifier.
(as discussed in https://codereview.chromium.org/2894283002, we are reverting
this because we don't know how to reproduce this issue anymore. When it comes up
again we can either fix the issue or re-revert and include an explanation).

R=ahe@google.com

Review-Url: https://codereview.chromium.org/2902153003 .
2017-05-24 11:17:15 -07:00
Dan Rubel 6e981d0cbf enable analyzer scanner adapter generic method support
This turns on generic method support in the scanner adapter layer
and updates the token.offset when the analyzer scanner
is being used to parse generic method comments.

R=scheglov@google.com

Review-Url: https://codereview.chromium.org/2900963009 .
2017-05-24 13:37:52 -04:00
Paul Berry 6b100c007b Use declared return type for inference of return and yield statements.
R=ahe@google.com

Review-Url: https://codereview.chromium.org/2899073004 .
2017-05-24 09:28:26 -07:00
Paul Berry b9b949f436 Use FutureOr as the return context in async closures.
R=scheglov@google.com

Review-Url: https://codereview.chromium.org/2898373004 .
2017-05-24 08:24:13 -07:00
Vijay Menon 6402ad477d Use the dart2js patch for dart:convert to get latest type fixes
BUG=
R=floitsch@google.com

Review-Url: https://codereview.chromium.org/2896253003 .
2017-05-24 07:33:19 -07:00
Peter von der Ahé ddf5fc23f1 Improve analysis coverage.
R=johnniwinther@google.com

Review-Url: https://codereview.chromium.org/2904483002 .
2017-05-24 15:52:42 +02:00
Paul Berry e642722f42 Implement subtyping rules for FutureOr in kernel.
These rules are only enabled when in strong mode, so existing Dart 1.0
functionality should be unaffected.

R=kmillikin@google.com, scheglov@google.com

Review-Url: https://codereview.chromium.org/2900113002 .
2017-05-24 06:14:22 -07:00
Peter von der Ahé 61d855bb47 Prepare for development branch by updating externally-used API.
R=scheglov@google.com

Review-Url: https://codereview.chromium.org/2898183002 .
2017-05-24 14:32:45 +02:00
Peter von der Ahé 9ed1ba2c12 Temporarily uncomment logEvent to make build bot green.
Review-Url: https://codereview.chromium.org/2901273002 .
2017-05-24 12:04:19 +02:00
Johnni Winther 99538b2c13 Pull the member context from the current target
- the variable might be erroneous.

Review-Url: https://codereview.chromium.org/2901103003 .
2017-05-24 11:55:37 +02:00
Peter von der Ahé f5012090f9 New parser event needed to check case expressions.
R=paulberry@google.com

Review-Url: https://codereview.chromium.org/2900993002 .
2017-05-24 11:48:42 +02:00
Peter von der Ahé b6a78795e4 Fix various semantic nits that Fasta will detect.
R=johnniwinther@google.com, paulberry@google.com, scheglov@google.com

Review-Url: https://codereview.chromium.org/2897003003 .
2017-05-24 11:43:18 +02:00
Johnni Winther 7eec91c3bf Pass context class directly to KernelSsaBuilder
Review-Url: https://codereview.chromium.org/2899273002 .
2017-05-24 11:41:54 +02:00
Peter von der Ahé 9eb265439f Ensure DART_CONFIGURATION is exported and don't run code in checked mode.
R=paulberry@google.com, scheglov@google.com

Review-Url: https://codereview.chromium.org/2903593002 .
2017-05-24 11:20:45 +02:00
Peter von der Ahé e6a7a38022 Support being called as absolute path.
R=scheglov@google.com

Review-Url: https://codereview.chromium.org/2896033002 .
2017-05-24 11:07:53 +02:00
Johnni Winther ac07b3ce03 Type .targetElement as MemberEntity
+ decouple LocalsHandler from ExecutableElement

R=efortuna@google.com

Review-Url: https://codereview.chromium.org/2901823002 .
2017-05-24 10:23:33 +02:00
Johnni Winther a932d7fd51 Use KernelToElementMap (more) directly in KernelSsaBuilder
R=sigmund@google.com

Review-Url: https://codereview.chromium.org/2904493002 .
2017-05-24 10:18:48 +02:00
Johnni Winther ccc6c484b3 Create KernelSsaBuilder from KernelSsaBuilderTask
R=sigmund@google.com

Review-Url: https://codereview.chromium.org/2899983003 .
2017-05-24 10:12:20 +02:00
Johnni Winther b767ebaa71 Create SsaBuilderTask stub for KernelBackendStrategy
R=sigmund@google.com

Review-Url: https://codereview.chromium.org/2896853002 .
2017-05-24 10:04:32 +02:00
Johnni Winther f8dc775b44 Share more logic between the Ssa(Ast)Builder and SsaKernelBuilder
This is a preparational step towards generating SSA from kernel based elements.

R=sigmund@google.com

Review-Url: https://codereview.chromium.org/2893293002 .
2017-05-24 09:59:20 +02:00
Stephen Adams a545c5c31f Use failedAt in more places (constants, universe)
TBR=sigmund@google.com

BUG=

Review-Url: https://codereview.chromium.org/2900263002 .
2017-05-23 19:23:32 -07:00
Stephen Adams e7e7d0c1b4 Use failedAt in more places (misc2)
TBR=sigmnd@google.com

Review-Url: https://codereview.chromium.org/2905573002 .
2017-05-23 19:04:16 -07:00
Stephen Adams c7b3400eb5 Use failedAt in more places (misc)
TBR=sigmund@google.com

Review-Url: https://codereview.chromium.org/2904783002 .
2017-05-23 18:13:28 -07:00