diff --git a/CHANGELOG.md b/CHANGELOG.md index a0d1ce3eab5..1bb1c6ab3a6 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,13 @@ Change Log === +v2.5.0 +--- +* Use TypeScript compiler `v1.6.2` +* [bugfixes] #637, #642, #650, #652 +* [bugfixes] fix various false positives in `no-unused-variable` rule (#570, #613, #663) +* Update project setup for latest VSCode (#662) + v2.5.0-beta --- * Use TypeScript compiler `v1.6.0-beta` diff --git a/package.json b/package.json index c84abe17899..c47cce51ca5 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "tslint", - "version": "2.5.0-beta", + "version": "2.5.0", "description": "a static analysis linter for TypeScript", "bin": { "tslint": "./bin/tslint" @@ -36,7 +36,7 @@ "grunt-tslint": "latest", "mocha": "^2.2.5", "tslint": "latest", - "typescript": "1.6.0-beta" + "typescript": "1.6.2" }, "license": "Apache-2.0" } diff --git a/src/tslint.ts b/src/tslint.ts index 1614389c60c..8863dc74dd8 100644 --- a/src/tslint.ts +++ b/src/tslint.ts @@ -33,7 +33,7 @@ module Lint { } export class Linter { - public static VERSION = "2.5.0-beta"; + public static VERSION = "2.5.0"; private fileName: string; private source: string; diff --git a/typings/typescriptServices.d.ts b/typings/typescriptServices.d.ts index 3d4418a9750..4ce3cd34cb5 100644 --- a/typings/typescriptServices.d.ts +++ b/typings/typescriptServices.d.ts @@ -1382,9 +1382,12 @@ declare namespace ts { } interface ResolvedModule { resolvedFileName: string; + isExternalLibraryImport?: boolean; + } + interface ResolvedModuleWithFailedLookupLocations { + resolvedModule: ResolvedModule; failedLookupLocations: string[]; } - type ModuleNameResolver = (moduleName: string, containingFile: string, options: CompilerOptions, host: ModuleResolutionHost) => ResolvedModule; interface CompilerHost extends ModuleResolutionHost { getSourceFile(fileName: string, languageVersion: ScriptTarget, onError?: (message: string) => void): SourceFile; getCancellationToken?(): CancellationToken; @@ -1394,7 +1397,7 @@ declare namespace ts { getCanonicalFileName(fileName: string): string; useCaseSensitiveFileNames(): boolean; getNewLine(): string; - resolveModuleNames?(moduleNames: string[], containingFile: string): string[]; + resolveModuleNames?(moduleNames: string[], containingFile: string): ResolvedModule[]; } interface TextSpan { start: number; @@ -1515,10 +1518,9 @@ declare namespace ts { const version: string; function findConfigFile(searchPath: string): string; function resolveTripleslashReference(moduleName: string, containingFile: string): string; - function resolveModuleName(moduleName: string, containingFile: string, compilerOptions: CompilerOptions, host: ModuleResolutionHost): ResolvedModule; - function nodeModuleNameResolver(moduleName: string, containingFile: string, host: ModuleResolutionHost): ResolvedModule; - function baseUrlModuleNameResolver(moduleName: string, containingFile: string, baseUrl: string, host: ModuleResolutionHost): ResolvedModule; - function classicNameResolver(moduleName: string, containingFile: string, compilerOptions: CompilerOptions, host: ModuleResolutionHost): ResolvedModule; + function resolveModuleName(moduleName: string, containingFile: string, compilerOptions: CompilerOptions, host: ModuleResolutionHost): ResolvedModuleWithFailedLookupLocations; + function nodeModuleNameResolver(moduleName: string, containingFile: string, host: ModuleResolutionHost): ResolvedModuleWithFailedLookupLocations; + function classicNameResolver(moduleName: string, containingFile: string, compilerOptions: CompilerOptions, host: ModuleResolutionHost): ResolvedModuleWithFailedLookupLocations; function createCompilerHost(options: CompilerOptions, setParentNodes?: boolean): CompilerHost; function getPreEmitDiagnostics(program: Program, sourceFile?: SourceFile, cancellationToken?: CancellationToken): Diagnostic[]; function flattenDiagnosticMessageText(messageText: string | DiagnosticMessageChain, newLine: string): string; @@ -1649,7 +1651,7 @@ declare namespace ts { trace?(s: string): void; error?(s: string): void; useCaseSensitiveFileNames?(): boolean; - resolveModuleNames?(moduleNames: string[], containingFile: string): string[]; + resolveModuleNames?(moduleNames: string[], containingFile: string): ResolvedModule[]; } interface LanguageService { cleanupSemanticCache(): void;