Konstantin Shcheglov
bd270935a5
Check bounds of type parameters of function type aliases.
...
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org/1967583002 .
2016-05-10 10:49:25 -07:00
Konstantin Shcheglov
038478ea77
Implement 'instantiate to bounds' feature in resynthesizer.
...
R=paulberry@google.com , brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org/1963593003 .
2016-05-10 09:58:06 -07:00
Konstantin Shcheglov
431e1b5e80
Issue 26427. Refine type of 'T + int' and 'T + double' when 'T extends num'.
...
R=brianwilkerson@google.com
BUG= https://github.com/dart-lang/sdk/issues/26427
Review URL: https://codereview.chromium.org/1957953004 .
2016-05-10 09:50:58 -07:00
Paul Berry
abd7a34476
Update dump_inferred_types to show an index of libraries and parts.
...
R=scheglov@google.com
Review URL: https://codereview.chromium.org/1962813002 .
2016-05-09 12:38:33 -07:00
Brian Wilkerson
61818c95a1
Convert some for-in loops for performance
...
R=scheglov@google.com
Review URL: https://codereview.chromium.org/1955373003 .
2016-05-09 11:01:16 -07:00
Paul Berry
ba61fde1b1
Fix reference sharing in the event that import prefixes are used.
...
R=scheglov@google.com
Review URL: https://codereview.chromium.org/1961753002 .
2016-05-08 19:40:26 -07:00
Paul Berry
6725cece3c
Fix AST-based type inference of enum types.
...
R=scheglov@google.com
Review URL: https://codereview.chromium.org/1957973002 .
2016-05-08 15:08:42 -07:00
Paul Berry
90dfbdd7d2
Fix AST summarization of synthetic function types and method tear-offs.
...
R=scheglov@google.com
Review URL: https://codereview.chromium.org/1960933002 .
2016-05-08 11:48:35 -07:00
Paul Berry
f10f138cd1
Drop trailing dynamic when dumping inferred types.
...
This makes it easier to compare the output of AST-based and
element-based summaries, since element-based summaries cannot
distinguish between implicit type arguments and explicitly-specified
type arguments that happen to match the default (usually `dynamic`).
R=scheglov@google.com
Review URL: https://codereview.chromium.org/1957133002 .
2016-05-08 11:36:22 -07:00
Paul Berry
c00b34b6f3
Fix InstanceFieldResolverVisitor to update element model.
...
R=leafp@google.com
Review URL: https://codereview.chromium.org/1956973002 .
2016-05-07 06:58:23 -07:00
Paul Berry
839216141a
Fix order of output of references with invokeMethodRef.
...
R=scheglov@google.com
Review URL: https://codereview.chromium.org/1955103003 .
2016-05-06 13:48:28 -07:00
Konstantin Shcheglov
4db64c34fe
Keep all type arguments in summaries - dynamic or not.
...
R=paulberry@google.com
BUG=
Review URL: https://codereview.chromium.org/1954203002 .
2016-05-06 12:13:03 -07:00
Paul Berry
45ea3a1938
Fix ast-based serialization of out-of-scope type parameters.
...
R=scheglov@google.com
Review URL: https://codereview.chromium.org/1956473004 .
2016-05-06 11:37:55 -07:00
Brian Wilkerson
8c244f03ad
Report when members indirectly inherited through a mixin are not implemented (issue 26411)
...
R=scheglov@google.com
Review URL: https://codereview.chromium.org/1951363003 .
2016-05-06 11:29:44 -07:00
Paul Berry
b992be5569
Fix a corner case of inferred types with function-typed parameters.
...
R=scheglov@google.com
Review URL: https://codereview.chromium.org/1950333003 .
2016-05-06 09:54:42 -07:00
Paul Berry
9dada87525
Fix summarization of inferred types which are function-typed params of typedefs.
...
R=scheglov@google.com
Review URL: https://codereview.chromium.org/1961533002 .
2016-05-06 09:30:06 -07:00
Konstantin Shcheglov
44e99952b3
Prepare for publishing analyzer 0.27.4-alpha.2
...
R=brianwilkerson@google.com , paulberry@google.com
BUG=
Review URL: https://codereview.chromium.org/1953933002 .
2016-05-05 15:22:26 -07:00
Konstantin Shcheglov
5082e6f8f2
Support for NamedExpression(s) as constructor initializer arguments.
...
R=paulberry@google.com
BUG=
Review URL: https://codereview.chromium.org/1952663006 .
2016-05-05 15:13:20 -07:00
Konstantin Shcheglov
2460938b14
Issue 25914. Fix for compound assignments like 'T += T'.
...
R=brianwilkerson@google.com
BUG= https://github.com/dart-lang/sdk/issues/25914
Review URL: https://codereview.chromium.org/1948293003 .
2016-05-05 14:30:39 -07:00
Konstantin Shcheglov
fef82ec1e8
Update mock SDK 'double'.
...
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org/1956443003 .
2016-05-05 14:12:53 -07:00
Brian Wilkerson
451547ba27
Do not fail when an enum constant is annotated (issue 26413)
...
R=jwren@google.com
Review URL: https://codereview.chromium.org/1958433002 .
2016-05-05 13:31:18 -07:00
Konstantin Shcheglov
a281a61d82
Replace 'allowTypeParameters' with 'numTypeArguments'.
...
With the final goal to get rid of it because we will move to providing
type arguments for all type parameters in order to implement the
'instantiate to bounds' feature.
R=paulberry@google.com
BUG=
Review URL: https://codereview.chromium.org/1948123003 .
2016-05-05 10:52:40 -07:00
Konstantin Shcheglov
11b9691b51
Issue 25914. Refine type of 'T + T' when 'T extends num' to 'T' in strong mode.
...
R=brianwilkerson@google.com
BUG= https://github.com/dart-lang/sdk/issues/25914
Review URL: https://codereview.chromium.org/1950983004 .
2016-05-05 10:11:39 -07:00
Paul Berry
5f3481e811
Skip local variables when dumping inferred types.
...
R=scheglov@google.com
Review URL: https://codereview.chromium.org/1956433002 .
2016-05-05 09:14:16 -07:00
Konstantin Shcheglov
597aaa15a4
Extract 'refineBinaryExpressionType' into TypeSystem.
...
This remove duplication and is also a preparation for fixing
https://github.com/dart-lang/sdk/issues/25914
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org/1953043002 .
2016-05-05 09:03:25 -07:00
Paul Berry
23323b27fc
Add typedef support to summary linker.
...
R=scheglov@google.com
Review URL: https://codereview.chromium.org/1951173005 .
2016-05-05 07:43:47 -07:00
Paul Berry
fca48b75de
Skip local functions when dumping inferred types.
...
R=scheglov@google.com
Review URL: https://codereview.chromium.org/1948103002 .
2016-05-04 11:29:38 -07:00
Konstantin Shcheglov
5e998d1e43
Resolve URIs of parts of imported libraries relative to importing library sources.
...
R=paulberry@google.com
BUG=
Review URL: https://codereview.chromium.org/1952683002 .
2016-05-04 08:40:42 -07:00
Paul Berry
6a6d635027
Use property accessor elements for type inference rather than top level variable elements.
...
This makes the behavior of the linker more consistent with the
language spec.
R=scheglov@google.com
Review URL: https://codereview.chromium.org/1951833003 .
2016-05-04 08:02:51 -07:00
Brian Wilkerson
08241e9072
More strong mode clean-up
...
R=scheglov@google.com
Review URL: https://codereview.chromium.org/1947813002 .
2016-05-04 07:42:46 -07:00
Paul Berry
c6086791e8
Generalize ReferenceableElementForLink to work with explicit getters.
...
R=scheglov@google.com
Review URL: https://codereview.chromium.org/1946933002 .
2016-05-03 21:04:58 -07:00
Paul Berry
db2e1df165
Fix a corner case of AST-based type inference with sequences of identifiers separated by '.'.
...
R=scheglov@google.com
Review URL: https://codereview.chromium.org/1949833002 .
2016-05-03 18:48:30 -07:00
Paul Berry
e2c51a289d
Implement PropertyAccessorElementForLink_Variable.getContainedName().
...
R=scheglov@google.com
Review URL: https://codereview.chromium.org/1949783002 .
2016-05-03 15:19:10 -07:00
Paul Berry
243e44074c
Use property accessor elements for type inference rather than field elements.
...
This makes the behavior of the linker more consistent with the
language spec.
R=scheglov@google.com
Review URL: https://codereview.chromium.org/1938403003 .
2016-05-03 14:50:05 -07:00
Konstantin Shcheglov
6aece2f7a6
Finer grain control over specifying which variables have invalid constant initializers.
...
As you noticed, we don't need to resynthesize anything if we know that
it is not a valid constant expression in advance. At the same time we
sometimes need to be able to test with both valid and invalid
initializers.
R=paulberry@google.com
BUG=
Review URL: https://codereview.chromium.org/1949603003 .
2016-05-03 14:32:14 -07:00
Konstantin Shcheglov
f97f22110f
Don't use ClassElementImpl - does not work well with summaries.
...
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org/1946743002 .
2016-05-03 13:27:21 -07:00
Konstantin Shcheglov
e79a2b1774
Implement 'assignToRef' resynthesizing.
...
The failing tests partially depend on your CL for adding all static
class members, although probably will require some more changes.
R=paulberry@google.com
BUG=
Review URL: https://codereview.chromium.org/1949693002 .
2016-05-03 13:02:56 -07:00
Paul Berry
f72f1e00b6
Support references to top level getters in the summary linker.
...
R=scheglov@google.com
Review URL: https://codereview.chromium.org/1944773002 .
2016-05-03 12:22:40 -07:00
Paul Berry
770ee1a744
Include all static class members in UnlinkedPublicName.members.
...
Previously, we only included names that could be referenced from
consts. This was a holdover from the initial implemenation, where
summaries only needed to encode information about the expressions used
in valid const declarations. Now, we also encode information about
expressions needed for type inference, which can refer to any static
class member.
R=scheglov@google.com
Review URL: https://codereview.chromium.org/1944023002 .
2016-05-03 12:20:52 -07:00
Konstantin Shcheglov
9e8723b6d2
Skip all local elements when comparing after AST based resynth.
...
R=paulberry@google.com
BUG=
Review URL: https://codereview.chromium.org/1940003002 .
2016-05-03 12:13:50 -07:00
Brian Wilkerson
132507e95c
Fix bug in summary deserialization
...
R=scheglov@google.com
Review URL: https://codereview.chromium.org/1946723002 .
2016-05-03 12:04:20 -07:00
Paul Berry
8c8d230a79
Support references to static getters in the summary linker.
...
R=scheglov@google.com
Review URL: https://codereview.chromium.org/1944733002 .
2016-05-03 09:08:04 -07:00
Paul Berry
c351cb3c37
Skip more initializers when dumping inferred types.
...
R=scheglov@google.com
Review URL: https://codereview.chromium.org/1939973002 .
2016-05-02 14:55:27 -07:00
Konstantin Shcheglov
339cf06a45
Serialize / resynthesize 'isAsynchronous' and 'isGenerator' flags.
...
R=paulberry@google.com
BUG=
Review URL: https://codereview.chromium.org/1936403002 .
2016-05-02 14:52:21 -07:00
pq
562b1f16b5
Alpha bump analyzer.
...
(For consumption by `flutter analyze`.)
BUG=
R=scheglov@google.com
Review URL: https://codereview.chromium.org/1937803004 .
2016-05-02 14:05:05 -07:00
Konstantin Shcheglov
4c76af4511
Fix for serializing annotations.
...
Instead of using artificial TypeName nodes we just pass all the required
information. This helps to avoid the situation when we mutate the AST
because we re-parent nodes in annotation.
It would be nice if annotations used the same AST structure as
instance creation :-(
R=paulberry@google.com
BUG=
Review URL: https://codereview.chromium.org/1943013002 .
2016-05-02 13:54:32 -07:00
Konstantin Shcheglov
f56a3c9765
All initializer expressions are serialized, even if not all of them are constants.
...
R=paulberry@google.com
BUG=
Review URL: https://codereview.chromium.org/1937223002 .
2016-05-02 10:42:35 -07:00
Sam Rawlins
68cadb3e71
Warn about @deprecated positional parameters
...
BUG=https://github.com/dart-lang/sdk/issues/22975
R=brianwilkerson@google.com , scheglov@google.com
Review URL: https://codereview.chromium.org/1936873002 .
2016-05-02 10:34:35 -07:00
Brian Wilkerson
91e2852659
Remove cast from AstNodeImpl._becomeParentOf
...
R=scheglov@google.com
Review URL: https://codereview.chromium.org/1939853002 .
2016-05-02 10:21:33 -07:00
Brian Wilkerson
df593ddd57
Remove a cast by creating node lists directly
...
R=scheglov@google.com
Review URL: https://codereview.chromium.org/1934153002 .
2016-05-02 07:54:17 -07:00