better pogen error reporting

This commit is contained in:
Florian Dold 2016-11-23 00:55:54 +01:00
parent c43e24bb13
commit e43187d617

View File

@ -227,7 +227,8 @@ export function processFile(sourceFile: ts.SourceFile) {
case ts.SyntaxKind.JsxClosingElement: case ts.SyntaxKind.JsxClosingElement:
break; break;
default: default:
console.error("unrecognized syntax in JSX Element", ts.SyntaxKind[childNode.kind]); let lc = ts.getLineAndCharacterOfPosition(childNode.getSourceFile(), childNode.getStart());
console.error(`unrecognized syntax in JSX Element (${childNode.getSourceFile().fileName}:${lc.line}:${lc.character}`);
break; break;
} }
}; };