Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Every TypeSymbolWithAnnotations should have an explicit NonNullTypes context #28766

Closed
jcouv opened this issue Jul 22, 2018 · 1 comment
Closed
Assignees
Milestone

Comments

@jcouv
Copy link
Member

jcouv commented Jul 22, 2018

We currently have some overload of Create which default to placeholder contexts (NonNullTypesTrueContext or NonNullTypesFalseContext).

Those overloads should be removed and proper/explicit contexts should be used in most places, if not all.

        ' The NonNullTypes context for nested tuple types is using a dummy rather than actual context from surrounding code.
        ' This does not affect `IsNullable`, but it affects `IsAnnotatedWithNonNullTypesContext`, which is used in comparisons.
        ' So when we copy modifiers (re-applying nullability information, including actual NonNullTypes context), we make the comparison fail.
        ' I think the solution is to never use a dummy context, even for value types.
        <Fact(Skip:="PROTOTYPE(NullableReferenceTypes): Hitting assertion in  CopyTypeCustomModifiers")>
        Public Sub TupleNamesFromCS001()

Relates to #28487

@cston
Copy link
Member

cston commented Aug 29, 2018

See #29344.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants