Skip to content

Commit a6a157c

Browse files
Compile TypeDoc against TypeScript 1.5.0-beta, see #95
1 parent 0eef403 commit a6a157c

File tree

3 files changed

+214
-281
lines changed

3 files changed

+214
-281
lines changed

bin/typedoc.js

Lines changed: 49 additions & 49 deletions
Original file line numberDiff line numberDiff line change
@@ -183,7 +183,7 @@ var td;
183183
td.EventDispatcher = EventDispatcher;
184184
})(td || (td = {}));
185185
/// <reference path="EventDispatcher.ts" />
186-
var __extends = (this && this.__extends) || function (d, b) {
186+
var __extends = this.__extends || function (d, b) {
187187
for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p];
188188
function __() { this.constructor = d; }
189189
__.prototype = b.prototype;
@@ -2251,54 +2251,54 @@ var td;
22512251
*/
22522252
function visit(context, node) {
22532253
switch (node.kind) {
2254-
case 228 /* SourceFile */:
2254+
case 227 /* SourceFile */:
22552255
return visitSourceFile(context, node);
2256-
case 175 /* ClassExpression */:
2257-
case 202 /* ClassDeclaration */:
2256+
case 174 /* ClassExpression */:
2257+
case 201 /* ClassDeclaration */:
22582258
return visitClassDeclaration(context, node);
2259-
case 203 /* InterfaceDeclaration */:
2259+
case 202 /* InterfaceDeclaration */:
22602260
return visitInterfaceDeclaration(context, node);
2261-
case 206 /* ModuleDeclaration */:
2261+
case 205 /* ModuleDeclaration */:
22622262
return visitModuleDeclaration(context, node);
2263-
case 181 /* VariableStatement */:
2263+
case 180 /* VariableStatement */:
22642264
return visitVariableStatement(context, node);
2265-
case 132 /* PropertySignature */:
2266-
case 133 /* PropertyDeclaration */:
2267-
case 225 /* PropertyAssignment */:
2268-
case 226 /* ShorthandPropertyAssignment */:
2269-
case 199 /* VariableDeclaration */:
2270-
case 153 /* BindingElement */:
2265+
case 131 /* PropertySignature */:
2266+
case 132 /* PropertyDeclaration */:
2267+
case 224 /* PropertyAssignment */:
2268+
case 225 /* ShorthandPropertyAssignment */:
2269+
case 198 /* VariableDeclaration */:
2270+
case 152 /* BindingElement */:
22712271
return visitVariableDeclaration(context, node);
2272-
case 205 /* EnumDeclaration */:
2272+
case 204 /* EnumDeclaration */:
22732273
return visitEnumDeclaration(context, node);
2274-
case 227 /* EnumMember */:
2274+
case 226 /* EnumMember */:
22752275
return visitEnumMember(context, node);
2276-
case 136 /* Constructor */:
2277-
case 140 /* ConstructSignature */:
2276+
case 135 /* Constructor */:
2277+
case 139 /* ConstructSignature */:
22782278
return visitConstructor(context, node);
2279-
case 134 /* MethodSignature */:
2280-
case 135 /* MethodDeclaration */:
2281-
case 201 /* FunctionDeclaration */:
2279+
case 133 /* MethodSignature */:
2280+
case 134 /* MethodDeclaration */:
2281+
case 200 /* FunctionDeclaration */:
22822282
return visitFunctionDeclaration(context, node);
2283-
case 137 /* GetAccessor */:
2283+
case 136 /* GetAccessor */:
22842284
return visitGetAccessorDeclaration(context, node);
2285-
case 138 /* SetAccessor */:
2285+
case 137 /* SetAccessor */:
22862286
return visitSetAccessorDeclaration(context, node);
2287-
case 139 /* CallSignature */:
2288-
case 143 /* FunctionType */:
2287+
case 138 /* CallSignature */:
2288+
case 142 /* FunctionType */:
22892289
return visitCallSignatureDeclaration(context, node);
2290-
case 141 /* IndexSignature */:
2290+
case 140 /* IndexSignature */:
22912291
return visitIndexSignatureDeclaration(context, node);
2292-
case 180 /* Block */:
2293-
case 207 /* ModuleBlock */:
2292+
case 179 /* Block */:
2293+
case 206 /* ModuleBlock */:
22942294
return visitBlock(context, node);
2295-
case 155 /* ObjectLiteralExpression */:
2295+
case 154 /* ObjectLiteralExpression */:
22962296
return visitObjectLiteral(context, node);
2297-
case 146 /* TypeLiteral */:
2297+
case 145 /* TypeLiteral */:
22982298
return visitTypeLiteral(context, node);
2299-
case 215 /* ExportAssignment */:
2299+
case 214 /* ExportAssignment */:
23002300
return visitExportAssignment(context, node);
2301-
case 204 /* TypeAliasDeclaration */:
2301+
case 203 /* TypeAliasDeclaration */:
23022302
return visitTypeAliasDeclaration(context, node);
23032303
default:
23042304
return null;
@@ -2307,7 +2307,7 @@ var td;
23072307
converter.visit = visit;
23082308
function visitBlock(context, node) {
23092309
if (node.statements) {
2310-
var prefered = [202 /* ClassDeclaration */, 203 /* InterfaceDeclaration */, 205 /* EnumDeclaration */];
2310+
var prefered = [201 /* ClassDeclaration */, 202 /* InterfaceDeclaration */, 204 /* EnumDeclaration */];
23112311
var statements = [];
23122312
node.statements.forEach(function (statement) {
23132313
if (prefered.indexOf(statement.kind) != -1) {
@@ -2516,12 +2516,12 @@ var td;
25162516
context.withScope(variable, function () {
25172517
if (node.initializer) {
25182518
switch (node.initializer.kind) {
2519-
case 164 /* ArrowFunction */:
2520-
case 163 /* FunctionExpression */:
2519+
case 163 /* ArrowFunction */:
2520+
case 162 /* FunctionExpression */:
25212521
variable.kind = scope.kind & td.models.ReflectionKind.ClassOrInterface ? td.models.ReflectionKind.Method : td.models.ReflectionKind.Function;
25222522
visitCallSignatureDeclaration(context, node.initializer);
25232523
break;
2524-
case 155 /* ObjectLiteralExpression */:
2524+
case 154 /* ObjectLiteralExpression */:
25252525
if (!isSimpleObjectLiteral(node.initializer)) {
25262526
variable.kind = td.models.ReflectionKind.ObjectLiteral;
25272527
variable.type = new td.models.IntrinsicType('object');
@@ -2812,11 +2812,11 @@ var td;
28122812
switch (node.kind) {
28132813
case 8 /* StringLiteral */:
28142814
return convertStringLiteralExpression(node);
2815-
case 147 /* ArrayType */:
2815+
case 146 /* ArrayType */:
28162816
return convertArrayTypeNode(context, node);
2817-
case 148 /* TupleType */:
2817+
case 147 /* TupleType */:
28182818
return convertTupleTypeNode(context, node);
2819-
case 149 /* UnionType */:
2819+
case 148 /* UnionType */:
28202820
return convertUnionTypeNode(context, node);
28212821
}
28222822
// Node based type conversions by type flags
@@ -3233,7 +3233,7 @@ var td;
32333233
* @returns The type reflection representing the given binding pattern.
32343234
*/
32353235
function convertDestructuringType(context, node) {
3236-
if (node.kind == 152 /* ArrayBindingPattern */) {
3236+
if (node.kind == 151 /* ArrayBindingPattern */) {
32373237
var types = [];
32383238
node.elements.forEach(function (element) {
32393239
types.push(convertType(context, element));
@@ -3672,7 +3672,7 @@ var td;
36723672
}
36733673
// Test whether the node is exported
36743674
var isExported = container.kindOf(td.models.ReflectionKind.Module) ? false : container.flags.isExported;
3675-
if (node.parent && node.parent.kind == 200 /* VariableDeclarationList */) {
3675+
if (node.parent && node.parent.kind == 199 /* VariableDeclarationList */) {
36763676
isExported = isExported || !!(node.parent.parent.flags & 1 /* Export */);
36773677
}
36783678
else {
@@ -3692,10 +3692,10 @@ var td;
36923692
if (nonStaticKinds.indexOf(kind) == -1) {
36933693
isStatic = !!(node.flags & 128 /* Static */);
36943694
if (container.kind == td.models.ReflectionKind.Class) {
3695-
if (node.parent && node.parent.kind == 136 /* Constructor */) {
3695+
if (node.parent && node.parent.kind == 135 /* Constructor */) {
36963696
isConstructorProperty = true;
36973697
}
3698-
else if (!node.parent || node.parent.kind != 202 /* ClassDeclaration */) {
3698+
else if (!node.parent || node.parent.kind != 201 /* ClassDeclaration */) {
36993699
isStatic = true;
37003700
}
37013701
}
@@ -3842,7 +3842,7 @@ var td;
38423842
*/
38433843
function extractSignatureType(context, node) {
38443844
var checker = context.checker;
3845-
if (node.kind & 139 /* CallSignature */ || node.kind & 158 /* CallExpression */) {
3845+
if (node.kind & 138 /* CallSignature */ || node.kind & 157 /* CallExpression */) {
38463846
try {
38473847
var signature = checker.getSignatureFromDeclaration(node);
38483848
return converter.convertType(context, node.type, checker.getReturnTypeOfSignature(signature));
@@ -4143,18 +4143,18 @@ var td;
41434143
CommentPlugin.getComment = function (node) {
41444144
var sourceFile = ts.getSourceFileOfNode(node);
41454145
var target = node;
4146-
if (node.kind == 206 /* ModuleDeclaration */) {
4146+
if (node.kind == 205 /* ModuleDeclaration */) {
41474147
var a, b;
41484148
// Ignore comments for cascaded modules, e.g. module A.B { }
4149-
if (node.nextContainer && node.nextContainer.kind == 206 /* ModuleDeclaration */) {
4149+
if (node.nextContainer && node.nextContainer.kind == 205 /* ModuleDeclaration */) {
41504150
a = node;
41514151
b = node.nextContainer;
41524152
if (a.name.end + 1 == b.name.pos) {
41534153
return null;
41544154
}
41554155
}
41564156
// Pull back comments of cascaded modules
4157-
while (target.parent && target.parent.kind == 206 /* ModuleDeclaration */) {
4157+
while (target.parent && target.parent.kind == 205 /* ModuleDeclaration */) {
41584158
a = target;
41594159
b = target.parent;
41604160
if (a.name.pos == b.name.end + 1) {
@@ -4165,13 +4165,13 @@ var td;
41654165
}
41664166
}
41674167
}
4168-
if (node.parent && node.parent.kind == 200 /* VariableDeclarationList */) {
4168+
if (node.parent && node.parent.kind == 199 /* VariableDeclarationList */) {
41694169
target = node.parent.parent;
41704170
}
41714171
var comments = ts.getJsDocComments(target, sourceFile);
41724172
if (comments && comments.length) {
41734173
var comment;
4174-
if (node.kind == 228 /* 'SourceFile' */) {
4174+
if (node.kind == 227 /* 'SourceFile' */) {
41754175
if (comments.length == 1)
41764176
return null;
41774177
comment = comments[0];
@@ -4409,7 +4409,7 @@ var td;
44094409
case 65 /* Identifier */:
44104410
identifier = decorator.expression;
44114411
break;
4412-
case 158 /* CallExpression */:
4412+
case 157 /* CallExpression */:
44134413
callExpression = decorator.expression;
44144414
identifier = callExpression.expression;
44154415
break;

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828
"node": ">=0.10.0"
2929
},
3030
"dependencies": {
31-
"typescript": "1.5.x",
31+
"typescript": "1.5.0-beta",
3232
"typedoc-default-themes": "^0.3.3",
3333
"fs-extra": "^0.16.5",
3434
"minimatch": "^2.0.4",

0 commit comments

Comments
 (0)