TypeScript/tests/baselines/reference/genericClassesRedeclaration.errors.txt
2014-09-30 18:09:55 -07:00

95 lines
5 KiB
Plaintext

tests/cases/compiler/genericClassesRedeclaration.ts(16,11): error TS2300: Duplicate identifier 'StringHashTable'.
tests/cases/compiler/genericClassesRedeclaration.ts(29,11): error TS2300: Duplicate identifier 'IdentiferNameHashTable'.
tests/cases/compiler/genericClassesRedeclaration.ts(42,9): error TS2374: Duplicate string index signature.
tests/cases/compiler/genericClassesRedeclaration.ts(55,11): error TS2300: Duplicate identifier 'StringHashTable'.
tests/cases/compiler/genericClassesRedeclaration.ts(68,11): error TS2300: Duplicate identifier 'IdentiferNameHashTable'.
==== tests/cases/compiler/genericClassesRedeclaration.ts (5 errors) ====
declare module TypeScript {
interface IIndexable<T> {
[s: string]: T;
}
function createIntrinsicsObject<T>(): IIndexable<T>;
interface IHashTable<T> {
getAllKeys(): string[];
add(key: string, data: T): boolean;
addOrUpdate(key: string, data: T): boolean;
map(fn: (k: string, value: T, context: any) => void, context: any): void;
every(fn: (k: string, value: T, context: any) => void, context: any): boolean;
some(fn: (k: string, value: T, context: any) => void, context: any): boolean;
count(): number;
lookup(key: string): T;
}
class StringHashTable<T> implements IHashTable<T> {
~~~~~~~~~~~~~~~
!!! error TS2300: Duplicate identifier 'StringHashTable'.
private itemCount;
private table;
public getAllKeys(): string[];
public add(key: string, data: T): boolean;
public addOrUpdate(key: string, data: T): boolean;
public map(fn: (k: string, value: T, context: any) => void, context: any): void;
public every(fn: (k: string, value: T, context: any) => void, context: any): boolean;
public some(fn: (k: string, value: T, context: any) => void, context: any): boolean;
public count(): number;
public lookup(key: string): T;
public remove(key: string): void;
}
class IdentiferNameHashTable<T> extends StringHashTable<T> {
~~~~~~~~~~~~~~~~~~~~~~
!!! error TS2300: Duplicate identifier 'IdentiferNameHashTable'.
public getAllKeys(): string[];
public add(key: string, data: T): boolean;
public addOrUpdate(key: string, data: T): boolean;
public map(fn: (k: string, value: T, context: any) => void, context: any): void;
public every(fn: (k: string, value: T, context: any) => void, context: any): boolean;
public some(fn: (k: string, value: any, context: any) => void, context: any): boolean;
public lookup(key: string): T;
}
}
declare module TypeScript {
interface IIndexable<T> {
[s: string]: T;
~~~~~~~~~~~~~~~
!!! error TS2374: Duplicate string index signature.
}
function createIntrinsicsObject<T>(): IIndexable<T>;
interface IHashTable<T> {
getAllKeys(): string[];
add(key: string, data: T): boolean;
addOrUpdate(key: string, data: T): boolean;
map(fn: (k: string, value: T, context: any) => void, context: any): void;
every(fn: (k: string, value: T, context: any) => void, context: any): boolean;
some(fn: (k: string, value: T, context: any) => void, context: any): boolean;
count(): number;
lookup(key: string): T;
}
class StringHashTable<T> implements IHashTable<T> {
~~~~~~~~~~~~~~~
!!! error TS2300: Duplicate identifier 'StringHashTable'.
private itemCount;
private table;
public getAllKeys(): string[];
public add(key: string, data: T): boolean;
public addOrUpdate(key: string, data: T): boolean;
public map(fn: (k: string, value: T, context: any) => void, context: any): void;
public every(fn: (k: string, value: T, context: any) => void, context: any): boolean;
public some(fn: (k: string, value: T, context: any) => void, context: any): boolean;
public count(): number;
public lookup(key: string): T;
public remove(key: string): void;
}
class IdentiferNameHashTable<T> extends StringHashTable<T> {
~~~~~~~~~~~~~~~~~~~~~~
!!! error TS2300: Duplicate identifier 'IdentiferNameHashTable'.
public getAllKeys(): string[];
public add(key: string, data: T): boolean;
public addOrUpdate(key: string, data: T): boolean;
public map(fn: (k: string, value: T, context: any) => void, context: any): void;
public every(fn: (k: string, value: T, context: any) => void, context: any): boolean;
public some(fn: (k: string, value: any, context: any) => void, context: any): boolean;
public lookup(key: string): T;
}
}