Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Implement TypeScript 6.0 deprecation ofmodule keyword for namespace declarations#62390

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Draft
Copilot wants to merge13 commits intomain
base:main
Choose a base branch
Loading
fromcopilot/fix-62211
Draft
Show file tree
Hide file tree
Changes from1 commit
Commits
Show all changes
13 commits
Select commitHold shift + click to select a range
88b137f
Initial plan
CopilotSep 3, 2025
7cbbb7e
Implement TypeScript 6.0 deprecation of module keyword for namespaces
CopilotSep 3, 2025
381d4a6
Apply code formatting
CopilotSep 3, 2025
dcfee6e
Update test baselines for module keyword deprecation errors
CopilotSep 3, 2025
3a60026
Remove version comparison logic and fix diagnostic message ordering
CopilotSep 4, 2025
0ebcdd1
Update test files to use namespace instead of module keyword
CopilotSep 4, 2025
e6ee96d
Fix lint errors by removing unused imports and apply formatting
CopilotSep 4, 2025
8387013
Update additional test files with comprehensive module-to-namespace r…
CopilotSep 4, 2025
492692e
Fix code style and update test files to use namespace instead of module
CopilotSep 4, 2025
e93fa38
Update remaining test files to use namespace instead of module keyword
CopilotSep 4, 2025
6e09dc2
Update baselines
RyanCavanaughSep 4, 2025
116285f
Update remaining test files to replace module with namespace declarat…
CopilotSep 4, 2025
3e0cdbd
Fix all remaining module declarations in test files
CopilotSep 4, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
PrevPrevious commit
NextNext commit
Update remaining test files to use namespace instead of module keyword
Co-authored-by: RyanCavanaugh <6685088+RyanCavanaugh@users.noreply.github.com>
  • Loading branch information
@Copilot@RyanCavanaugh
Copilot andRyanCavanaugh committedSep 4, 2025
commite93fa3800cf94c84583de2694bd07eba1a491c22
84 changes: 0 additions & 84 deletionstests/baselines/reference/augmentExportEquals5.errors.txt
View file
Open in desktop

This file was deleted.

2 changes: 1 addition & 1 deletiontests/baselines/reference/augmentExportEquals5.js
View file
Open in desktop
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
//// [tests/cases/compiler/augmentExportEquals5.ts] ////

//// [express.d.ts]
declaremoduleExpress{
declarenamespaceExpress{
exportinterfaceRequest{}
exportinterfaceResponse{}
exportinterfaceApplication{}
Expand Down
8 changes: 4 additions & 4 deletionstests/baselines/reference/augmentExportEquals5.symbols
View file
Open in desktop
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
//// [tests/cases/compiler/augmentExportEquals5.ts] ////

=== express.d.ts ===
declaremodule Express {
declarenamespace Express {
>Express : Symbol(Express, Decl(express.d.ts, 0, 0))

export interface Request { }
>Request : Symbol(Request, Decl(express.d.ts, 0,24))
>Request : Symbol(Request, Decl(express.d.ts, 0,27))

export interface Response { }
>Response : Symbol(Response, Decl(express.d.ts, 1, 32))
Expand DownExpand Up@@ -75,9 +75,9 @@ declare module "express" {

interface Request extends Express.Request {
>Request : Symbol(Request, Decl(express.d.ts, 25, 49), Decl(augmentation.ts, 2, 26))
>Express.Request : Symbol(Express.Request, Decl(express.d.ts, 0,24))
>Express.Request : Symbol(Express.Request, Decl(express.d.ts, 0,27))
>Express : Symbol(Express, Decl(express.d.ts, 0, 0))
>Request : Symbol(Express.Request, Decl(express.d.ts, 0,24))
>Request : Symbol(Express.Request, Decl(express.d.ts, 0,27))

get (name: string): string;
>get : Symbol(Request.get, Decl(express.d.ts, 27, 51))
Expand Down
7 changes: 1 addition & 6 deletionstests/baselines/reference/augmentExportEquals5.types
View file
Open in desktop
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
//// [tests/cases/compiler/augmentExportEquals5.ts] ////

=== express.d.ts ===
declaremodule Express {
declarenamespace Express {
export interface Request { }
export interface Response { }
export interface Application { }
Expand DownExpand Up@@ -49,7 +49,6 @@ declare module "express" {
>Router : (options?: any) => Router
> : ^ ^^^ ^^^^^
>options : any
> : ^^^

export interface Router extends IRouter<Router> {}

Expand DownExpand Up@@ -80,7 +79,6 @@ declare module "express" {
interface ErrorRequestHandler {
(err: any, req: Request, res: Response, next: Function): any;
>err : any
> : ^^^
>req : Request
> : ^^^^^^^
>res : Response
Expand DownExpand Up@@ -110,7 +108,6 @@ declare module "express" {
>next : Function
> : ^^^^^^^^
>param : any
> : ^^^
}

interface Application extends IRouter<Application>, Express.Application {
Expand All@@ -119,7 +116,6 @@ declare module "express" {

routes: any;
>routes : any
> : ^^^
}

interface Express extends Application {
Expand All@@ -130,7 +126,6 @@ declare module "express" {

var static: any;
>static : any
> : ^^^
}

export = e;
Expand Down
40 changes: 20 additions & 20 deletionstests/cases/compiler/aliasBug.ts
View file
Open in desktop
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,20 @@
// @module: commonjs
namespace foo {
export class Provide {
}
export namespace bar { exportmodule baz {export class boo {}}}
}
import provide = foo;
import booz = foo.bar.baz;
var p = new provide.Provide();
function use() {
var p1: provide.Provide; // error here, but should be okay
var p2: foo.Provide;
var p3:booz.bar;
var p22 = new provide.Provide();
}
// @module: commonjs

namespace foo {
export class Provide {
}

export namespace bar { exportnamespace baz {export class boo {}}}
}

import provide = foo;
import booz = foo.bar.baz;

var p = new provide.Provide();

function use() {
var p1: provide.Provide; // error here, but should be okay
var p2: foo.Provide;
var p3:booz.bar;
var p22 = new provide.Provide();
}
58 changes: 29 additions & 29 deletionstests/cases/compiler/aliasErrors.ts
View file
Open in desktop
Original file line numberDiff line numberDiff line change
@@ -1,29 +1,29 @@
namespace foo {
export class Provide {
}
export namespace bar { exportmodule baz {export class boo {}}}
}
import provide = foo;
import booz = foo.bar.baz;
import beez = foo.bar;
import m = no;
import m2 = no.mod;
import n = 5;
import o = "s";
import q = null;
import r = undefined;
var p = new provide.Provide();
function use() {
beez.baz.boo;
var p1: provide.Provide;
var p2: foo.Provide;
var p3:booz.bar;
var p22 = new provide.Provide();
}
namespace foo {
export class Provide {
}
export namespace bar { exportnamespace baz {export class boo {}}}
}

import provide = foo;
import booz = foo.bar.baz;
import beez = foo.bar;

import m = no;
import m2 = no.mod;
import n = 5;
import o = "s";
import q = null;
import r = undefined;


var p = new provide.Provide();

function use() {

beez.baz.boo;
var p1: provide.Provide;
var p2: foo.Provide;
var p3:booz.bar;
var p22 = new provide.Provide();
}

Loading

[8]ページ先頭

©2009-2025 Movatter.jp