Skip to content

Nameof on a generic type allows specifying bogus type arguments #7416

Closed

Description

@cartermp

Given this:

type C<'T>() = class end

let name = nameof C<int, string, PhillipCarter>

The code compiles and name is given "C".

This should fail to compile, since C<int, string, PhillipCarter> is not valid.

Activity

  1. added this to the Backlog milestone on Aug 16, 2019
  2. dsyme commented on Aug 19, 2019

    @dsyme
    Contributor

    Updated the issue :)

  3. dsyme commented on Jul 27, 2020

    @dsyme
    Contributor

    Thanks for this report. The fix is now part of the update to the preview feature at #8754

    I'll close this for now since it's tracked in #8754

  4. modified the milestones: Backlog, 16.8 on Aug 26, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions