TypeScript/tests/cases/compiler/aliasUsageInFunctionExpression.ts
2014-07-12 17:30:19 -07:00

20 lines
No EOL
701 B
TypeScript

//@module: commonjs
// @Filename: aliasUsageInFunctionExpression_backbone.ts
export class Model {
public someData: string;
}
// @Filename: aliasUsageInFunctionExpression_moduleA.ts
import Backbone = require("aliasUsageInFunctionExpression_backbone");
export class VisualizationModel extends Backbone.Model {
// interesting stuff here
}
// @Filename: aliasUsageInFunctionExpression_main.ts
import Backbone = require("aliasUsageInFunctionExpression_backbone");
import moduleA = require("aliasUsageInFunctionExpression_moduleA");
interface IHasVisualizationModel {
VisualizationModel: typeof Backbone.Model;
}
var f = (x: IHasVisualizationModel) => x;
f = (x) => moduleA;