GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Config noImplicitAny seems to be not working since typescript 2.1 · Issue #18679 · microsoft/TypeScript

Config noImplicitAny seems to be not working since typescript 2.1 #18679

New issue
Copy link
New issue
Copy link
Closed
Closed
Config noImplicitAny seems to be not working since typescript 2.1#18679
Copy link
Labels
Working as IntendedThe behavior described is the intended behavior; this is not a bugThe behavior described is the intended behavior; this is not a bug

Description

@Flarna
Gerhard Stöbich (Flarna)
opened on Sep 22, 2017
Issue body actions

TypeScript Version: 2.5.2 / nightly (2.6.0-dev.20170922)

Code
tsconfig.json with noImplicitAny set to true:

{
  "compilerOptions": {
    "target": "es5",
    "module": "commonjs",
    "strict": true,
    "noImplicitAny": true
  }
}

Creating a variable without specifying a type:

let i;
i = 5;
i = "foo";

Expected behavior:
Typescript compiler complains that i is implicit any.

Actual behavior:
Typescript compile does not report any issue.

If I use typescript 2.0.10 (with adapted tsconfig.json) I get "error TS7005: Variable 'i' implicitly has an 'any' type." as expected.

Activity

  1. Gerhard Stöbich (Flarna)
    changed the title [-]Config noImplicitAny seems to be not working[/-] [+]Config noImplicitAny seems to be not working since typescript 2.1[/+] on Sep 22, 2017
  2. HerringtonDarkholme commented on Sep 22, 2017

    @HerringtonDarkholme
    Herrington Darkholme (HerringtonDarkholme)
    on Sep 22, 2017
    Contributor
    More actions

    Actually it is a new feature.

    #11263

  3. Daniel Rosenwasser (DanielRosenwasser)
    added
    Working as IntendedThe behavior described is the intended behavior; this is not a bugThe behavior described is the intended behavior; this is not a bug
    on Sep 22, 2017
  4. Flarna commented on Sep 22, 2017

    @Flarna
    Gerhard Stöbich (Flarna)
    on Sep 22, 2017
    Author
    More actions

    Ah ok thanks, thats fine.
    Seems I got confused by VsCode which shows let i: any if I hover my mouse pointer over the statement i = 5.

  5. Gerhard Stöbich (Flarna)
    closed this as completedon Sep 22, 2017
  6. microsoft
    locked and limited conversation to collaborators on Jun 14, 2018
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

    Working as IntendedThe behavior described is the intended behavior; this is not a bugThe behavior described is the intended behavior; this is not a bug

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

      You are visitor 01402503 — GeezerVison does not store the pages you look up.
      Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.