镜像站点 · 本页由第三方 GitHub 只读镜像提供,非 GitHub 官方站点,不接受任何登录或凭据输入。前往 github.com
Skip to content

Exclude is bottlenecked by depth limit #53583

Description

@ufukbakan

When excluding a type from an unlimited type , it should calculate excluded type first but it doesnt. For example:

type NonZ = Exclude<string, 'Z'>;
const myval: NonZ = 'Z'; // doesnt give any error

Because of this bug many other bugs happens like :

interface HasNotZ {
  [key: NonZ]: number
}

const MyObj : HasNotZ = {
  Z: 123 // is still valid .... Should give an error
}

No activity

Activity on this issue will appear here.

Activity

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

    DuplicateAn existing issue was already created

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions