Merge branch 'master' into reachabilityChecks

This commit is contained in:
Vladimir Matveev
2015-10-12 22:33:25 -07:00
196 changed files with 13527 additions and 309 deletions
+2 -1
View File
@@ -1,6 +1,7 @@
language: node_js
node_js:
- '4'
- '0.10'
sudo: false
sudo: false
+1 -28
View File
@@ -3965,34 +3965,7 @@ interface ObjectConstructor {
* Copy the values of all of the enumerable own properties from one or more source objects to a
* target object. Returns the target object.
* @param target The target object to copy to.
* @param source The source object from which to copy properties.
*/
assign<T, U>(target: T, source: U): T & U;
/**
* Copy the values of all of the enumerable own properties from one or more source objects to a
* target object. Returns the target object.
* @param target The target object to copy to.
* @param source1 The first source object from which to copy properties.
* @param source2 The second source object from which to copy properties.
*/
assign<T, U, V>(target: T, source1: U, source2: V): T & U & V;
/**
* Copy the values of all of the enumerable own properties from one or more source objects to a
* target object. Returns the target object.
* @param target The target object to copy to.
* @param source1 The first source object from which to copy properties.
* @param source2 The second source object from which to copy properties.
* @param source3 The third source object from which to copy properties.
*/
assign<T, U, V, W>(target: T, source1: U, source2: V, source3: W): T & U & V & W;
/**
* Copy the values of all of the enumerable own properties from one or more source objects to a
* target object. Returns the target object.
* @param target The target object to copy to.
* @param sources One or more source objects from which to copy properties
* @param sources One or more source objects to copy properties from.
*/
assign(target: any, ...sources: any[]): any;
+15 -4
View File
@@ -612,8 +612,11 @@ namespace ts {
// block - scope variable and namespace module. However, only when we
// try to resolve name in /*1*/ which is used in variable position,
// we want to check for block- scoped
if (meaning & SymbolFlags.BlockScopedVariable && result.flags & SymbolFlags.BlockScopedVariable) {
checkResolvedBlockScopedVariable(result, errorLocation);
if (meaning & SymbolFlags.BlockScopedVariable) {
const exportOrLocalSymbol = getExportSymbolOfValueSymbolIfExported(result);
if (exportOrLocalSymbol.flags & SymbolFlags.BlockScopedVariable) {
checkResolvedBlockScopedVariable(exportOrLocalSymbol, errorLocation);
}
}
}
return result;
@@ -7982,6 +7985,11 @@ namespace ts {
return true;
}
// An instance property must be accessed through an instance of the enclosing class
if (type.flags & TypeFlags.ThisType) {
// get the original type -- represented as the type constraint of the 'this' type
type = getConstraintOfTypeParameter(<TypeParameter>type);
}
// TODO: why is the first part of this check here?
if (!(getTargetType(type).flags & (TypeFlags.Class | TypeFlags.Interface) && hasBaseType(<InterfaceType>type, enclosingClass))) {
error(node, Diagnostics.Property_0_is_protected_and_only_accessible_through_an_instance_of_class_1, symbolToString(prop), typeToString(enclosingClass));
@@ -10051,7 +10059,9 @@ namespace ts {
let rightType = checkExpression(right, contextualMapper);
switch (operator) {
case SyntaxKind.AsteriskToken:
case SyntaxKind.AsteriskAsteriskToken:
case SyntaxKind.AsteriskEqualsToken:
case SyntaxKind.AsteriskAsteriskEqualsToken:
case SyntaxKind.SlashToken:
case SyntaxKind.SlashEqualsToken:
case SyntaxKind.PercentToken:
@@ -10070,7 +10080,7 @@ namespace ts {
case SyntaxKind.CaretEqualsToken:
case SyntaxKind.AmpersandToken:
case SyntaxKind.AmpersandEqualsToken:
// TypeScript 1.0 spec (April 2014): 4.15.1
// TypeScript 1.0 spec (April 2014): 4.19.1
// These operators require their operands to be of type Any, the Number primitive type,
// or an enum type. Operands of an enum type are treated
// as having the primitive type Number. If one operand is the null or undefined value,
@@ -10099,7 +10109,7 @@ namespace ts {
return numberType;
case SyntaxKind.PlusToken:
case SyntaxKind.PlusEqualsToken:
// TypeScript 1.0 spec (April 2014): 4.15.2
// TypeScript 1.0 spec (April 2014): 4.19.2
// The binary + operator requires both operands to be of the Number primitive type or an enum type,
// or at least one of the operands to be of type Any or the String primitive type.
@@ -13889,6 +13899,7 @@ namespace ts {
break;
case SyntaxKind.ClassExpression:
forEach((<ClassExpression>node).members, checkSourceElement);
forEachChild(node, checkFunctionAndClassExpressionBodies);
break;
case SyntaxKind.MethodDeclaration:
case SyntaxKind.MethodSignature:
+6
View File
@@ -722,6 +722,12 @@ namespace ts {
* List of supported extensions in order of file resolution precedence.
*/
export const supportedExtensions = [".ts", ".tsx", ".d.ts"];
/**
* List of extensions that will be used to look for external modules.
* This list is kept separate from supportedExtensions to for cases when we'll allow to include .js files in compilation,
* but still would like to load only TypeScript files as modules
*/
export const moduleFileExtensions = supportedExtensions;
const extensionsToRemove = [".d.ts", ".ts", ".js", ".tsx", ".jsx"];
export function removeFileExtension(path: string): string {
+8
View File
@@ -2506,5 +2506,13 @@
"A constructor cannot contain a 'super' call when its class extends 'null'": {
"category": "Error",
"code": 17005
},
"An unary expression with the '{0}' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.": {
"category": "Error",
"code": 17006
},
"A type assertion expression is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.": {
"category": "Error",
"code": 17007
}
}
+143 -45
View File
@@ -2783,6 +2783,68 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, Promi
}
}
/**
* Emit ES7 exponentiation operator downlevel using Math.pow
* @param node a binary expression node containing exponentiationOperator (**, **=)
*/
function emitExponentiationOperator(node: BinaryExpression) {
let leftHandSideExpression = node.left;
if (node.operatorToken.kind === SyntaxKind.AsteriskAsteriskEqualsToken) {
let synthesizedLHS: ElementAccessExpression | PropertyAccessExpression;
let shouldEmitParentheses = false;
if (isElementAccessExpression(leftHandSideExpression)) {
shouldEmitParentheses = true;
write("(");
synthesizedLHS = <ElementAccessExpression>createSynthesizedNode(SyntaxKind.ElementAccessExpression, /*startsOnNewLine*/ false);
let identifier = emitTempVariableAssignment(leftHandSideExpression.expression, /*canDefinedTempVariablesInPlaces*/ false, /*shouldEmitCommaBeforeAssignment*/ false);
synthesizedLHS.expression = identifier;
if (leftHandSideExpression.argumentExpression.kind !== SyntaxKind.NumericLiteral &&
leftHandSideExpression.argumentExpression.kind !== SyntaxKind.StringLiteral) {
let tempArgumentExpression = createAndRecordTempVariable(TempFlags._i);
(<ElementAccessExpression>synthesizedLHS).argumentExpression = tempArgumentExpression;
emitAssignment(tempArgumentExpression, leftHandSideExpression.argumentExpression, /*shouldEmitCommaBeforeAssignment*/ true);
}
else {
(<ElementAccessExpression>synthesizedLHS).argumentExpression = leftHandSideExpression.argumentExpression;
}
write(", ");
}
else if (isPropertyAccessExpression(leftHandSideExpression)) {
shouldEmitParentheses = true;
write("(");
synthesizedLHS = <PropertyAccessExpression>createSynthesizedNode(SyntaxKind.PropertyAccessExpression, /*startsOnNewLine*/ false);
let identifier = emitTempVariableAssignment(leftHandSideExpression.expression, /*canDefinedTempVariablesInPlaces*/ false, /*shouldemitCommaBeforeAssignment*/ false);
synthesizedLHS.expression = identifier;
(<PropertyAccessExpression>synthesizedLHS).dotToken = leftHandSideExpression.dotToken;
(<PropertyAccessExpression>synthesizedLHS).name = leftHandSideExpression.name;
write(", ");
}
emit(synthesizedLHS || leftHandSideExpression);
write(" = ");
write("Math.pow(");
emit(synthesizedLHS || leftHandSideExpression);
write(", ");
emit(node.right);
write(")");
if (shouldEmitParentheses) {
write(")");
}
}
else {
write("Math.pow(");
emit(leftHandSideExpression);
write(", ");
emit(node.right);
write(")");
}
}
function emitBinaryExpression(node: BinaryExpression) {
if (languageVersion < ScriptTarget.ES6 && node.operatorToken.kind === SyntaxKind.EqualsToken &&
(node.left.kind === SyntaxKind.ObjectLiteralExpression || node.left.kind === SyntaxKind.ArrayLiteralExpression)) {
@@ -2800,12 +2862,27 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, Promi
emitNodeWithoutSourceMap(node.left);
write(`", `);
}
emit(node.left);
let indentedBeforeOperator = indentIfOnDifferentLines(node, node.left, node.operatorToken, node.operatorToken.kind !== SyntaxKind.CommaToken ? " " : undefined);
write(tokenToString(node.operatorToken.kind));
let indentedAfterOperator = indentIfOnDifferentLines(node, node.operatorToken, node.right, " ");
emit(node.right);
decreaseIndentIf(indentedBeforeOperator, indentedAfterOperator);
if (node.operatorToken.kind === SyntaxKind.AsteriskAsteriskToken || node.operatorToken.kind === SyntaxKind.AsteriskAsteriskEqualsToken) {
// Downleveled emit exponentiation operator using Math.pow
emitExponentiationOperator(node);
}
else {
emit(node.left);
// Add indentation before emit the operator if the operator is on different line
// For example:
// 3
// + 2;
// emitted as
// 3
// + 2;
let indentedBeforeOperator = indentIfOnDifferentLines(node, node.left, node.operatorToken, node.operatorToken.kind !== SyntaxKind.CommaToken ? " " : undefined);
write(tokenToString(node.operatorToken.kind));
let indentedAfterOperator = indentIfOnDifferentLines(node, node.operatorToken, node.right, " ");
emit(node.right);
decreaseIndentIf(indentedBeforeOperator, indentedAfterOperator);
}
if (exportChanged) {
write(")");
}
@@ -3442,6 +3519,58 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, Promi
write(";");
}
/**
* Emit an assignment to a given identifier, 'name', with a given expression, 'value'.
* @param name an identifier as a left-hand-side operand of the assignment
* @param value an expression as a right-hand-side operand of the assignment
* @param shouldEmitCommaBeforeAssignment a boolean indicating whether to prefix an assignment with comma
*/
function emitAssignment(name: Identifier, value: Expression, shouldEmitCommaBeforeAssignment: boolean) {
if (shouldEmitCommaBeforeAssignment) {
write(", ");
}
let exportChanged = isNameOfExportedSourceLevelDeclarationInSystemExternalModule(name);
if (exportChanged) {
write(`${exportFunctionForFile}("`);
emitNodeWithCommentsAndWithoutSourcemap(name);
write(`", `);
}
const isVariableDeclarationOrBindingElement =
name.parent && (name.parent.kind === SyntaxKind.VariableDeclaration || name.parent.kind === SyntaxKind.BindingElement);
if (isVariableDeclarationOrBindingElement) {
emitModuleMemberName(<Declaration>name.parent);
}
else {
emit(name);
}
write(" = ");
emit(value);
if (exportChanged) {
write(")");
}
}
/**
* Create temporary variable, emit an assignment of the variable the given expression
* @param expression an expression to assign to the newly created temporary variable
* @param canDefineTempVariablesInPlace a boolean indicating whether you can define the temporary variable at an assignment location
* @param shouldEmitCommaBeforeAssignment a boolean indicating whether an assignment should prefix with comma
*/
function emitTempVariableAssignment(expression: Expression, canDefineTempVariablesInPlace: boolean, shouldEmitCommaBeforeAssignment: boolean): Identifier {
let identifier = createTempVariable(TempFlags.Auto);
if (!canDefineTempVariablesInPlace) {
recordTempDeclaration(identifier);
}
emitAssignment(identifier, expression, shouldEmitCommaBeforeAssignment);
return identifier;
}
function emitDestructuring(root: BinaryExpression | VariableDeclaration | ParameterDeclaration, isAssignmentExpressionStatement: boolean, value?: Expression) {
let emitCount = 0;
@@ -3467,36 +3596,6 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, Promi
emitBindingElement(<BindingElement>root, value);
}
function emitAssignment(name: Identifier, value: Expression) {
if (emitCount++) {
write(", ");
}
const isVariableDeclarationOrBindingElement =
name.parent && (name.parent.kind === SyntaxKind.VariableDeclaration || name.parent.kind === SyntaxKind.BindingElement);
let exportChanged = isNameOfExportedSourceLevelDeclarationInSystemExternalModule(name);
if (exportChanged) {
write(`${exportFunctionForFile}("`);
emitNodeWithCommentsAndWithoutSourcemap(name);
write(`", `);
}
if (isVariableDeclarationOrBindingElement) {
emitModuleMemberName(<Declaration>name.parent);
}
else {
emit(name);
}
write(" = ");
emit(value);
if (exportChanged) {
write(")");
}
}
/**
* Ensures that there exists a declared identifier whose value holds the given expression.
@@ -3512,11 +3611,8 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, Promi
return expr;
}
let identifier = createTempVariable(TempFlags.Auto);
if (!canDefineTempVariablesInPlace) {
recordTempDeclaration(identifier);
}
emitAssignment(identifier, expr);
let identifier = emitTempVariableAssignment(expr, canDefineTempVariablesInPlace, emitCount > 0);
emitCount++;
return identifier;
}
@@ -3623,7 +3719,8 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, Promi
emitArrayLiteralAssignment(<ArrayLiteralExpression>target, value);
}
else {
emitAssignment(<Identifier>target, value);
emitAssignment(<Identifier>target, value, /*shouldEmitCommaBeforeAssignment*/ emitCount > 0);
emitCount++;
}
}
@@ -3692,7 +3789,8 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, Promi
}
}
else {
emitAssignment(<Identifier>target.name, value);
emitAssignment(<Identifier>target.name, value, /*shouldEmitCommaBeforeAssignment*/ emitCount > 0);
emitCount++;
}
}
}
@@ -6859,7 +6957,7 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, Promi
if (isLineBreak(c)) {
if (firstNonWhitespace !== -1 && (lastNonWhitespace - firstNonWhitespace + 1 > 0)) {
let part = text.substr(firstNonWhitespace, lastNonWhitespace - firstNonWhitespace + 1);
result = (result ? result + "\" + ' ' + \"" : "") + part;
result = (result ? result + "\" + ' ' + \"" : "") + escapeString(part);
}
firstNonWhitespace = -1;
}
@@ -6873,7 +6971,7 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, Promi
if (firstNonWhitespace !== -1) {
let part = text.substr(firstNonWhitespace);
result = (result ? result + "\" + ' ' + \"" : "") + part;
result = (result ? result + "\" + ' ' + \"" : "") + escapeString(part);
}
if (result) {
+141 -19
View File
@@ -3031,7 +3031,31 @@ namespace ts {
let newPrecedence = getBinaryOperatorPrecedence();
// Check the precedence to see if we should "take" this operator
if (newPrecedence <= precedence) {
// - For left associative operator (all operator but **), consume the operator,
// recursively call the function below, and parse binaryExpression as a rightOperand
// of the caller if the new precendence of the operator is greater then or equal to the current precendence.
// For example:
// a - b - c;
// ^token; leftOperand = b. Return b to the caller as a rightOperand
// a * b - c
// ^token; leftOperand = b. Return b to the caller as a rightOperand
// a - b * c;
// ^token; leftOperand = b. Return b * c to the caller as a rightOperand
// - For right associative operator (**), consume the operator, recursively call the function
// and parse binaryExpression as a rightOperand of the caller if the new precendence of
// the operator is strictly grater than the current precendence
// For example:
// a ** b ** c;
// ^^token; leftOperand = b. Return b ** c to the caller as a rightOperand
// a - b ** c;
// ^^token; leftOperand = b. Return b ** c to the caller as a rightOperand
// a ** b - c
// ^token; leftOperand = b. Return b to the caller as a rightOperand
const consumeCurrentOperator = token === SyntaxKind.AsteriskAsteriskToken ?
newPrecedence >= precedence :
newPrecedence > precedence;
if (!consumeCurrentOperator) {
break;
}
@@ -3105,6 +3129,8 @@ namespace ts {
case SyntaxKind.SlashToken:
case SyntaxKind.PercentToken:
return 10;
case SyntaxKind.AsteriskAsteriskToken:
return 11;
}
// -1 is lower than all other precedences. Returning it will cause binary expression
@@ -3131,28 +3157,29 @@ namespace ts {
let node = <PrefixUnaryExpression>createNode(SyntaxKind.PrefixUnaryExpression);
node.operator = token;
nextToken();
node.operand = parseUnaryExpressionOrHigher();
node.operand = parseSimpleUnaryExpression();
return finishNode(node);
}
function parseDeleteExpression() {
let node = <DeleteExpression>createNode(SyntaxKind.DeleteExpression);
nextToken();
node.expression = parseUnaryExpressionOrHigher();
node.expression = parseSimpleUnaryExpression();
return finishNode(node);
}
function parseTypeOfExpression() {
let node = <TypeOfExpression>createNode(SyntaxKind.TypeOfExpression);
nextToken();
node.expression = parseUnaryExpressionOrHigher();
node.expression = parseSimpleUnaryExpression();
return finishNode(node);
}
function parseVoidExpression() {
let node = <VoidExpression>createNode(SyntaxKind.VoidExpression);
nextToken();
node.expression = parseUnaryExpressionOrHigher();
node.expression = parseSimpleUnaryExpression();
return finishNode(node);
}
@@ -3172,22 +3199,63 @@ namespace ts {
function parseAwaitExpression() {
const node = <AwaitExpression>createNode(SyntaxKind.AwaitExpression);
nextToken();
node.expression = parseUnaryExpressionOrHigher();
node.expression = parseSimpleUnaryExpression();
return finishNode(node);
}
function parseUnaryExpressionOrHigher(): UnaryExpression {
/**
* Parse ES7 unary expression and await expression
*
* ES7 UnaryExpression:
* 1) SimpleUnaryExpression[?yield]
* 2) IncrementExpression[?yield] ** UnaryExpression[?yield]
*/
function parseUnaryExpressionOrHigher(): UnaryExpression | BinaryExpression {
if (isAwaitExpression()) {
return parseAwaitExpression();
}
if (isIncrementExpression()) {
let incrementExpression = parseIncrementExpression();
return token === SyntaxKind.AsteriskAsteriskToken ?
<BinaryExpression>parseBinaryExpressionRest(getBinaryOperatorPrecedence(), incrementExpression) :
incrementExpression;
}
let unaryOperator = token;
let simpleUnaryExpression = parseSimpleUnaryExpression();
if (token === SyntaxKind.AsteriskAsteriskToken) {
let diagnostic: Diagnostic;
let start = skipTrivia(sourceText, simpleUnaryExpression.pos);
if (simpleUnaryExpression.kind === SyntaxKind.TypeAssertionExpression) {
parseErrorAtPosition(start, simpleUnaryExpression.end - start, Diagnostics.A_type_assertion_expression_is_not_allowed_in_the_left_hand_side_of_an_exponentiation_expression_Consider_enclosing_the_expression_in_parentheses);
}
else {
parseErrorAtPosition(start, simpleUnaryExpression.end - start, Diagnostics.An_unary_expression_with_the_0_operator_is_not_allowed_in_the_left_hand_side_of_an_exponentiation_expression_Consider_enclosing_the_expression_in_parentheses, tokenToString(unaryOperator));
}
}
return simpleUnaryExpression;
}
/**
* Parse ES7 simple-unary expression or higher:
*
* ES7 SimpleUnaryExpression:
* 1) IncrementExpression[?yield]
* 2) delete UnaryExpression[?yield]
* 3) void UnaryExpression[?yield]
* 4) typeof UnaryExpression[?yield]
* 5) + UnaryExpression[?yield]
* 6) - UnaryExpression[?yield]
* 7) ~ UnaryExpression[?yield]
* 8) ! UnaryExpression[?yield]
*/
function parseSimpleUnaryExpression(): UnaryExpression {
switch (token) {
case SyntaxKind.PlusToken:
case SyntaxKind.MinusToken:
case SyntaxKind.TildeToken:
case SyntaxKind.ExclamationToken:
case SyntaxKind.PlusPlusToken:
case SyntaxKind.MinusMinusToken:
return parsePrefixUnaryExpression();
case SyntaxKind.DeleteKeyword:
return parseDeleteExpression();
@@ -3196,19 +3264,73 @@ namespace ts {
case SyntaxKind.VoidKeyword:
return parseVoidExpression();
case SyntaxKind.LessThanToken:
if (sourceFile.languageVariant !== LanguageVariant.JSX) {
return parseTypeAssertion();
}
if (lookAhead(nextTokenIsIdentifierOrKeyword)) {
return parseJsxElementOrSelfClosingElement(/*inExpressionContext*/ true);
}
// Fall through
// This is modified UnaryExpression grammar in TypeScript
// UnaryExpression (modified):
// < type > UnaryExpression
return parseTypeAssertion();
default:
return parsePostfixExpressionOrHigher();
return parseIncrementExpression();
}
}
function parsePostfixExpressionOrHigher(): PostfixExpression {
/**
* Check if the current token can possibly be an ES7 increment expression.
*
* ES7 IncrementExpression:
* LeftHandSideExpression[?Yield]
* LeftHandSideExpression[?Yield][no LineTerminator here]++
* LeftHandSideExpression[?Yield][no LineTerminator here]--
* ++LeftHandSideExpression[?Yield]
* --LeftHandSideExpression[?Yield]
*/
function isIncrementExpression(): boolean {
// This function is called inside parseUnaryExpression to decide
// whether to call parseSimpleUnaryExpression or call parseIncrmentExpression directly
switch (token) {
case SyntaxKind.PlusToken:
case SyntaxKind.MinusToken:
case SyntaxKind.TildeToken:
case SyntaxKind.ExclamationToken:
case SyntaxKind.DeleteKeyword:
case SyntaxKind.TypeOfKeyword:
case SyntaxKind.VoidKeyword:
return false;
case SyntaxKind.LessThanToken:
// If we are not in JSX context, we are parsing TypeAssertion which is an UnaryExpression
if (sourceFile.languageVariant !== LanguageVariant.JSX) {
return false;
}
// We are in JSX context and the token is part of JSXElement.
// Fall through
default:
return true;
}
}
/**
* Parse ES7 IncrementExpression. IncrementExpression is used instead of ES6's PostFixExpression.
*
* ES7 IncrementExpression[yield]:
* 1) LeftHandSideExpression[?yield]
* 2) LeftHandSideExpression[?yield] [[no LineTerminator here]]++
* 3) LeftHandSideExpression[?yield] [[no LineTerminator here]]--
* 4) ++LeftHandSideExpression[?yield]
* 5) --LeftHandSideExpression[?yield]
* In TypeScript (2), (3) are parsed as PostfixUnaryExpression. (4), (5) are parsed as PrefixUnaryExpression
*/
function parseIncrementExpression(): IncrementExpression {
if (token === SyntaxKind.PlusPlusToken || token === SyntaxKind.MinusMinusToken) {
let node = <PrefixUnaryExpression>createNode(SyntaxKind.PrefixUnaryExpression);
node.operator = token;
nextToken();
node.operand = parseLeftHandSideExpressionOrHigher();
return finishNode(node);
}
else if (sourceFile.languageVariant === LanguageVariant.JSX && token === SyntaxKind.LessThanToken && lookAhead(nextTokenIsIdentifierOrKeyword)) {
// JSXElement is part of primaryExpression
return parseJsxElementOrSelfClosingElement(/*inExpressionContext*/ true);
}
let expression = parseLeftHandSideExpressionOrHigher();
Debug.assert(isLeftHandSideExpression(expression));
@@ -3505,7 +3627,7 @@ namespace ts {
parseExpected(SyntaxKind.LessThanToken);
node.type = parseType();
parseExpected(SyntaxKind.GreaterThanToken);
node.expression = parseUnaryExpressionOrHigher();
node.expression = parseSimpleUnaryExpression();
return finishNode(node);
}
+9 -14
View File
@@ -53,13 +53,13 @@ namespace ts {
if (getRootLength(moduleName) !== 0 || nameStartsWithDotSlashOrDotDotSlash(moduleName)) {
let failedLookupLocations: string[] = [];
let candidate = normalizePath(combinePaths(containingDirectory, moduleName));
let resolvedFileName = loadNodeModuleFromFile(candidate, /* loadOnlyDts */ false, failedLookupLocations, host);
let resolvedFileName = loadNodeModuleFromFile(candidate, failedLookupLocations, host);
if (resolvedFileName) {
return { resolvedModule: { resolvedFileName }, failedLookupLocations };
}
resolvedFileName = loadNodeModuleFromDirectory(candidate, /* loadOnlyDts */ false, failedLookupLocations, host);
resolvedFileName = loadNodeModuleFromDirectory(candidate, failedLookupLocations, host);
return resolvedFileName
? { resolvedModule: { resolvedFileName }, failedLookupLocations }
: { resolvedModule: undefined, failedLookupLocations };
@@ -69,13 +69,8 @@ namespace ts {
}
}
function loadNodeModuleFromFile(candidate: string, loadOnlyDts: boolean, failedLookupLocation: string[], host: ModuleResolutionHost): string {
if (loadOnlyDts) {
return tryLoad(".d.ts");
}
else {
return forEach(supportedExtensions, tryLoad);
}
function loadNodeModuleFromFile(candidate: string, failedLookupLocation: string[], host: ModuleResolutionHost): string {
return forEach(moduleFileExtensions, tryLoad);
function tryLoad(ext: string): string {
let fileName = fileExtensionIs(candidate, ext) ? candidate : candidate + ext;
@@ -89,7 +84,7 @@ namespace ts {
}
}
function loadNodeModuleFromDirectory(candidate: string, loadOnlyDts: boolean, failedLookupLocation: string[], host: ModuleResolutionHost): string {
function loadNodeModuleFromDirectory(candidate: string, failedLookupLocation: string[], host: ModuleResolutionHost): string {
let packageJsonPath = combinePaths(candidate, "package.json");
if (host.fileExists(packageJsonPath)) {
@@ -105,7 +100,7 @@ namespace ts {
}
if (jsonContent.typings) {
let result = loadNodeModuleFromFile(normalizePath(combinePaths(candidate, jsonContent.typings)), loadOnlyDts, failedLookupLocation, host);
let result = loadNodeModuleFromFile(normalizePath(combinePaths(candidate, jsonContent.typings)), failedLookupLocation, host);
if (result) {
return result;
}
@@ -116,7 +111,7 @@ namespace ts {
failedLookupLocation.push(packageJsonPath);
}
return loadNodeModuleFromFile(combinePaths(candidate, "index"), loadOnlyDts, failedLookupLocation, host);
return loadNodeModuleFromFile(combinePaths(candidate, "index"), failedLookupLocation, host);
}
function loadModuleFromNodeModules(moduleName: string, directory: string, host: ModuleResolutionHost): ResolvedModuleWithFailedLookupLocations {
@@ -127,12 +122,12 @@ namespace ts {
if (baseName !== "node_modules") {
let nodeModulesFolder = combinePaths(directory, "node_modules");
let candidate = normalizePath(combinePaths(nodeModulesFolder, moduleName));
let result = loadNodeModuleFromFile(candidate, /* loadOnlyDts */ true, failedLookupLocations, host);
let result = loadNodeModuleFromFile(candidate, failedLookupLocations, host);
if (result) {
return { resolvedModule: { resolvedFileName: result, isExternalLibraryImport: true }, failedLookupLocations };
}
result = loadNodeModuleFromDirectory(candidate, /* loadOnlyDts */ true, failedLookupLocations, host);
result = loadNodeModuleFromDirectory(candidate, failedLookupLocations, host);
if (result) {
return { resolvedModule: { resolvedFileName: result, isExternalLibraryImport: true }, failedLookupLocations };
}
+8
View File
@@ -136,6 +136,7 @@ namespace ts {
"=>": SyntaxKind.EqualsGreaterThanToken,
"+": SyntaxKind.PlusToken,
"-": SyntaxKind.MinusToken,
"**": SyntaxKind.AsteriskAsteriskToken,
"*": SyntaxKind.AsteriskToken,
"/": SyntaxKind.SlashToken,
"%": SyntaxKind.PercentToken,
@@ -158,6 +159,7 @@ namespace ts {
"+=": SyntaxKind.PlusEqualsToken,
"-=": SyntaxKind.MinusEqualsToken,
"*=": SyntaxKind.AsteriskEqualsToken,
"**=": SyntaxKind.AsteriskAsteriskEqualsToken,
"/=": SyntaxKind.SlashEqualsToken,
"%=": SyntaxKind.PercentEqualsToken,
"<<=": SyntaxKind.LessThanLessThanEqualsToken,
@@ -1200,6 +1202,12 @@ namespace ts {
if (text.charCodeAt(pos + 1) === CharacterCodes.equals) {
return pos += 2, token = SyntaxKind.AsteriskEqualsToken;
}
if (text.charCodeAt(pos + 1) === CharacterCodes.asterisk) {
if (text.charCodeAt(pos + 2) === CharacterCodes.equals) {
return pos += 3, token = SyntaxKind.AsteriskAsteriskEqualsToken;
}
return pos += 2, token = SyntaxKind.AsteriskAsteriskToken;
}
return pos++, token = SyntaxKind.AsteriskToken;
case CharacterCodes.plus:
if (text.charCodeAt(pos + 1) === CharacterCodes.plus) {
+9 -3
View File
@@ -64,6 +64,7 @@ namespace ts {
PlusToken,
MinusToken,
AsteriskToken,
AsteriskAsteriskToken,
SlashToken,
PercentToken,
PlusPlusToken,
@@ -86,6 +87,7 @@ namespace ts {
PlusEqualsToken,
MinusEqualsToken,
AsteriskEqualsToken,
AsteriskAsteriskEqualsToken,
SlashEqualsToken,
PercentEqualsToken,
LessThanLessThanEqualsToken,
@@ -713,12 +715,16 @@ namespace ts {
_unaryExpressionBrand: any;
}
export interface PrefixUnaryExpression extends UnaryExpression {
export interface IncrementExpression extends UnaryExpression {
_incrementExpressionBrand: any;
}
export interface PrefixUnaryExpression extends IncrementExpression {
operator: SyntaxKind;
operand: UnaryExpression;
}
export interface PostfixUnaryExpression extends PostfixExpression {
export interface PostfixUnaryExpression extends IncrementExpression {
operand: LeftHandSideExpression;
operator: SyntaxKind;
}
@@ -727,7 +733,7 @@ namespace ts {
_postfixExpressionBrand: any;
}
export interface LeftHandSideExpression extends PostfixExpression {
export interface LeftHandSideExpression extends IncrementExpression {
_leftHandSideExpressionBrand: any;
}
+11 -3
View File
@@ -896,6 +896,14 @@ namespace ts {
return nodeIsDecorated(node) || childIsDecorated(node);
}
export function isPropertyAccessExpression(node: Node): node is PropertyAccessExpression {
return node.kind === SyntaxKind.PropertyAccessExpression;
}
export function isElementAccessExpression(node: Node): node is ElementAccessExpression {
return node.kind === SyntaxKind.ElementAccessExpression;
}
export function isExpression(node: Node): boolean {
switch (node.kind) {
case SyntaxKind.SuperKeyword:
@@ -1414,7 +1422,7 @@ namespace ts {
* where Symbol is literally the word "Symbol", and name is any identifierName
*/
export function isWellKnownSymbolSyntactically(node: Expression): boolean {
return node.kind === SyntaxKind.PropertyAccessExpression && isESSymbolIdentifier((<PropertyAccessExpression>node).expression);
return isPropertyAccessExpression(node) && isESSymbolIdentifier(node.expression);
}
export function getPropertyNameForPropertyNameNode(name: DeclarationName): string {
@@ -2047,8 +2055,8 @@ namespace ts {
if (node.kind === SyntaxKind.Identifier) {
return true;
}
else if (node.kind === SyntaxKind.PropertyAccessExpression) {
return isSupportedExpressionWithTypeArgumentsRest((<PropertyAccessExpression>node).expression);
else if (isPropertyAccessExpression(node)) {
return isSupportedExpressionWithTypeArgumentsRest(node.expression);
}
else {
return false;
+4 -1
View File
@@ -7893,6 +7893,10 @@ declare var Node: {
}
interface NodeFilter {
acceptNode(n: Node): number;
}
declare var NodeFilter: {
FILTER_ACCEPT: number;
FILTER_REJECT: number;
FILTER_SKIP: number;
@@ -7910,7 +7914,6 @@ interface NodeFilter {
SHOW_PROCESSING_INSTRUCTION: number;
SHOW_TEXT: number;
}
declare var NodeFilter: NodeFilter;
interface NodeIterator {
expandEntityReferences: boolean;
+7 -1
View File
@@ -214,6 +214,7 @@ namespace ts.formatting {
public SpaceBetweenYieldOrYieldStarAndOperand: Rule;
// Async functions
public SpaceBetweenAsyncAndOpenParen: Rule;
public SpaceBetweenAsyncAndFunctionKeyword: Rule;
// Template strings
@@ -369,6 +370,7 @@ namespace ts.formatting {
this.SpaceBetweenYieldOrYieldStarAndOperand = new Rule(RuleDescriptor.create4(Shared.TokenRange.FromTokens([SyntaxKind.YieldKeyword, SyntaxKind.AsteriskToken]), Shared.TokenRange.Any), RuleOperation.create2(new RuleOperationContext(Rules.IsSameLineTokenContext, Rules.IsYieldOrYieldStarWithOperand), RuleAction.Space));
// Async-await
this.SpaceBetweenAsyncAndOpenParen = new Rule(RuleDescriptor.create1(SyntaxKind.AsyncKeyword, SyntaxKind.OpenParenToken), RuleOperation.create2(new RuleOperationContext(Rules.IsArrowFunctionContext, Rules.IsSameLineTokenContext), RuleAction.Space));
this.SpaceBetweenAsyncAndFunctionKeyword = new Rule(RuleDescriptor.create1(SyntaxKind.AsyncKeyword, SyntaxKind.FunctionKeyword), RuleOperation.create2(new RuleOperationContext(Rules.IsSameLineTokenContext), RuleAction.Space));
// template string
@@ -402,7 +404,7 @@ namespace ts.formatting {
this.NoSpaceBeforeOpenParenInFuncCall,
this.SpaceBeforeBinaryKeywordOperator, this.SpaceAfterBinaryKeywordOperator,
this.SpaceAfterVoidOperator,
this.SpaceBetweenAsyncAndFunctionKeyword,
this.SpaceBetweenAsyncAndOpenParen, this.SpaceBetweenAsyncAndFunctionKeyword,
this.SpaceBetweenTagAndTemplateString, this.NoSpaceAfterTemplateHeadAndMiddle, this.NoSpaceBeforeTemplateMiddleAndTail,
// TypeScript-specific rules
@@ -703,6 +705,10 @@ namespace ts.formatting {
return context.currentTokenSpan.kind !== SyntaxKind.CommaToken;
}
static IsArrowFunctionContext(context: FormattingContext): boolean {
return context.contextNode.kind === SyntaxKind.ArrowFunction;
}
static IsSameLineTokenContext(context: FormattingContext): boolean {
return context.TokensAreOnSameLine();
}
+3 -2
View File
@@ -4112,8 +4112,9 @@ namespace ts {
let useConstructSignatures = callExpression.kind === SyntaxKind.NewExpression || callExpression.expression.kind === SyntaxKind.SuperKeyword;
let allSignatures = useConstructSignatures ? type.getConstructSignatures() : type.getCallSignatures();
if (!contains(allSignatures, signature.target || signature)) {
// Get the first signature if there
if (!contains(allSignatures, signature.target) && !contains(allSignatures, signature)) {
// Get the first signature if there is one -- allSignatures may contain
// either the original signature or its target, so check for either
signature = allSignatures.length ? allSignatures[0] : undefined;
}
+10 -10
View File
@@ -75,26 +75,26 @@ function delint(sourceFile) {
delintNode(sourceFile);
function delintNode(node) {
switch (node.kind) {
case 197 /* ForStatement */:
case 198 /* ForInStatement */:
case 196 /* WhileStatement */:
case 195 /* DoStatement */:
if (node.statement.kind !== 190 /* Block */) {
case 199 /* ForStatement */:
case 200 /* ForInStatement */:
case 198 /* WhileStatement */:
case 197 /* DoStatement */:
if (node.statement.kind !== 192 /* Block */) {
report(node, "A looping statement's contents should be wrapped in a block body.");
}
break;
case 194 /* IfStatement */:
case 196 /* IfStatement */:
var ifStatement = node;
if (ifStatement.thenStatement.kind !== 190 /* Block */) {
if (ifStatement.thenStatement.kind !== 192 /* Block */) {
report(ifStatement.thenStatement, "An if statement's contents should be wrapped in a block body.");
}
if (ifStatement.elseStatement &&
ifStatement.elseStatement.kind !== 190 /* Block */ &&
ifStatement.elseStatement.kind !== 194 /* IfStatement */) {
ifStatement.elseStatement.kind !== 192 /* Block */ &&
ifStatement.elseStatement.kind !== 196 /* IfStatement */) {
report(ifStatement.elseStatement, "An else statement's contents should be wrapped in a block body.");
}
break;
case 179 /* BinaryExpression */:
case 181 /* BinaryExpression */:
var op = node.operatorToken.kind;
if (op === 30 /* EqualsEqualsToken */ || op == 31 /* ExclamationEqualsToken */) {
report(node, "Use '===' and '!=='.");
@@ -0,0 +1,56 @@
//// [compoundExponentiationAssignmentLHSCanBeAssigned1.ts]
enum E { a, b, c }
var a: any;
var b: number;
var c: E;
var x1: any;
x1 **= a;
x1 **= b;
x1 **= c;
x1 **= null;
x1 **= undefined;
var x2: number;
x2 **= a;
x2 **= b;
x2 **= c;
x2 **= null;
x2 **= undefined;
var x3: E;
x3 **= a;
x3 **= b;
x3 **= c;
x3 **= null;
x3 **= undefined;
//// [compoundExponentiationAssignmentLHSCanBeAssigned1.js]
var E;
(function (E) {
E[E["a"] = 0] = "a";
E[E["b"] = 1] = "b";
E[E["c"] = 2] = "c";
})(E || (E = {}));
var a;
var b;
var c;
var x1;
x1 = Math.pow(x1, a);
x1 = Math.pow(x1, b);
x1 = Math.pow(x1, c);
x1 = Math.pow(x1, null);
x1 = Math.pow(x1, undefined);
var x2;
x2 = Math.pow(x2, a);
x2 = Math.pow(x2, b);
x2 = Math.pow(x2, c);
x2 = Math.pow(x2, null);
x2 = Math.pow(x2, undefined);
var x3;
x3 = Math.pow(x3, a);
x3 = Math.pow(x3, b);
x3 = Math.pow(x3, c);
x3 = Math.pow(x3, null);
x3 = Math.pow(x3, undefined);
@@ -0,0 +1,84 @@
=== tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCanBeAssigned1.ts ===
enum E { a, b, c }
>E : Symbol(E, Decl(compoundExponentiationAssignmentLHSCanBeAssigned1.ts, 0, 0))
>a : Symbol(E.a, Decl(compoundExponentiationAssignmentLHSCanBeAssigned1.ts, 0, 8))
>b : Symbol(E.b, Decl(compoundExponentiationAssignmentLHSCanBeAssigned1.ts, 0, 11))
>c : Symbol(E.c, Decl(compoundExponentiationAssignmentLHSCanBeAssigned1.ts, 0, 14))
var a: any;
>a : Symbol(a, Decl(compoundExponentiationAssignmentLHSCanBeAssigned1.ts, 2, 3))
var b: number;
>b : Symbol(b, Decl(compoundExponentiationAssignmentLHSCanBeAssigned1.ts, 3, 3))
var c: E;
>c : Symbol(c, Decl(compoundExponentiationAssignmentLHSCanBeAssigned1.ts, 4, 3))
>E : Symbol(E, Decl(compoundExponentiationAssignmentLHSCanBeAssigned1.ts, 0, 0))
var x1: any;
>x1 : Symbol(x1, Decl(compoundExponentiationAssignmentLHSCanBeAssigned1.ts, 6, 3))
x1 **= a;
>x1 : Symbol(x1, Decl(compoundExponentiationAssignmentLHSCanBeAssigned1.ts, 6, 3))
>a : Symbol(a, Decl(compoundExponentiationAssignmentLHSCanBeAssigned1.ts, 2, 3))
x1 **= b;
>x1 : Symbol(x1, Decl(compoundExponentiationAssignmentLHSCanBeAssigned1.ts, 6, 3))
>b : Symbol(b, Decl(compoundExponentiationAssignmentLHSCanBeAssigned1.ts, 3, 3))
x1 **= c;
>x1 : Symbol(x1, Decl(compoundExponentiationAssignmentLHSCanBeAssigned1.ts, 6, 3))
>c : Symbol(c, Decl(compoundExponentiationAssignmentLHSCanBeAssigned1.ts, 4, 3))
x1 **= null;
>x1 : Symbol(x1, Decl(compoundExponentiationAssignmentLHSCanBeAssigned1.ts, 6, 3))
x1 **= undefined;
>x1 : Symbol(x1, Decl(compoundExponentiationAssignmentLHSCanBeAssigned1.ts, 6, 3))
>undefined : Symbol(undefined)
var x2: number;
>x2 : Symbol(x2, Decl(compoundExponentiationAssignmentLHSCanBeAssigned1.ts, 13, 3))
x2 **= a;
>x2 : Symbol(x2, Decl(compoundExponentiationAssignmentLHSCanBeAssigned1.ts, 13, 3))
>a : Symbol(a, Decl(compoundExponentiationAssignmentLHSCanBeAssigned1.ts, 2, 3))
x2 **= b;
>x2 : Symbol(x2, Decl(compoundExponentiationAssignmentLHSCanBeAssigned1.ts, 13, 3))
>b : Symbol(b, Decl(compoundExponentiationAssignmentLHSCanBeAssigned1.ts, 3, 3))
x2 **= c;
>x2 : Symbol(x2, Decl(compoundExponentiationAssignmentLHSCanBeAssigned1.ts, 13, 3))
>c : Symbol(c, Decl(compoundExponentiationAssignmentLHSCanBeAssigned1.ts, 4, 3))
x2 **= null;
>x2 : Symbol(x2, Decl(compoundExponentiationAssignmentLHSCanBeAssigned1.ts, 13, 3))
x2 **= undefined;
>x2 : Symbol(x2, Decl(compoundExponentiationAssignmentLHSCanBeAssigned1.ts, 13, 3))
>undefined : Symbol(undefined)
var x3: E;
>x3 : Symbol(x3, Decl(compoundExponentiationAssignmentLHSCanBeAssigned1.ts, 20, 3))
>E : Symbol(E, Decl(compoundExponentiationAssignmentLHSCanBeAssigned1.ts, 0, 0))
x3 **= a;
>x3 : Symbol(x3, Decl(compoundExponentiationAssignmentLHSCanBeAssigned1.ts, 20, 3))
>a : Symbol(a, Decl(compoundExponentiationAssignmentLHSCanBeAssigned1.ts, 2, 3))
x3 **= b;
>x3 : Symbol(x3, Decl(compoundExponentiationAssignmentLHSCanBeAssigned1.ts, 20, 3))
>b : Symbol(b, Decl(compoundExponentiationAssignmentLHSCanBeAssigned1.ts, 3, 3))
x3 **= c;
>x3 : Symbol(x3, Decl(compoundExponentiationAssignmentLHSCanBeAssigned1.ts, 20, 3))
>c : Symbol(c, Decl(compoundExponentiationAssignmentLHSCanBeAssigned1.ts, 4, 3))
x3 **= null;
>x3 : Symbol(x3, Decl(compoundExponentiationAssignmentLHSCanBeAssigned1.ts, 20, 3))
x3 **= undefined;
>x3 : Symbol(x3, Decl(compoundExponentiationAssignmentLHSCanBeAssigned1.ts, 20, 3))
>undefined : Symbol(undefined)
@@ -0,0 +1,102 @@
=== tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCanBeAssigned1.ts ===
enum E { a, b, c }
>E : E
>a : E
>b : E
>c : E
var a: any;
>a : any
var b: number;
>b : number
var c: E;
>c : E
>E : E
var x1: any;
>x1 : any
x1 **= a;
>x1 **= a : number
>x1 : any
>a : any
x1 **= b;
>x1 **= b : number
>x1 : any
>b : number
x1 **= c;
>x1 **= c : number
>x1 : any
>c : E
x1 **= null;
>x1 **= null : number
>x1 : any
>null : null
x1 **= undefined;
>x1 **= undefined : number
>x1 : any
>undefined : undefined
var x2: number;
>x2 : number
x2 **= a;
>x2 **= a : number
>x2 : number
>a : any
x2 **= b;
>x2 **= b : number
>x2 : number
>b : number
x2 **= c;
>x2 **= c : number
>x2 : number
>c : E
x2 **= null;
>x2 **= null : number
>x2 : number
>null : null
x2 **= undefined;
>x2 **= undefined : number
>x2 : number
>undefined : undefined
var x3: E;
>x3 : E
>E : E
x3 **= a;
>x3 **= a : number
>x3 : E
>a : any
x3 **= b;
>x3 **= b : number
>x3 : E
>b : number
x3 **= c;
>x3 **= c : number
>x3 : E
>c : E
x3 **= null;
>x3 **= null : number
>x3 : E
>null : null
x3 **= undefined;
>x3 **= undefined : number
>x3 : E
>undefined : undefined
@@ -0,0 +1,267 @@
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(7,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(8,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(8,8): error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(9,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(9,8): error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(10,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(11,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(11,8): error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(12,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(13,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(13,8): error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(14,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(14,8): error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(15,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(15,8): error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(18,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(19,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(19,8): error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(20,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(20,8): error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(21,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(22,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(22,8): error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(23,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(24,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(24,8): error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(25,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(25,8): error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(26,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(26,8): error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(29,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(30,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(30,8): error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(31,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(31,8): error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(32,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(33,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(33,8): error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(34,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(35,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(35,8): error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(36,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(36,8): error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(37,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(37,8): error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(40,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(41,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(41,8): error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(42,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(42,8): error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(43,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(44,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(44,8): error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(45,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(46,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(46,8): error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(47,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(47,8): error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(48,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(48,8): error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(51,8): error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(52,8): error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(53,8): error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(54,8): error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(57,8): error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(58,8): error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(59,8): error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts(60,8): error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
==== tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSCannotBeAssigned.ts (68 errors) ====
enum E { a, b }
var a: any;
var b: void;
var x1: boolean;
x1 **= a;
~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
x1 **= b;
~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~
!!! error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
x1 **= true;
~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~
!!! error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
x1 **= 0;
~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
x1 **= ''
~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~
!!! error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
x1 **= E.a;
~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
x1 **= {};
~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~
!!! error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
x1 **= null;
~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~
!!! error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
x1 **= undefined;
~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~~
!!! error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
var x2: string;
x2 **= a;
~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
x2 **= b;
~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~
!!! error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
x2 **= true;
~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~
!!! error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
x2 **= 0;
~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
x2 **= ''
~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~
!!! error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
x2 **= E.a;
~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
x2 **= {};
~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~
!!! error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
x2 **= null;
~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~
!!! error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
x2 **= undefined;
~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~~
!!! error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
var x3: {};
x3 **= a;
~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
x3 **= b;
~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~
!!! error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
x3 **= true;
~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~
!!! error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
x3 **= 0;
~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
x3 **= ''
~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~
!!! error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
x3 **= E.a;
~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
x3 **= {};
~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~
!!! error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
x3 **= null;
~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~
!!! error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
x3 **= undefined;
~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~~
!!! error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
var x4: void;
x4 **= a;
~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
x4 **= b;
~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~
!!! error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
x4 **= true;
~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~
!!! error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
x4 **= 0;
~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
x4 **= ''
~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~
!!! error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
x4 **= E.a;
~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
x4 **= {};
~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~
!!! error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
x4 **= null;
~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~
!!! error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
x4 **= undefined;
~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~~
!!! error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
var x5: number;
x5 **= b;
~
!!! error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
x5 **= true;
~~~~
!!! error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
x5 **= ''
~~
!!! error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
x5 **= {};
~~
!!! error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
var x6: E;
x6 **= b;
~
!!! error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
x6 **= true;
~~~~
!!! error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
x6 **= ''
~~
!!! error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
x6 **= {};
~~
!!! error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
@@ -0,0 +1,120 @@
//// [compoundExponentiationAssignmentLHSCannotBeAssigned.ts]
enum E { a, b }
var a: any;
var b: void;
var x1: boolean;
x1 **= a;
x1 **= b;
x1 **= true;
x1 **= 0;
x1 **= ''
x1 **= E.a;
x1 **= {};
x1 **= null;
x1 **= undefined;
var x2: string;
x2 **= a;
x2 **= b;
x2 **= true;
x2 **= 0;
x2 **= ''
x2 **= E.a;
x2 **= {};
x2 **= null;
x2 **= undefined;
var x3: {};
x3 **= a;
x3 **= b;
x3 **= true;
x3 **= 0;
x3 **= ''
x3 **= E.a;
x3 **= {};
x3 **= null;
x3 **= undefined;
var x4: void;
x4 **= a;
x4 **= b;
x4 **= true;
x4 **= 0;
x4 **= ''
x4 **= E.a;
x4 **= {};
x4 **= null;
x4 **= undefined;
var x5: number;
x5 **= b;
x5 **= true;
x5 **= ''
x5 **= {};
var x6: E;
x6 **= b;
x6 **= true;
x6 **= ''
x6 **= {};
//// [compoundExponentiationAssignmentLHSCannotBeAssigned.js]
var E;
(function (E) {
E[E["a"] = 0] = "a";
E[E["b"] = 1] = "b";
})(E || (E = {}));
var a;
var b;
var x1;
x1 = Math.pow(x1, a);
x1 = Math.pow(x1, b);
x1 = Math.pow(x1, true);
x1 = Math.pow(x1, 0);
x1 = Math.pow(x1, '');
x1 = Math.pow(x1, E.a);
x1 = Math.pow(x1, {});
x1 = Math.pow(x1, null);
x1 = Math.pow(x1, undefined);
var x2;
x2 = Math.pow(x2, a);
x2 = Math.pow(x2, b);
x2 = Math.pow(x2, true);
x2 = Math.pow(x2, 0);
x2 = Math.pow(x2, '');
x2 = Math.pow(x2, E.a);
x2 = Math.pow(x2, {});
x2 = Math.pow(x2, null);
x2 = Math.pow(x2, undefined);
var x3;
x3 = Math.pow(x3, a);
x3 = Math.pow(x3, b);
x3 = Math.pow(x3, true);
x3 = Math.pow(x3, 0);
x3 = Math.pow(x3, '');
x3 = Math.pow(x3, E.a);
x3 = Math.pow(x3, {});
x3 = Math.pow(x3, null);
x3 = Math.pow(x3, undefined);
var x4;
x4 = Math.pow(x4, a);
x4 = Math.pow(x4, b);
x4 = Math.pow(x4, true);
x4 = Math.pow(x4, 0);
x4 = Math.pow(x4, '');
x4 = Math.pow(x4, E.a);
x4 = Math.pow(x4, {});
x4 = Math.pow(x4, null);
x4 = Math.pow(x4, undefined);
var x5;
x5 = Math.pow(x5, b);
x5 = Math.pow(x5, true);
x5 = Math.pow(x5, '');
x5 = Math.pow(x5, {});
var x6;
x6 = Math.pow(x6, b);
x6 = Math.pow(x6, true);
x6 = Math.pow(x6, '');
x6 = Math.pow(x6, {});
@@ -0,0 +1,48 @@
//// [compoundExponentiationAssignmentLHSIsReference.ts]
var value;
// identifiers: variable and parameter
var x1: number;
x1 **= value;
function fn1(x2: number) {
x2 **= value;
}
// property accesses
var x3: { a: number };
x3.a **= value;
x3['a'] **= value;
// parentheses, the contained expression is reference
(x1) **= value;
function fn2(x4: number) {
(x4) **= value;
}
(x3.a) **= value;
(x3['a']) **= value;
//// [compoundExponentiationAssignmentLHSIsReference.js]
var value;
// identifiers: variable and parameter
var x1;
x1 = Math.pow(x1, value);
function fn1(x2) {
x2 = Math.pow(x2, value);
}
// property accesses
var x3;
(_a = x3, _a.a = Math.pow(_a.a, value));
(_b = x3, _b['a'] = Math.pow(_b['a'], value));
// parentheses, the contained expression is reference
(x1) = Math.pow((x1), value);
function fn2(x4) {
(x4) = Math.pow((x4), value);
}
(x3.a) = Math.pow((x3.a), value);
(x3['a']) = Math.pow((x3['a']), value);
var _a, _b;
@@ -0,0 +1,62 @@
=== tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSIsReference.ts ===
var value;
>value : Symbol(value, Decl(compoundExponentiationAssignmentLHSIsReference.ts, 0, 3))
// identifiers: variable and parameter
var x1: number;
>x1 : Symbol(x1, Decl(compoundExponentiationAssignmentLHSIsReference.ts, 3, 3))
x1 **= value;
>x1 : Symbol(x1, Decl(compoundExponentiationAssignmentLHSIsReference.ts, 3, 3))
>value : Symbol(value, Decl(compoundExponentiationAssignmentLHSIsReference.ts, 0, 3))
function fn1(x2: number) {
>fn1 : Symbol(fn1, Decl(compoundExponentiationAssignmentLHSIsReference.ts, 4, 13))
>x2 : Symbol(x2, Decl(compoundExponentiationAssignmentLHSIsReference.ts, 6, 13))
x2 **= value;
>x2 : Symbol(x2, Decl(compoundExponentiationAssignmentLHSIsReference.ts, 6, 13))
>value : Symbol(value, Decl(compoundExponentiationAssignmentLHSIsReference.ts, 0, 3))
}
// property accesses
var x3: { a: number };
>x3 : Symbol(x3, Decl(compoundExponentiationAssignmentLHSIsReference.ts, 11, 3))
>a : Symbol(a, Decl(compoundExponentiationAssignmentLHSIsReference.ts, 11, 9))
x3.a **= value;
>x3.a : Symbol(a, Decl(compoundExponentiationAssignmentLHSIsReference.ts, 11, 9))
>x3 : Symbol(x3, Decl(compoundExponentiationAssignmentLHSIsReference.ts, 11, 3))
>a : Symbol(a, Decl(compoundExponentiationAssignmentLHSIsReference.ts, 11, 9))
>value : Symbol(value, Decl(compoundExponentiationAssignmentLHSIsReference.ts, 0, 3))
x3['a'] **= value;
>x3 : Symbol(x3, Decl(compoundExponentiationAssignmentLHSIsReference.ts, 11, 3))
>'a' : Symbol(a, Decl(compoundExponentiationAssignmentLHSIsReference.ts, 11, 9))
>value : Symbol(value, Decl(compoundExponentiationAssignmentLHSIsReference.ts, 0, 3))
// parentheses, the contained expression is reference
(x1) **= value;
>x1 : Symbol(x1, Decl(compoundExponentiationAssignmentLHSIsReference.ts, 3, 3))
>value : Symbol(value, Decl(compoundExponentiationAssignmentLHSIsReference.ts, 0, 3))
function fn2(x4: number) {
>fn2 : Symbol(fn2, Decl(compoundExponentiationAssignmentLHSIsReference.ts, 17, 15))
>x4 : Symbol(x4, Decl(compoundExponentiationAssignmentLHSIsReference.ts, 19, 13))
(x4) **= value;
>x4 : Symbol(x4, Decl(compoundExponentiationAssignmentLHSIsReference.ts, 19, 13))
>value : Symbol(value, Decl(compoundExponentiationAssignmentLHSIsReference.ts, 0, 3))
}
(x3.a) **= value;
>x3.a : Symbol(a, Decl(compoundExponentiationAssignmentLHSIsReference.ts, 11, 9))
>x3 : Symbol(x3, Decl(compoundExponentiationAssignmentLHSIsReference.ts, 11, 3))
>a : Symbol(a, Decl(compoundExponentiationAssignmentLHSIsReference.ts, 11, 9))
>value : Symbol(value, Decl(compoundExponentiationAssignmentLHSIsReference.ts, 0, 3))
(x3['a']) **= value;
>x3 : Symbol(x3, Decl(compoundExponentiationAssignmentLHSIsReference.ts, 11, 3))
>'a' : Symbol(a, Decl(compoundExponentiationAssignmentLHSIsReference.ts, 11, 9))
>value : Symbol(value, Decl(compoundExponentiationAssignmentLHSIsReference.ts, 0, 3))
@@ -0,0 +1,76 @@
=== tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSIsReference.ts ===
var value;
>value : any
// identifiers: variable and parameter
var x1: number;
>x1 : number
x1 **= value;
>x1 **= value : number
>x1 : number
>value : any
function fn1(x2: number) {
>fn1 : (x2: number) => void
>x2 : number
x2 **= value;
>x2 **= value : number
>x2 : number
>value : any
}
// property accesses
var x3: { a: number };
>x3 : { a: number; }
>a : number
x3.a **= value;
>x3.a **= value : number
>x3.a : number
>x3 : { a: number; }
>a : number
>value : any
x3['a'] **= value;
>x3['a'] **= value : number
>x3['a'] : number
>x3 : { a: number; }
>'a' : string
>value : any
// parentheses, the contained expression is reference
(x1) **= value;
>(x1) **= value : number
>(x1) : number
>x1 : number
>value : any
function fn2(x4: number) {
>fn2 : (x4: number) => void
>x4 : number
(x4) **= value;
>(x4) **= value : number
>(x4) : number
>x4 : number
>value : any
}
(x3.a) **= value;
>(x3.a) **= value : number
>(x3.a) : number
>x3.a : number
>x3 : { a: number; }
>a : number
>value : any
(x3['a']) **= value;
>(x3['a']) **= value : number
>(x3['a']) : number
>x3['a'] : number
>x3 : { a: number; }
>'a' : string
>value : any
@@ -0,0 +1,199 @@
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSIsValue.ts(7,9): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSIsValue.ts(10,9): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSIsValue.ts(13,9): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSIsValue.ts(18,5): error TS2364: Invalid left-hand side of assignment expression.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSIsValue.ts(21,1): error TS2364: Invalid left-hand side of assignment expression.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSIsValue.ts(25,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSIsValue.ts(27,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSIsValue.ts(30,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSIsValue.ts(32,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSIsValue.ts(35,1): error TS2364: Invalid left-hand side of assignment expression.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSIsValue.ts(36,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSIsValue.ts(37,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSIsValue.ts(38,1): error TS2364: Invalid left-hand side of assignment expression.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSIsValue.ts(39,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSIsValue.ts(40,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSIsValue.ts(43,10): error TS1128: Declaration or statement expected.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSIsValue.ts(46,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSIsValue.ts(52,15): error TS1034: 'super' must be followed by an argument list or member access.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSIsValue.ts(56,15): error TS1034: 'super' must be followed by an argument list or member access.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSIsValue.ts(60,15): error TS1034: 'super' must be followed by an argument list or member access.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSIsValue.ts(65,21): error TS1128: Declaration or statement expected.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSIsValue.ts(66,11): error TS1005: ';' expected.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSIsValue.ts(69,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSIsValue.ts(72,1): error TS2364: Invalid left-hand side of assignment expression.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSIsValue.ts(73,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSIsValue.ts(74,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSIsValue.ts(75,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSIsValue.ts(76,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSIsValue.ts(77,1): error TS2364: Invalid left-hand side of assignment expression.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSIsValue.ts(78,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSIsValue.ts(79,1): error TS2364: Invalid left-hand side of assignment expression.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSIsValue.ts(80,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSIsValue.ts(81,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSIsValue.ts(82,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSIsValue.ts(83,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSIsValue.ts(84,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSIsValue.ts(85,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
==== tests/cases/conformance/es7/exponentiationOperator/compoundExponentiationAssignmentLHSIsValue.ts (37 errors) ====
// expected error for all the LHS of compound assignments (arithmetic and addition)
var value;
// this
class C {
constructor() {
this **= value;
~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
}
foo() {
this **= value;
~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
}
static sfoo() {
this **= value;
~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
}
}
function foo() {
this **= value;
~~~~
!!! error TS2364: Invalid left-hand side of assignment expression.
}
this **= value;
~~~~
!!! error TS2364: Invalid left-hand side of assignment expression.
// identifiers: module, class, enum, function
module M { export var a; }
M **= value;
~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
C **= value;
~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
enum E { }
E **= value;
~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
foo **= value;
~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
// literals
null **= value;
~~~~
!!! error TS2364: Invalid left-hand side of assignment expression.
true **= value;
~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
false **= value;
~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
0 **= value;
~
!!! error TS2364: Invalid left-hand side of assignment expression.
'' **= value;
~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
/d+/ **= value;
~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
// object literals
{ a: 0 } **= value;
~~~
!!! error TS1128: Declaration or statement expected.
// array literals
['', ''] **= value;
~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
// super
class Derived extends C {
constructor() {
super();
super **= value;
~~~
!!! error TS1034: 'super' must be followed by an argument list or member access.
}
foo() {
super **= value;
~~~
!!! error TS1034: 'super' must be followed by an argument list or member access.
}
static sfoo() {
super **= value;
~~~
!!! error TS1034: 'super' must be followed by an argument list or member access.
}
}
// function expression
function bar1() { } **= value;
~~~
!!! error TS1128: Declaration or statement expected.
() => { } **= value;
~~~
!!! error TS1005: ';' expected.
// function calls
foo() **= value;
~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
// parentheses, the containted expression is value
(this) **= value;
~~~~~~
!!! error TS2364: Invalid left-hand side of assignment expression.
(M) **= value;
~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
(C) **= value;
~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
(E) **= value;
~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
(foo) **= value;
~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
(null) **= value;
~~~~~~
!!! error TS2364: Invalid left-hand side of assignment expression.
(true) **= value;
~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
(0) **= value;
~~~
!!! error TS2364: Invalid left-hand side of assignment expression.
('') **= value;
~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
(/d+/) **= value;
~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
({}) **= value;
~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
([]) **= value;
~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
(function baz1() { }) **= value;
~~~~~~~~~~~~~~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
(foo()) **= value;
~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
@@ -0,0 +1,177 @@
//// [compoundExponentiationAssignmentLHSIsValue.ts]
// expected error for all the LHS of compound assignments (arithmetic and addition)
var value;
// this
class C {
constructor() {
this **= value;
}
foo() {
this **= value;
}
static sfoo() {
this **= value;
}
}
function foo() {
this **= value;
}
this **= value;
// identifiers: module, class, enum, function
module M { export var a; }
M **= value;
C **= value;
enum E { }
E **= value;
foo **= value;
// literals
null **= value;
true **= value;
false **= value;
0 **= value;
'' **= value;
/d+/ **= value;
// object literals
{ a: 0 } **= value;
// array literals
['', ''] **= value;
// super
class Derived extends C {
constructor() {
super();
super **= value;
}
foo() {
super **= value;
}
static sfoo() {
super **= value;
}
}
// function expression
function bar1() { } **= value;
() => { } **= value;
// function calls
foo() **= value;
// parentheses, the containted expression is value
(this) **= value;
(M) **= value;
(C) **= value;
(E) **= value;
(foo) **= value;
(null) **= value;
(true) **= value;
(0) **= value;
('') **= value;
(/d+/) **= value;
({}) **= value;
([]) **= value;
(function baz1() { }) **= value;
(foo()) **= value;
//// [compoundExponentiationAssignmentLHSIsValue.js]
var __extends = (this && this.__extends) || function (d, b) {
for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p];
function __() { this.constructor = d; }
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
};
// expected error for all the LHS of compound assignments (arithmetic and addition)
var value;
// this
var C = (function () {
function C() {
this = Math.pow(this, value);
}
C.prototype.foo = function () {
this = Math.pow(this, value);
};
C.sfoo = function () {
this = Math.pow(this, value);
};
return C;
})();
function foo() {
this = Math.pow(this, value);
}
this = Math.pow(this, value);
// identifiers: module, class, enum, function
var M;
(function (M) {
})(M || (M = {}));
M = Math.pow(M, value);
C = Math.pow(C, value);
var E;
(function (E) {
})(E || (E = {}));
E = Math.pow(E, value);
foo = Math.pow(foo, value);
// literals
null = Math.pow(null, value);
true = Math.pow(true, value);
false = Math.pow(false, value);
0 = Math.pow(0, value);
'' = Math.pow('', value);
/d+/ = Math.pow(/d+/, value);
// object literals
{
a: 0;
}
value;
// array literals
['', ''] = Math.pow(['', ''], value);
// super
var Derived = (function (_super) {
__extends(Derived, _super);
function Derived() {
_super.call(this);
(_a = _super.prototype, _a. = Math.pow(_a., value));
var _a;
}
Derived.prototype.foo = function () {
(_a = _super.prototype, _a. = Math.pow(_a., value));
var _a;
};
Derived.sfoo = function () {
(_a = _super, _a. = Math.pow(_a., value));
var _a;
};
return Derived;
})(C);
// function expression
function bar1() { }
value;
(function () { });
value;
// function calls
foo() = Math.pow(foo(), value);
// parentheses, the containted expression is value
(this) = Math.pow((this), value);
(M) = Math.pow((M), value);
(C) = Math.pow((C), value);
(E) = Math.pow((E), value);
(foo) = Math.pow((foo), value);
(null) = Math.pow((null), value);
(true) = Math.pow((true), value);
(0) = Math.pow((0), value);
('') = Math.pow((''), value);
(/d+/) = Math.pow((/d+/), value);
({}) = Math.pow(({}), value);
([]) = Math.pow(([]), value);
(function baz1() { }) = Math.pow((function baz1() { }), value);
(foo()) = Math.pow((foo()), value);
@@ -36,15 +36,21 @@ tests/cases/conformance/expressions/unaryOperators/decrementOperator/decrementOp
tests/cases/conformance/expressions/unaryOperators/decrementOperator/decrementOperatorWithAnyOtherTypeInvalidOperations.ts(60,24): error TS2356: An arithmetic operand must be of type 'any', 'number' or an enum type.
tests/cases/conformance/expressions/unaryOperators/decrementOperator/decrementOperatorWithAnyOtherTypeInvalidOperations.ts(63,3): error TS2356: An arithmetic operand must be of type 'any', 'number' or an enum type.
tests/cases/conformance/expressions/unaryOperators/decrementOperator/decrementOperatorWithAnyOtherTypeInvalidOperations.ts(65,1): error TS2356: An arithmetic operand must be of type 'any', 'number' or an enum type.
tests/cases/conformance/expressions/unaryOperators/decrementOperator/decrementOperatorWithAnyOtherTypeInvalidOperations.ts(67,3): error TS2357: The operand of an increment or decrement operator must be a variable, property or indexer.
tests/cases/conformance/expressions/unaryOperators/decrementOperator/decrementOperatorWithAnyOtherTypeInvalidOperations.ts(68,3): error TS2357: The operand of an increment or decrement operator must be a variable, property or indexer.
tests/cases/conformance/expressions/unaryOperators/decrementOperator/decrementOperatorWithAnyOtherTypeInvalidOperations.ts(69,3): error TS2357: The operand of an increment or decrement operator must be a variable, property or indexer.
tests/cases/conformance/expressions/unaryOperators/decrementOperator/decrementOperatorWithAnyOtherTypeInvalidOperations.ts(70,3): error TS2357: The operand of an increment or decrement operator must be a variable, property or indexer.
tests/cases/conformance/expressions/unaryOperators/decrementOperator/decrementOperatorWithAnyOtherTypeInvalidOperations.ts(71,3): error TS2357: The operand of an increment or decrement operator must be a variable, property or indexer.
tests/cases/conformance/expressions/unaryOperators/decrementOperator/decrementOperatorWithAnyOtherTypeInvalidOperations.ts(72,3): error TS2357: The operand of an increment or decrement operator must be a variable, property or indexer.
tests/cases/conformance/expressions/unaryOperators/decrementOperator/decrementOperatorWithAnyOtherTypeInvalidOperations.ts(67,7): error TS1005: ';' expected.
tests/cases/conformance/expressions/unaryOperators/decrementOperator/decrementOperatorWithAnyOtherTypeInvalidOperations.ts(67,9): error TS1109: Expression expected.
tests/cases/conformance/expressions/unaryOperators/decrementOperator/decrementOperatorWithAnyOtherTypeInvalidOperations.ts(68,7): error TS1005: ';' expected.
tests/cases/conformance/expressions/unaryOperators/decrementOperator/decrementOperatorWithAnyOtherTypeInvalidOperations.ts(68,9): error TS1109: Expression expected.
tests/cases/conformance/expressions/unaryOperators/decrementOperator/decrementOperatorWithAnyOtherTypeInvalidOperations.ts(69,7): error TS1005: ';' expected.
tests/cases/conformance/expressions/unaryOperators/decrementOperator/decrementOperatorWithAnyOtherTypeInvalidOperations.ts(69,9): error TS1109: Expression expected.
tests/cases/conformance/expressions/unaryOperators/decrementOperator/decrementOperatorWithAnyOtherTypeInvalidOperations.ts(70,10): error TS1005: ';' expected.
tests/cases/conformance/expressions/unaryOperators/decrementOperator/decrementOperatorWithAnyOtherTypeInvalidOperations.ts(70,12): error TS1109: Expression expected.
tests/cases/conformance/expressions/unaryOperators/decrementOperator/decrementOperatorWithAnyOtherTypeInvalidOperations.ts(71,10): error TS1005: ';' expected.
tests/cases/conformance/expressions/unaryOperators/decrementOperator/decrementOperatorWithAnyOtherTypeInvalidOperations.ts(71,12): error TS1109: Expression expected.
tests/cases/conformance/expressions/unaryOperators/decrementOperator/decrementOperatorWithAnyOtherTypeInvalidOperations.ts(72,10): error TS1005: ';' expected.
tests/cases/conformance/expressions/unaryOperators/decrementOperator/decrementOperatorWithAnyOtherTypeInvalidOperations.ts(72,12): error TS1109: Expression expected.
==== tests/cases/conformance/expressions/unaryOperators/decrementOperator/decrementOperatorWithAnyOtherTypeInvalidOperations.ts (44 errors) ====
==== tests/cases/conformance/expressions/unaryOperators/decrementOperator/decrementOperatorWithAnyOtherTypeInvalidOperations.ts (50 errors) ====
// -- operator on any type
var ANY1;
var ANY2: any[] = ["", ""];
@@ -188,20 +194,32 @@ tests/cases/conformance/expressions/unaryOperators/decrementOperator/decrementOp
!!! error TS2356: An arithmetic operand must be of type 'any', 'number' or an enum type.
--ANY1--;
~~~~~~
!!! error TS2357: The operand of an increment or decrement operator must be a variable, property or indexer.
~~
!!! error TS1005: ';' expected.
~
!!! error TS1109: Expression expected.
--ANY1++;
~~~~~~
!!! error TS2357: The operand of an increment or decrement operator must be a variable, property or indexer.
~~
!!! error TS1005: ';' expected.
~
!!! error TS1109: Expression expected.
++ANY1--;
~~~~~~
!!! error TS2357: The operand of an increment or decrement operator must be a variable, property or indexer.
~~
!!! error TS1005: ';' expected.
~
!!! error TS1109: Expression expected.
--ANY2[0]--;
~~~~~~~~~
!!! error TS2357: The operand of an increment or decrement operator must be a variable, property or indexer.
~~
!!! error TS1005: ';' expected.
~
!!! error TS1109: Expression expected.
--ANY2[0]++;
~~~~~~~~~
!!! error TS2357: The operand of an increment or decrement operator must be a variable, property or indexer.
~~
!!! error TS1005: ';' expected.
~
!!! error TS1109: Expression expected.
++ANY2[0]--;
~~~~~~~~~
!!! error TS2357: The operand of an increment or decrement operator must be a variable, property or indexer.
~~
!!! error TS1005: ';' expected.
~
!!! error TS1109: Expression expected.
@@ -131,9 +131,15 @@ var ResultIsNumber30 = obj1.y--;
// miss assignment operators
--ANY2;
ANY2--;
--ANY1--;
--ANY1++;
++ANY1--;
--ANY2[0]--;
--ANY2[0]++;
++ANY2[0]--;
--ANY1;
--;
--ANY1;
++;
++ANY1;
--;
--ANY2[0];
--;
--ANY2[0];
++;
++ANY2[0];
--;
@@ -0,0 +1,32 @@
//// [emitCompoundExponentiationAssignmentWithIndexingOnLHS1.ts]
var array0 = [1, 2, 3]
var i0 = 0;
array0[++i0] **= 2;
var array1 = [1, 2, 3]
var i1 = 0;
array1[++i1] **= array1[++i1] **= 2;
var array2 = [1, 2, 3]
var i2 = 0;
array2[++i2] **= array2[++i2] ** 2;
var array3 = [2, 2, 3];
var j0 = 0, j1 = 1;
array3[j0++] **= array3[j1++] **= array3[j0++] **= 1;
//// [emitCompoundExponentiationAssignmentWithIndexingOnLHS1.js]
var array0 = [1, 2, 3];
var i0 = 0;
(_a = array0, _i = ++i0, _a[_i] = Math.pow(_a[_i], 2));
var array1 = [1, 2, 3];
var i1 = 0;
(_b = array1, _c = ++i1, _b[_c] = Math.pow(_b[_c], (_d = array1, _e = ++i1, _d[_e] = Math.pow(_d[_e], 2))));
var array2 = [1, 2, 3];
var i2 = 0;
(_f = array2, _g = ++i2, _f[_g] = Math.pow(_f[_g], Math.pow(array2[++i2], 2)));
var array3 = [2, 2, 3];
var j0 = 0, j1 = 1;
(_h = array3, _j = j0++, _h[_j] = Math.pow(_h[_j], (_k = array3, _l = j1++, _k[_l] = Math.pow(_k[_l], (_m = array3, _o = j0++, _m[_o] = Math.pow(_m[_o], 1))))));
var _a, _i, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o;
@@ -0,0 +1,51 @@
=== tests/cases/conformance/es7/exponentiationOperator/emitCompoundExponentiationAssignmentWithIndexingOnLHS1.ts ===
var array0 = [1, 2, 3]
>array0 : Symbol(array0, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS1.ts, 1, 3))
var i0 = 0;
>i0 : Symbol(i0, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS1.ts, 2, 3))
array0[++i0] **= 2;
>array0 : Symbol(array0, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS1.ts, 1, 3))
>i0 : Symbol(i0, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS1.ts, 2, 3))
var array1 = [1, 2, 3]
>array1 : Symbol(array1, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS1.ts, 5, 3))
var i1 = 0;
>i1 : Symbol(i1, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS1.ts, 6, 3))
array1[++i1] **= array1[++i1] **= 2;
>array1 : Symbol(array1, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS1.ts, 5, 3))
>i1 : Symbol(i1, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS1.ts, 6, 3))
>array1 : Symbol(array1, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS1.ts, 5, 3))
>i1 : Symbol(i1, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS1.ts, 6, 3))
var array2 = [1, 2, 3]
>array2 : Symbol(array2, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS1.ts, 9, 3))
var i2 = 0;
>i2 : Symbol(i2, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS1.ts, 10, 3))
array2[++i2] **= array2[++i2] ** 2;
>array2 : Symbol(array2, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS1.ts, 9, 3))
>i2 : Symbol(i2, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS1.ts, 10, 3))
>array2 : Symbol(array2, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS1.ts, 9, 3))
>i2 : Symbol(i2, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS1.ts, 10, 3))
var array3 = [2, 2, 3];
>array3 : Symbol(array3, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS1.ts, 13, 3))
var j0 = 0, j1 = 1;
>j0 : Symbol(j0, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS1.ts, 14, 3))
>j1 : Symbol(j1, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS1.ts, 14, 11))
array3[j0++] **= array3[j1++] **= array3[j0++] **= 1;
>array3 : Symbol(array3, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS1.ts, 13, 3))
>j0 : Symbol(j0, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS1.ts, 14, 3))
>array3 : Symbol(array3, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS1.ts, 13, 3))
>j1 : Symbol(j1, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS1.ts, 14, 11))
>array3 : Symbol(array3, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS1.ts, 13, 3))
>j0 : Symbol(j0, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS1.ts, 14, 3))
@@ -0,0 +1,100 @@
=== tests/cases/conformance/es7/exponentiationOperator/emitCompoundExponentiationAssignmentWithIndexingOnLHS1.ts ===
var array0 = [1, 2, 3]
>array0 : number[]
>[1, 2, 3] : number[]
>1 : number
>2 : number
>3 : number
var i0 = 0;
>i0 : number
>0 : number
array0[++i0] **= 2;
>array0[++i0] **= 2 : number
>array0[++i0] : number
>array0 : number[]
>++i0 : number
>i0 : number
>2 : number
var array1 = [1, 2, 3]
>array1 : number[]
>[1, 2, 3] : number[]
>1 : number
>2 : number
>3 : number
var i1 = 0;
>i1 : number
>0 : number
array1[++i1] **= array1[++i1] **= 2;
>array1[++i1] **= array1[++i1] **= 2 : number
>array1[++i1] : number
>array1 : number[]
>++i1 : number
>i1 : number
>array1[++i1] **= 2 : number
>array1[++i1] : number
>array1 : number[]
>++i1 : number
>i1 : number
>2 : number
var array2 = [1, 2, 3]
>array2 : number[]
>[1, 2, 3] : number[]
>1 : number
>2 : number
>3 : number
var i2 = 0;
>i2 : number
>0 : number
array2[++i2] **= array2[++i2] ** 2;
>array2[++i2] **= array2[++i2] ** 2 : number
>array2[++i2] : number
>array2 : number[]
>++i2 : number
>i2 : number
>array2[++i2] ** 2 : number
>array2[++i2] : number
>array2 : number[]
>++i2 : number
>i2 : number
>2 : number
var array3 = [2, 2, 3];
>array3 : number[]
>[2, 2, 3] : number[]
>2 : number
>2 : number
>3 : number
var j0 = 0, j1 = 1;
>j0 : number
>0 : number
>j1 : number
>1 : number
array3[j0++] **= array3[j1++] **= array3[j0++] **= 1;
>array3[j0++] **= array3[j1++] **= array3[j0++] **= 1 : number
>array3[j0++] : number
>array3 : number[]
>j0++ : number
>j0 : number
>array3[j1++] **= array3[j0++] **= 1 : number
>array3[j1++] : number
>array3 : number[]
>j1++ : number
>j1 : number
>array3[j0++] **= 1 : number
>array3[j0++] : number
>array3 : number[]
>j0++ : number
>j0 : number
>1 : number
@@ -0,0 +1,26 @@
//// [emitCompoundExponentiationAssignmentWithIndexingOnLHS2.ts]
var globalCounter = 0;
function foo() {
globalCounter += 1;
return { 0: 2 };
}
foo()[0] **= foo()[0];
var result_foo1 = foo()[0] **= foo()[0];
foo()[0] **= foo()[0] **= 2;
var result_foo2 = foo()[0] **= foo()[0] **= 2;
foo()[0] **= foo()[0] ** 2;
var result_foo3 = foo()[0] **= foo()[0] ** 2;
//// [emitCompoundExponentiationAssignmentWithIndexingOnLHS2.js]
var globalCounter = 0;
function foo() {
globalCounter += 1;
return { 0: 2 };
}
(_a = foo(), _a[0] = Math.pow(_a[0], foo()[0]));
var result_foo1 = (_b = foo(), _b[0] = Math.pow(_b[0], foo()[0]));
(_c = foo(), _c[0] = Math.pow(_c[0], (_d = foo(), _d[0] = Math.pow(_d[0], 2))));
var result_foo2 = (_e = foo(), _e[0] = Math.pow(_e[0], (_f = foo(), _f[0] = Math.pow(_f[0], 2))));
(_g = foo(), _g[0] = Math.pow(_g[0], Math.pow(foo()[0], 2)));
var result_foo3 = (_h = foo(), _h[0] = Math.pow(_h[0], Math.pow(foo()[0], 2)));
var _a, _b, _c, _d, _e, _f, _g, _h;
@@ -0,0 +1,51 @@
=== tests/cases/conformance/es7/exponentiationOperator/emitCompoundExponentiationAssignmentWithIndexingOnLHS2.ts ===
var globalCounter = 0;
>globalCounter : Symbol(globalCounter, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS2.ts, 0, 3))
function foo() {
>foo : Symbol(foo, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS2.ts, 0, 22))
globalCounter += 1;
>globalCounter : Symbol(globalCounter, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS2.ts, 0, 3))
return { 0: 2 };
}
foo()[0] **= foo()[0];
>foo : Symbol(foo, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS2.ts, 0, 22))
>0 : Symbol(0, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS2.ts, 3, 12))
>foo : Symbol(foo, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS2.ts, 0, 22))
>0 : Symbol(0, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS2.ts, 3, 12))
var result_foo1 = foo()[0] **= foo()[0];
>result_foo1 : Symbol(result_foo1, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS2.ts, 6, 3))
>foo : Symbol(foo, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS2.ts, 0, 22))
>0 : Symbol(0, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS2.ts, 3, 12))
>foo : Symbol(foo, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS2.ts, 0, 22))
>0 : Symbol(0, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS2.ts, 3, 12))
foo()[0] **= foo()[0] **= 2;
>foo : Symbol(foo, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS2.ts, 0, 22))
>0 : Symbol(0, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS2.ts, 3, 12))
>foo : Symbol(foo, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS2.ts, 0, 22))
>0 : Symbol(0, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS2.ts, 3, 12))
var result_foo2 = foo()[0] **= foo()[0] **= 2;
>result_foo2 : Symbol(result_foo2, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS2.ts, 8, 3))
>foo : Symbol(foo, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS2.ts, 0, 22))
>0 : Symbol(0, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS2.ts, 3, 12))
>foo : Symbol(foo, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS2.ts, 0, 22))
>0 : Symbol(0, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS2.ts, 3, 12))
foo()[0] **= foo()[0] ** 2;
>foo : Symbol(foo, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS2.ts, 0, 22))
>0 : Symbol(0, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS2.ts, 3, 12))
>foo : Symbol(foo, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS2.ts, 0, 22))
>0 : Symbol(0, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS2.ts, 3, 12))
var result_foo3 = foo()[0] **= foo()[0] ** 2;
>result_foo3 : Symbol(result_foo3, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS2.ts, 10, 3))
>foo : Symbol(foo, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS2.ts, 0, 22))
>0 : Symbol(0, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS2.ts, 3, 12))
>foo : Symbol(foo, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS2.ts, 0, 22))
>0 : Symbol(0, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS2.ts, 3, 12))
@@ -0,0 +1,94 @@
=== tests/cases/conformance/es7/exponentiationOperator/emitCompoundExponentiationAssignmentWithIndexingOnLHS2.ts ===
var globalCounter = 0;
>globalCounter : number
>0 : number
function foo() {
>foo : () => { 0: number; }
globalCounter += 1;
>globalCounter += 1 : number
>globalCounter : number
>1 : number
return { 0: 2 };
>{ 0: 2 } : { 0: number; }
>2 : number
}
foo()[0] **= foo()[0];
>foo()[0] **= foo()[0] : number
>foo()[0] : number
>foo() : { 0: number; }
>foo : () => { 0: number; }
>0 : number
>foo()[0] : number
>foo() : { 0: number; }
>foo : () => { 0: number; }
>0 : number
var result_foo1 = foo()[0] **= foo()[0];
>result_foo1 : number
>foo()[0] **= foo()[0] : number
>foo()[0] : number
>foo() : { 0: number; }
>foo : () => { 0: number; }
>0 : number
>foo()[0] : number
>foo() : { 0: number; }
>foo : () => { 0: number; }
>0 : number
foo()[0] **= foo()[0] **= 2;
>foo()[0] **= foo()[0] **= 2 : number
>foo()[0] : number
>foo() : { 0: number; }
>foo : () => { 0: number; }
>0 : number
>foo()[0] **= 2 : number
>foo()[0] : number
>foo() : { 0: number; }
>foo : () => { 0: number; }
>0 : number
>2 : number
var result_foo2 = foo()[0] **= foo()[0] **= 2;
>result_foo2 : number
>foo()[0] **= foo()[0] **= 2 : number
>foo()[0] : number
>foo() : { 0: number; }
>foo : () => { 0: number; }
>0 : number
>foo()[0] **= 2 : number
>foo()[0] : number
>foo() : { 0: number; }
>foo : () => { 0: number; }
>0 : number
>2 : number
foo()[0] **= foo()[0] ** 2;
>foo()[0] **= foo()[0] ** 2 : number
>foo()[0] : number
>foo() : { 0: number; }
>foo : () => { 0: number; }
>0 : number
>foo()[0] ** 2 : number
>foo()[0] : number
>foo() : { 0: number; }
>foo : () => { 0: number; }
>0 : number
>2 : number
var result_foo3 = foo()[0] **= foo()[0] ** 2;
>result_foo3 : number
>foo()[0] **= foo()[0] ** 2 : number
>foo()[0] : number
>foo() : { 0: number; }
>foo : () => { 0: number; }
>0 : number
>foo()[0] ** 2 : number
>foo()[0] : number
>foo() : { 0: number; }
>foo : () => { 0: number; }
>0 : number
>2 : number
@@ -0,0 +1,29 @@
//// [emitCompoundExponentiationAssignmentWithIndexingOnLHS3.ts]
var object = {
_0: 2,
get 0() {
return this._0;
},
set 0(x: number) {
this._0 = x;
},
}
object[0] **= object[0];
object[0] **= object[0] **= 2;
object[0] **= object[0] ** 2;
//// [emitCompoundExponentiationAssignmentWithIndexingOnLHS3.js]
var object = {
_0: 2,
get 0() {
return this._0;
},
set 0(x) {
this._0 = x;
},
};
(_a = object, _a[0] = Math.pow(_a[0], object[0]));
(_b = object, _b[0] = Math.pow(_b[0], (_c = object, _c[0] = Math.pow(_c[0], 2))));
(_d = object, _d[0] = Math.pow(_d[0], Math.pow(object[0], 2)));
var _a, _b, _c, _d;
@@ -0,0 +1,37 @@
=== tests/cases/conformance/es7/exponentiationOperator/emitCompoundExponentiationAssignmentWithIndexingOnLHS3.ts ===
var object = {
>object : Symbol(object, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS3.ts, 1, 3))
_0: 2,
>_0 : Symbol(_0, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS3.ts, 1, 14))
get 0() {
return this._0;
},
set 0(x: number) {
>x : Symbol(x, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS3.ts, 6, 10))
this._0 = x;
>x : Symbol(x, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS3.ts, 6, 10))
},
}
object[0] **= object[0];
>object : Symbol(object, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS3.ts, 1, 3))
>0 : Symbol(0, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS3.ts, 2, 10), Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS3.ts, 5, 6))
>object : Symbol(object, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS3.ts, 1, 3))
>0 : Symbol(0, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS3.ts, 2, 10), Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS3.ts, 5, 6))
object[0] **= object[0] **= 2;
>object : Symbol(object, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS3.ts, 1, 3))
>0 : Symbol(0, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS3.ts, 2, 10), Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS3.ts, 5, 6))
>object : Symbol(object, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS3.ts, 1, 3))
>0 : Symbol(0, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS3.ts, 2, 10), Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS3.ts, 5, 6))
object[0] **= object[0] ** 2;
>object : Symbol(object, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS3.ts, 1, 3))
>0 : Symbol(0, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS3.ts, 2, 10), Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS3.ts, 5, 6))
>object : Symbol(object, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS3.ts, 1, 3))
>0 : Symbol(0, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS3.ts, 2, 10), Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS3.ts, 5, 6))
@@ -0,0 +1,60 @@
=== tests/cases/conformance/es7/exponentiationOperator/emitCompoundExponentiationAssignmentWithIndexingOnLHS3.ts ===
var object = {
>object : { 0: number; _0: number; }
>{ _0: 2, get 0() { return this._0; }, set 0(x: number) { this._0 = x; },} : { 0: number; _0: number; }
_0: 2,
>_0 : number
>2 : number
get 0() {
return this._0;
>this._0 : any
>this : any
>_0 : any
},
set 0(x: number) {
>x : number
this._0 = x;
>this._0 = x : number
>this._0 : any
>this : any
>_0 : any
>x : number
},
}
object[0] **= object[0];
>object[0] **= object[0] : number
>object[0] : number
>object : { 0: number; _0: number; }
>0 : number
>object[0] : number
>object : { 0: number; _0: number; }
>0 : number
object[0] **= object[0] **= 2;
>object[0] **= object[0] **= 2 : number
>object[0] : number
>object : { 0: number; _0: number; }
>0 : number
>object[0] **= 2 : number
>object[0] : number
>object : { 0: number; _0: number; }
>0 : number
>2 : number
object[0] **= object[0] ** 2;
>object[0] **= object[0] ** 2 : number
>object[0] : number
>object : { 0: number; _0: number; }
>0 : number
>object[0] ** 2 : number
>object[0] : number
>object : { 0: number; _0: number; }
>0 : number
>2 : number
@@ -0,0 +1,29 @@
//// [emitCompoundExponentiationAssignmentWithIndexingOnLHS4.ts]
var globalCounter = 0;
function incrementIdx(max: number) {
globalCounter += 1;
let idx = Math.floor(Math.random() * max);
return idx;
}
var array1 = [1, 2, 3, 4, 5];
array1[incrementIdx(array1.length)] **= 3;
array1[incrementIdx(array1.length)] **= array1[incrementIdx(array1.length)] **= 2;
array1[incrementIdx(array1.length)] **= array1[incrementIdx(array1.length)] ** 2;
//// [emitCompoundExponentiationAssignmentWithIndexingOnLHS4.js]
var globalCounter = 0;
function incrementIdx(max) {
globalCounter += 1;
var idx = Math.floor(Math.random() * max);
return idx;
}
var array1 = [1, 2, 3, 4, 5];
(_a = array1, _i = incrementIdx(array1.length), _a[_i] = Math.pow(_a[_i], 3));
(_b = array1, _c = incrementIdx(array1.length), _b[_c] = Math.pow(_b[_c], (_d = array1, _e = incrementIdx(array1.length), _d[_e] = Math.pow(_d[_e], 2))));
(_f = array1, _g = incrementIdx(array1.length), _f[_g] = Math.pow(_f[_g], Math.pow(array1[incrementIdx(array1.length)], 2)));
var _a, _i, _b, _c, _d, _e, _f, _g;
@@ -0,0 +1,60 @@
=== tests/cases/conformance/es7/exponentiationOperator/emitCompoundExponentiationAssignmentWithIndexingOnLHS4.ts ===
var globalCounter = 0;
>globalCounter : Symbol(globalCounter, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS4.ts, 1, 3))
function incrementIdx(max: number) {
>incrementIdx : Symbol(incrementIdx, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS4.ts, 1, 22))
>max : Symbol(max, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS4.ts, 2, 22))
globalCounter += 1;
>globalCounter : Symbol(globalCounter, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS4.ts, 1, 3))
let idx = Math.floor(Math.random() * max);
>idx : Symbol(idx, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS4.ts, 4, 7))
>Math.floor : Symbol(Math.floor, Decl(lib.d.ts, --, --))
>Math : Symbol(Math, Decl(lib.d.ts, --, --), Decl(lib.d.ts, --, --))
>floor : Symbol(Math.floor, Decl(lib.d.ts, --, --))
>Math.random : Symbol(Math.random, Decl(lib.d.ts, --, --))
>Math : Symbol(Math, Decl(lib.d.ts, --, --), Decl(lib.d.ts, --, --))
>random : Symbol(Math.random, Decl(lib.d.ts, --, --))
>max : Symbol(max, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS4.ts, 2, 22))
return idx;
>idx : Symbol(idx, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS4.ts, 4, 7))
}
var array1 = [1, 2, 3, 4, 5];
>array1 : Symbol(array1, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS4.ts, 8, 3))
array1[incrementIdx(array1.length)] **= 3;
>array1 : Symbol(array1, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS4.ts, 8, 3))
>incrementIdx : Symbol(incrementIdx, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS4.ts, 1, 22))
>array1.length : Symbol(Array.length, Decl(lib.d.ts, --, --))
>array1 : Symbol(array1, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS4.ts, 8, 3))
>length : Symbol(Array.length, Decl(lib.d.ts, --, --))
array1[incrementIdx(array1.length)] **= array1[incrementIdx(array1.length)] **= 2;
>array1 : Symbol(array1, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS4.ts, 8, 3))
>incrementIdx : Symbol(incrementIdx, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS4.ts, 1, 22))
>array1.length : Symbol(Array.length, Decl(lib.d.ts, --, --))
>array1 : Symbol(array1, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS4.ts, 8, 3))
>length : Symbol(Array.length, Decl(lib.d.ts, --, --))
>array1 : Symbol(array1, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS4.ts, 8, 3))
>incrementIdx : Symbol(incrementIdx, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS4.ts, 1, 22))
>array1.length : Symbol(Array.length, Decl(lib.d.ts, --, --))
>array1 : Symbol(array1, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS4.ts, 8, 3))
>length : Symbol(Array.length, Decl(lib.d.ts, --, --))
array1[incrementIdx(array1.length)] **= array1[incrementIdx(array1.length)] ** 2;
>array1 : Symbol(array1, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS4.ts, 8, 3))
>incrementIdx : Symbol(incrementIdx, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS4.ts, 1, 22))
>array1.length : Symbol(Array.length, Decl(lib.d.ts, --, --))
>array1 : Symbol(array1, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS4.ts, 8, 3))
>length : Symbol(Array.length, Decl(lib.d.ts, --, --))
>array1 : Symbol(array1, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS4.ts, 8, 3))
>incrementIdx : Symbol(incrementIdx, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS4.ts, 1, 22))
>array1.length : Symbol(Array.length, Decl(lib.d.ts, --, --))
>array1 : Symbol(array1, Decl(emitCompoundExponentiationAssignmentWithIndexingOnLHS4.ts, 8, 3))
>length : Symbol(Array.length, Decl(lib.d.ts, --, --))
@@ -0,0 +1,90 @@
=== tests/cases/conformance/es7/exponentiationOperator/emitCompoundExponentiationAssignmentWithIndexingOnLHS4.ts ===
var globalCounter = 0;
>globalCounter : number
>0 : number
function incrementIdx(max: number) {
>incrementIdx : (max: number) => number
>max : number
globalCounter += 1;
>globalCounter += 1 : number
>globalCounter : number
>1 : number
let idx = Math.floor(Math.random() * max);
>idx : number
>Math.floor(Math.random() * max) : number
>Math.floor : (x: number) => number
>Math : Math
>floor : (x: number) => number
>Math.random() * max : number
>Math.random() : number
>Math.random : () => number
>Math : Math
>random : () => number
>max : number
return idx;
>idx : number
}
var array1 = [1, 2, 3, 4, 5];
>array1 : number[]
>[1, 2, 3, 4, 5] : number[]
>1 : number
>2 : number
>3 : number
>4 : number
>5 : number
array1[incrementIdx(array1.length)] **= 3;
>array1[incrementIdx(array1.length)] **= 3 : number
>array1[incrementIdx(array1.length)] : number
>array1 : number[]
>incrementIdx(array1.length) : number
>incrementIdx : (max: number) => number
>array1.length : number
>array1 : number[]
>length : number
>3 : number
array1[incrementIdx(array1.length)] **= array1[incrementIdx(array1.length)] **= 2;
>array1[incrementIdx(array1.length)] **= array1[incrementIdx(array1.length)] **= 2 : number
>array1[incrementIdx(array1.length)] : number
>array1 : number[]
>incrementIdx(array1.length) : number
>incrementIdx : (max: number) => number
>array1.length : number
>array1 : number[]
>length : number
>array1[incrementIdx(array1.length)] **= 2 : number
>array1[incrementIdx(array1.length)] : number
>array1 : number[]
>incrementIdx(array1.length) : number
>incrementIdx : (max: number) => number
>array1.length : number
>array1 : number[]
>length : number
>2 : number
array1[incrementIdx(array1.length)] **= array1[incrementIdx(array1.length)] ** 2;
>array1[incrementIdx(array1.length)] **= array1[incrementIdx(array1.length)] ** 2 : number
>array1[incrementIdx(array1.length)] : number
>array1 : number[]
>incrementIdx(array1.length) : number
>incrementIdx : (max: number) => number
>array1.length : number
>array1 : number[]
>length : number
>array1[incrementIdx(array1.length)] ** 2 : number
>array1[incrementIdx(array1.length)] : number
>array1 : number[]
>incrementIdx(array1.length) : number
>incrementIdx : (max: number) => number
>array1.length : number
>array1 : number[]
>length : number
>2 : number
@@ -0,0 +1,27 @@
//// [emitCompoundExponentiationAssignmentWithPropertyAccessingOnLHS1.ts]
var globalCounter = 0;
function foo() {
globalCounter += 1;
return { prop: 2 };
}
foo().prop **= 2;
var result0 = foo().prop **= 2;
foo().prop **= foo().prop **= 2;
var result1 = foo().prop **= foo().prop **= 2;
foo().prop **= foo().prop ** 2;
var result2 = foo().prop **= foo().prop ** 2;
//// [emitCompoundExponentiationAssignmentWithPropertyAccessingOnLHS1.js]
var globalCounter = 0;
function foo() {
globalCounter += 1;
return { prop: 2 };
}
(_a = foo(), _a.prop = Math.pow(_a.prop, 2));
var result0 = (_b = foo(), _b.prop = Math.pow(_b.prop, 2));
(_c = foo(), _c.prop = Math.pow(_c.prop, (_d = foo(), _d.prop = Math.pow(_d.prop, 2))));
var result1 = (_e = foo(), _e.prop = Math.pow(_e.prop, (_f = foo(), _f.prop = Math.pow(_f.prop, 2))));
(_g = foo(), _g.prop = Math.pow(_g.prop, Math.pow(foo().prop, 2)));
var result2 = (_h = foo(), _h.prop = Math.pow(_h.prop, Math.pow(foo().prop, 2)));
var _a, _b, _c, _d, _e, _f, _g, _h;
@@ -0,0 +1,59 @@
=== tests/cases/conformance/es7/exponentiationOperator/emitCompoundExponentiationAssignmentWithPropertyAccessingOnLHS1.ts ===
var globalCounter = 0;
>globalCounter : Symbol(globalCounter, Decl(emitCompoundExponentiationAssignmentWithPropertyAccessingOnLHS1.ts, 1, 3))
function foo() {
>foo : Symbol(foo, Decl(emitCompoundExponentiationAssignmentWithPropertyAccessingOnLHS1.ts, 1, 22))
globalCounter += 1;
>globalCounter : Symbol(globalCounter, Decl(emitCompoundExponentiationAssignmentWithPropertyAccessingOnLHS1.ts, 1, 3))
return { prop: 2 };
>prop : Symbol(prop, Decl(emitCompoundExponentiationAssignmentWithPropertyAccessingOnLHS1.ts, 4, 12))
}
foo().prop **= 2;
>foo().prop : Symbol(prop, Decl(emitCompoundExponentiationAssignmentWithPropertyAccessingOnLHS1.ts, 4, 12))
>foo : Symbol(foo, Decl(emitCompoundExponentiationAssignmentWithPropertyAccessingOnLHS1.ts, 1, 22))
>prop : Symbol(prop, Decl(emitCompoundExponentiationAssignmentWithPropertyAccessingOnLHS1.ts, 4, 12))
var result0 = foo().prop **= 2;
>result0 : Symbol(result0, Decl(emitCompoundExponentiationAssignmentWithPropertyAccessingOnLHS1.ts, 7, 3))
>foo().prop : Symbol(prop, Decl(emitCompoundExponentiationAssignmentWithPropertyAccessingOnLHS1.ts, 4, 12))
>foo : Symbol(foo, Decl(emitCompoundExponentiationAssignmentWithPropertyAccessingOnLHS1.ts, 1, 22))
>prop : Symbol(prop, Decl(emitCompoundExponentiationAssignmentWithPropertyAccessingOnLHS1.ts, 4, 12))
foo().prop **= foo().prop **= 2;
>foo().prop : Symbol(prop, Decl(emitCompoundExponentiationAssignmentWithPropertyAccessingOnLHS1.ts, 4, 12))
>foo : Symbol(foo, Decl(emitCompoundExponentiationAssignmentWithPropertyAccessingOnLHS1.ts, 1, 22))
>prop : Symbol(prop, Decl(emitCompoundExponentiationAssignmentWithPropertyAccessingOnLHS1.ts, 4, 12))
>foo().prop : Symbol(prop, Decl(emitCompoundExponentiationAssignmentWithPropertyAccessingOnLHS1.ts, 4, 12))
>foo : Symbol(foo, Decl(emitCompoundExponentiationAssignmentWithPropertyAccessingOnLHS1.ts, 1, 22))
>prop : Symbol(prop, Decl(emitCompoundExponentiationAssignmentWithPropertyAccessingOnLHS1.ts, 4, 12))
var result1 = foo().prop **= foo().prop **= 2;
>result1 : Symbol(result1, Decl(emitCompoundExponentiationAssignmentWithPropertyAccessingOnLHS1.ts, 9, 3))
>foo().prop : Symbol(prop, Decl(emitCompoundExponentiationAssignmentWithPropertyAccessingOnLHS1.ts, 4, 12))
>foo : Symbol(foo, Decl(emitCompoundExponentiationAssignmentWithPropertyAccessingOnLHS1.ts, 1, 22))
>prop : Symbol(prop, Decl(emitCompoundExponentiationAssignmentWithPropertyAccessingOnLHS1.ts, 4, 12))
>foo().prop : Symbol(prop, Decl(emitCompoundExponentiationAssignmentWithPropertyAccessingOnLHS1.ts, 4, 12))
>foo : Symbol(foo, Decl(emitCompoundExponentiationAssignmentWithPropertyAccessingOnLHS1.ts, 1, 22))
>prop : Symbol(prop, Decl(emitCompoundExponentiationAssignmentWithPropertyAccessingOnLHS1.ts, 4, 12))
foo().prop **= foo().prop ** 2;
>foo().prop : Symbol(prop, Decl(emitCompoundExponentiationAssignmentWithPropertyAccessingOnLHS1.ts, 4, 12))
>foo : Symbol(foo, Decl(emitCompoundExponentiationAssignmentWithPropertyAccessingOnLHS1.ts, 1, 22))
>prop : Symbol(prop, Decl(emitCompoundExponentiationAssignmentWithPropertyAccessingOnLHS1.ts, 4, 12))
>foo().prop : Symbol(prop, Decl(emitCompoundExponentiationAssignmentWithPropertyAccessingOnLHS1.ts, 4, 12))
>foo : Symbol(foo, Decl(emitCompoundExponentiationAssignmentWithPropertyAccessingOnLHS1.ts, 1, 22))
>prop : Symbol(prop, Decl(emitCompoundExponentiationAssignmentWithPropertyAccessingOnLHS1.ts, 4, 12))
var result2 = foo().prop **= foo().prop ** 2;
>result2 : Symbol(result2, Decl(emitCompoundExponentiationAssignmentWithPropertyAccessingOnLHS1.ts, 11, 3))
>foo().prop : Symbol(prop, Decl(emitCompoundExponentiationAssignmentWithPropertyAccessingOnLHS1.ts, 4, 12))
>foo : Symbol(foo, Decl(emitCompoundExponentiationAssignmentWithPropertyAccessingOnLHS1.ts, 1, 22))
>prop : Symbol(prop, Decl(emitCompoundExponentiationAssignmentWithPropertyAccessingOnLHS1.ts, 4, 12))
>foo().prop : Symbol(prop, Decl(emitCompoundExponentiationAssignmentWithPropertyAccessingOnLHS1.ts, 4, 12))
>foo : Symbol(foo, Decl(emitCompoundExponentiationAssignmentWithPropertyAccessingOnLHS1.ts, 1, 22))
>prop : Symbol(prop, Decl(emitCompoundExponentiationAssignmentWithPropertyAccessingOnLHS1.ts, 4, 12))
@@ -0,0 +1,90 @@
=== tests/cases/conformance/es7/exponentiationOperator/emitCompoundExponentiationAssignmentWithPropertyAccessingOnLHS1.ts ===
var globalCounter = 0;
>globalCounter : number
>0 : number
function foo() {
>foo : () => { prop: number; }
globalCounter += 1;
>globalCounter += 1 : number
>globalCounter : number
>1 : number
return { prop: 2 };
>{ prop: 2 } : { prop: number; }
>prop : number
>2 : number
}
foo().prop **= 2;
>foo().prop **= 2 : number
>foo().prop : number
>foo() : { prop: number; }
>foo : () => { prop: number; }
>prop : number
>2 : number
var result0 = foo().prop **= 2;
>result0 : number
>foo().prop **= 2 : number
>foo().prop : number
>foo() : { prop: number; }
>foo : () => { prop: number; }
>prop : number
>2 : number
foo().prop **= foo().prop **= 2;
>foo().prop **= foo().prop **= 2 : number
>foo().prop : number
>foo() : { prop: number; }
>foo : () => { prop: number; }
>prop : number
>foo().prop **= 2 : number
>foo().prop : number
>foo() : { prop: number; }
>foo : () => { prop: number; }
>prop : number
>2 : number
var result1 = foo().prop **= foo().prop **= 2;
>result1 : number
>foo().prop **= foo().prop **= 2 : number
>foo().prop : number
>foo() : { prop: number; }
>foo : () => { prop: number; }
>prop : number
>foo().prop **= 2 : number
>foo().prop : number
>foo() : { prop: number; }
>foo : () => { prop: number; }
>prop : number
>2 : number
foo().prop **= foo().prop ** 2;
>foo().prop **= foo().prop ** 2 : number
>foo().prop : number
>foo() : { prop: number; }
>foo : () => { prop: number; }
>prop : number
>foo().prop ** 2 : number
>foo().prop : number
>foo() : { prop: number; }
>foo : () => { prop: number; }
>prop : number
>2 : number
var result2 = foo().prop **= foo().prop ** 2;
>result2 : number
>foo().prop **= foo().prop ** 2 : number
>foo().prop : number
>foo() : { prop: number; }
>foo : () => { prop: number; }
>prop : number
>foo().prop ** 2 : number
>foo().prop : number
>foo() : { prop: number; }
>foo : () => { prop: number; }
>prop : number
>2 : number
@@ -0,0 +1,43 @@
//// [emitCompoundExponentiationOperator1.ts]
var comp: number;
comp **= 1;
comp **= comp ** comp;
comp **= comp ** comp ** 2;
comp **= comp ** comp + 2;
comp **= comp ** comp - 2;
comp **= comp ** comp * 2;
comp **= comp ** comp / 2;
comp **= comp ** comp % 2;
comp **= (comp - 2) ** 5;
comp **= (comp + 2) ** 5;
comp **= (comp * 2) ** 5;
comp **= (comp / 2) ** 5;
comp **= (comp % 2) ** 5;
comp **= comp ** (5 + 2);
comp **= comp ** (5 - 2);
comp **= comp ** (5 * 2);
comp **= comp ** (5 / 2);
comp **= comp ** (5 % 2);
//// [emitCompoundExponentiationOperator1.js]
var comp;
comp = Math.pow(comp, 1);
comp = Math.pow(comp, Math.pow(comp, comp));
comp = Math.pow(comp, Math.pow(comp, Math.pow(comp, 2)));
comp = Math.pow(comp, Math.pow(comp, comp) + 2);
comp = Math.pow(comp, Math.pow(comp, comp) - 2);
comp = Math.pow(comp, Math.pow(comp, comp) * 2);
comp = Math.pow(comp, Math.pow(comp, comp) / 2);
comp = Math.pow(comp, Math.pow(comp, comp) % 2);
comp = Math.pow(comp, Math.pow((comp - 2), 5));
comp = Math.pow(comp, Math.pow((comp + 2), 5));
comp = Math.pow(comp, Math.pow((comp * 2), 5));
comp = Math.pow(comp, Math.pow((comp / 2), 5));
comp = Math.pow(comp, Math.pow((comp % 2), 5));
comp = Math.pow(comp, Math.pow(comp, (5 + 2)));
comp = Math.pow(comp, Math.pow(comp, (5 - 2)));
comp = Math.pow(comp, Math.pow(comp, (5 * 2)));
comp = Math.pow(comp, Math.pow(comp, (5 / 2)));
comp = Math.pow(comp, Math.pow(comp, (5 % 2)));
@@ -0,0 +1,83 @@
=== tests/cases/conformance/es7/exponentiationOperator/emitCompoundExponentiationOperator1.ts ===
var comp: number;
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator1.ts, 1, 3))
comp **= 1;
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator1.ts, 1, 3))
comp **= comp ** comp;
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator1.ts, 1, 3))
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator1.ts, 1, 3))
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator1.ts, 1, 3))
comp **= comp ** comp ** 2;
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator1.ts, 1, 3))
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator1.ts, 1, 3))
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator1.ts, 1, 3))
comp **= comp ** comp + 2;
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator1.ts, 1, 3))
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator1.ts, 1, 3))
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator1.ts, 1, 3))
comp **= comp ** comp - 2;
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator1.ts, 1, 3))
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator1.ts, 1, 3))
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator1.ts, 1, 3))
comp **= comp ** comp * 2;
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator1.ts, 1, 3))
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator1.ts, 1, 3))
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator1.ts, 1, 3))
comp **= comp ** comp / 2;
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator1.ts, 1, 3))
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator1.ts, 1, 3))
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator1.ts, 1, 3))
comp **= comp ** comp % 2;
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator1.ts, 1, 3))
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator1.ts, 1, 3))
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator1.ts, 1, 3))
comp **= (comp - 2) ** 5;
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator1.ts, 1, 3))
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator1.ts, 1, 3))
comp **= (comp + 2) ** 5;
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator1.ts, 1, 3))
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator1.ts, 1, 3))
comp **= (comp * 2) ** 5;
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator1.ts, 1, 3))
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator1.ts, 1, 3))
comp **= (comp / 2) ** 5;
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator1.ts, 1, 3))
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator1.ts, 1, 3))
comp **= (comp % 2) ** 5;
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator1.ts, 1, 3))
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator1.ts, 1, 3))
comp **= comp ** (5 + 2);
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator1.ts, 1, 3))
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator1.ts, 1, 3))
comp **= comp ** (5 - 2);
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator1.ts, 1, 3))
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator1.ts, 1, 3))
comp **= comp ** (5 * 2);
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator1.ts, 1, 3))
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator1.ts, 1, 3))
comp **= comp ** (5 / 2);
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator1.ts, 1, 3))
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator1.ts, 1, 3))
comp **= comp ** (5 % 2);
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator1.ts, 1, 3))
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator1.ts, 1, 3))
@@ -0,0 +1,171 @@
=== tests/cases/conformance/es7/exponentiationOperator/emitCompoundExponentiationOperator1.ts ===
var comp: number;
>comp : number
comp **= 1;
>comp **= 1 : number
>comp : number
>1 : number
comp **= comp ** comp;
>comp **= comp ** comp : number
>comp : number
>comp ** comp : number
>comp : number
>comp : number
comp **= comp ** comp ** 2;
>comp **= comp ** comp ** 2 : number
>comp : number
>comp ** comp ** 2 : number
>comp : number
>comp ** 2 : number
>comp : number
>2 : number
comp **= comp ** comp + 2;
>comp **= comp ** comp + 2 : number
>comp : number
>comp ** comp + 2 : number
>comp ** comp : number
>comp : number
>comp : number
>2 : number
comp **= comp ** comp - 2;
>comp **= comp ** comp - 2 : number
>comp : number
>comp ** comp - 2 : number
>comp ** comp : number
>comp : number
>comp : number
>2 : number
comp **= comp ** comp * 2;
>comp **= comp ** comp * 2 : number
>comp : number
>comp ** comp * 2 : number
>comp ** comp : number
>comp : number
>comp : number
>2 : number
comp **= comp ** comp / 2;
>comp **= comp ** comp / 2 : number
>comp : number
>comp ** comp / 2 : number
>comp ** comp : number
>comp : number
>comp : number
>2 : number
comp **= comp ** comp % 2;
>comp **= comp ** comp % 2 : number
>comp : number
>comp ** comp % 2 : number
>comp ** comp : number
>comp : number
>comp : number
>2 : number
comp **= (comp - 2) ** 5;
>comp **= (comp - 2) ** 5 : number
>comp : number
>(comp - 2) ** 5 : number
>(comp - 2) : number
>comp - 2 : number
>comp : number
>2 : number
>5 : number
comp **= (comp + 2) ** 5;
>comp **= (comp + 2) ** 5 : number
>comp : number
>(comp + 2) ** 5 : number
>(comp + 2) : number
>comp + 2 : number
>comp : number
>2 : number
>5 : number
comp **= (comp * 2) ** 5;
>comp **= (comp * 2) ** 5 : number
>comp : number
>(comp * 2) ** 5 : number
>(comp * 2) : number
>comp * 2 : number
>comp : number
>2 : number
>5 : number
comp **= (comp / 2) ** 5;
>comp **= (comp / 2) ** 5 : number
>comp : number
>(comp / 2) ** 5 : number
>(comp / 2) : number
>comp / 2 : number
>comp : number
>2 : number
>5 : number
comp **= (comp % 2) ** 5;
>comp **= (comp % 2) ** 5 : number
>comp : number
>(comp % 2) ** 5 : number
>(comp % 2) : number
>comp % 2 : number
>comp : number
>2 : number
>5 : number
comp **= comp ** (5 + 2);
>comp **= comp ** (5 + 2) : number
>comp : number
>comp ** (5 + 2) : number
>comp : number
>(5 + 2) : number
>5 + 2 : number
>5 : number
>2 : number
comp **= comp ** (5 - 2);
>comp **= comp ** (5 - 2) : number
>comp : number
>comp ** (5 - 2) : number
>comp : number
>(5 - 2) : number
>5 - 2 : number
>5 : number
>2 : number
comp **= comp ** (5 * 2);
>comp **= comp ** (5 * 2) : number
>comp : number
>comp ** (5 * 2) : number
>comp : number
>(5 * 2) : number
>5 * 2 : number
>5 : number
>2 : number
comp **= comp ** (5 / 2);
>comp **= comp ** (5 / 2) : number
>comp : number
>comp ** (5 / 2) : number
>comp : number
>(5 / 2) : number
>5 / 2 : number
>5 : number
>2 : number
comp **= comp ** (5 % 2);
>comp **= comp ** (5 % 2) : number
>comp : number
>comp ** (5 % 2) : number
>comp : number
>(5 % 2) : number
>5 % 2 : number
>5 : number
>2 : number
@@ -0,0 +1,47 @@
//// [emitCompoundExponentiationOperator2.ts]
var comp: number;
comp **= 1;
comp **= comp **= 1;
comp **= comp **= 1 + 2;
comp **= comp **= 1 - 2;
comp **= comp **= 1 * 2;
comp **= comp **= 1 / 2;
comp **= comp **= (1 + 2);
comp **= comp **= (1 - 2);
comp **= comp **= (1 * 2);
comp **= comp **= (1 / 2);
comp **= comp **= 1 + 2 ** 3;
comp **= comp **= 1 - 2 ** 4;
comp **= comp **= 1 * 2 ** 5;
comp **= comp **= 1 / 2 ** 6;
comp **= comp **= (1 + 2) ** 3;
comp **= comp **= (1 - 2) ** 4;
comp **= comp **= (1 * 2) ** 5;
comp **= comp **= (1 / 2) ** 6;
//// [emitCompoundExponentiationOperator2.js]
var comp;
comp = Math.pow(comp, 1);
comp = Math.pow(comp, comp = Math.pow(comp, 1));
comp = Math.pow(comp, comp = Math.pow(comp, 1 + 2));
comp = Math.pow(comp, comp = Math.pow(comp, 1 - 2));
comp = Math.pow(comp, comp = Math.pow(comp, 1 * 2));
comp = Math.pow(comp, comp = Math.pow(comp, 1 / 2));
comp = Math.pow(comp, comp = Math.pow(comp, (1 + 2)));
comp = Math.pow(comp, comp = Math.pow(comp, (1 - 2)));
comp = Math.pow(comp, comp = Math.pow(comp, (1 * 2)));
comp = Math.pow(comp, comp = Math.pow(comp, (1 / 2)));
comp = Math.pow(comp, comp = Math.pow(comp, 1 + Math.pow(2, 3)));
comp = Math.pow(comp, comp = Math.pow(comp, 1 - Math.pow(2, 4)));
comp = Math.pow(comp, comp = Math.pow(comp, 1 * Math.pow(2, 5)));
comp = Math.pow(comp, comp = Math.pow(comp, 1 / Math.pow(2, 6)));
comp = Math.pow(comp, comp = Math.pow(comp, Math.pow((1 + 2), 3)));
comp = Math.pow(comp, comp = Math.pow(comp, Math.pow((1 - 2), 4)));
comp = Math.pow(comp, comp = Math.pow(comp, Math.pow((1 * 2), 5)));
comp = Math.pow(comp, comp = Math.pow(comp, Math.pow((1 / 2), 6)));
@@ -0,0 +1,76 @@
=== tests/cases/conformance/es7/exponentiationOperator/emitCompoundExponentiationOperator2.ts ===
var comp: number;
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator2.ts, 1, 3))
comp **= 1;
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator2.ts, 1, 3))
comp **= comp **= 1;
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator2.ts, 1, 3))
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator2.ts, 1, 3))
comp **= comp **= 1 + 2;
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator2.ts, 1, 3))
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator2.ts, 1, 3))
comp **= comp **= 1 - 2;
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator2.ts, 1, 3))
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator2.ts, 1, 3))
comp **= comp **= 1 * 2;
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator2.ts, 1, 3))
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator2.ts, 1, 3))
comp **= comp **= 1 / 2;
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator2.ts, 1, 3))
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator2.ts, 1, 3))
comp **= comp **= (1 + 2);
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator2.ts, 1, 3))
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator2.ts, 1, 3))
comp **= comp **= (1 - 2);
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator2.ts, 1, 3))
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator2.ts, 1, 3))
comp **= comp **= (1 * 2);
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator2.ts, 1, 3))
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator2.ts, 1, 3))
comp **= comp **= (1 / 2);
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator2.ts, 1, 3))
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator2.ts, 1, 3))
comp **= comp **= 1 + 2 ** 3;
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator2.ts, 1, 3))
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator2.ts, 1, 3))
comp **= comp **= 1 - 2 ** 4;
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator2.ts, 1, 3))
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator2.ts, 1, 3))
comp **= comp **= 1 * 2 ** 5;
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator2.ts, 1, 3))
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator2.ts, 1, 3))
comp **= comp **= 1 / 2 ** 6;
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator2.ts, 1, 3))
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator2.ts, 1, 3))
comp **= comp **= (1 + 2) ** 3;
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator2.ts, 1, 3))
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator2.ts, 1, 3))
comp **= comp **= (1 - 2) ** 4;
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator2.ts, 1, 3))
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator2.ts, 1, 3))
comp **= comp **= (1 * 2) ** 5;
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator2.ts, 1, 3))
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator2.ts, 1, 3))
comp **= comp **= (1 / 2) ** 6;
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator2.ts, 1, 3))
>comp : Symbol(comp, Decl(emitCompoundExponentiationOperator2.ts, 1, 3))
@@ -0,0 +1,185 @@
=== tests/cases/conformance/es7/exponentiationOperator/emitCompoundExponentiationOperator2.ts ===
var comp: number;
>comp : number
comp **= 1;
>comp **= 1 : number
>comp : number
>1 : number
comp **= comp **= 1;
>comp **= comp **= 1 : number
>comp : number
>comp **= 1 : number
>comp : number
>1 : number
comp **= comp **= 1 + 2;
>comp **= comp **= 1 + 2 : number
>comp : number
>comp **= 1 + 2 : number
>comp : number
>1 + 2 : number
>1 : number
>2 : number
comp **= comp **= 1 - 2;
>comp **= comp **= 1 - 2 : number
>comp : number
>comp **= 1 - 2 : number
>comp : number
>1 - 2 : number
>1 : number
>2 : number
comp **= comp **= 1 * 2;
>comp **= comp **= 1 * 2 : number
>comp : number
>comp **= 1 * 2 : number
>comp : number
>1 * 2 : number
>1 : number
>2 : number
comp **= comp **= 1 / 2;
>comp **= comp **= 1 / 2 : number
>comp : number
>comp **= 1 / 2 : number
>comp : number
>1 / 2 : number
>1 : number
>2 : number
comp **= comp **= (1 + 2);
>comp **= comp **= (1 + 2) : number
>comp : number
>comp **= (1 + 2) : number
>comp : number
>(1 + 2) : number
>1 + 2 : number
>1 : number
>2 : number
comp **= comp **= (1 - 2);
>comp **= comp **= (1 - 2) : number
>comp : number
>comp **= (1 - 2) : number
>comp : number
>(1 - 2) : number
>1 - 2 : number
>1 : number
>2 : number
comp **= comp **= (1 * 2);
>comp **= comp **= (1 * 2) : number
>comp : number
>comp **= (1 * 2) : number
>comp : number
>(1 * 2) : number
>1 * 2 : number
>1 : number
>2 : number
comp **= comp **= (1 / 2);
>comp **= comp **= (1 / 2) : number
>comp : number
>comp **= (1 / 2) : number
>comp : number
>(1 / 2) : number
>1 / 2 : number
>1 : number
>2 : number
comp **= comp **= 1 + 2 ** 3;
>comp **= comp **= 1 + 2 ** 3 : number
>comp : number
>comp **= 1 + 2 ** 3 : number
>comp : number
>1 + 2 ** 3 : number
>1 : number
>2 ** 3 : number
>2 : number
>3 : number
comp **= comp **= 1 - 2 ** 4;
>comp **= comp **= 1 - 2 ** 4 : number
>comp : number
>comp **= 1 - 2 ** 4 : number
>comp : number
>1 - 2 ** 4 : number
>1 : number
>2 ** 4 : number
>2 : number
>4 : number
comp **= comp **= 1 * 2 ** 5;
>comp **= comp **= 1 * 2 ** 5 : number
>comp : number
>comp **= 1 * 2 ** 5 : number
>comp : number
>1 * 2 ** 5 : number
>1 : number
>2 ** 5 : number
>2 : number
>5 : number
comp **= comp **= 1 / 2 ** 6;
>comp **= comp **= 1 / 2 ** 6 : number
>comp : number
>comp **= 1 / 2 ** 6 : number
>comp : number
>1 / 2 ** 6 : number
>1 : number
>2 ** 6 : number
>2 : number
>6 : number
comp **= comp **= (1 + 2) ** 3;
>comp **= comp **= (1 + 2) ** 3 : number
>comp : number
>comp **= (1 + 2) ** 3 : number
>comp : number
>(1 + 2) ** 3 : number
>(1 + 2) : number
>1 + 2 : number
>1 : number
>2 : number
>3 : number
comp **= comp **= (1 - 2) ** 4;
>comp **= comp **= (1 - 2) ** 4 : number
>comp : number
>comp **= (1 - 2) ** 4 : number
>comp : number
>(1 - 2) ** 4 : number
>(1 - 2) : number
>1 - 2 : number
>1 : number
>2 : number
>4 : number
comp **= comp **= (1 * 2) ** 5;
>comp **= comp **= (1 * 2) ** 5 : number
>comp : number
>comp **= (1 * 2) ** 5 : number
>comp : number
>(1 * 2) ** 5 : number
>(1 * 2) : number
>1 * 2 : number
>1 : number
>2 : number
>5 : number
comp **= comp **= (1 / 2) ** 6;
>comp **= comp **= (1 / 2) ** 6 : number
>comp : number
>comp **= (1 / 2) ** 6 : number
>comp : number
>(1 / 2) ** 6 : number
>(1 / 2) : number
>1 / 2 : number
>1 : number
>2 : number
>6 : number
@@ -0,0 +1,62 @@
//// [emitExponentiationOperator1.ts]
1 ** -2;
1 ** 2;
(-1) ** 2
1 ** 2 ** 3;
1 ** 2 ** -3;
1 ** -(2 ** 3);
(-(1 ** 2)) ** 3;
(-(1 ** 2)) ** -3;
1 ** 2 + 3;
1 ** 2 - 3;
1 ** 2 * 3;
1 ** 2 / 3;
1 ** 2 % 3;
1 ** -2 + 3;
1 ** -2 - 3;
1 ** -2 * 3;
1 ** -2 / 3;
1 ** -2 % 3;
2 + 3 ** 3;
2 - 3 ** 3;
2 * 3 ** 3;
2 / 3 ** 3;
2 % 3 ** 3;
(2 + 3) ** 4;
(2 - 3) ** 4;
(2 * 3) ** 4;
(2 / 3) ** 4;
//// [emitExponentiationOperator1.js]
Math.pow(1, -2);
Math.pow(1, 2);
Math.pow((-1), 2);
Math.pow(1, Math.pow(2, 3));
Math.pow(1, Math.pow(2, -3));
Math.pow(1, -(Math.pow(2, 3)));
Math.pow((-(Math.pow(1, 2))), 3);
Math.pow((-(Math.pow(1, 2))), -3);
Math.pow(1, 2) + 3;
Math.pow(1, 2) - 3;
Math.pow(1, 2) * 3;
Math.pow(1, 2) / 3;
Math.pow(1, 2) % 3;
Math.pow(1, -2) + 3;
Math.pow(1, -2) - 3;
Math.pow(1, -2) * 3;
Math.pow(1, -2) / 3;
Math.pow(1, -2) % 3;
2 + Math.pow(3, 3);
2 - Math.pow(3, 3);
2 * Math.pow(3, 3);
2 / Math.pow(3, 3);
2 % Math.pow(3, 3);
Math.pow((2 + 3), 4);
Math.pow((2 - 3), 4);
Math.pow((2 * 3), 4);
Math.pow((2 / 3), 4);
@@ -0,0 +1,34 @@
=== tests/cases/conformance/es7/exponentiationOperator/emitExponentiationOperator1.ts ===
No type information for this code.1 ** -2;
No type information for this code.1 ** 2;
No type information for this code.(-1) ** 2
No type information for this code.1 ** 2 ** 3;
No type information for this code.1 ** 2 ** -3;
No type information for this code.1 ** -(2 ** 3);
No type information for this code.(-(1 ** 2)) ** 3;
No type information for this code.(-(1 ** 2)) ** -3;
No type information for this code.
No type information for this code.1 ** 2 + 3;
No type information for this code.1 ** 2 - 3;
No type information for this code.1 ** 2 * 3;
No type information for this code.1 ** 2 / 3;
No type information for this code.1 ** 2 % 3;
No type information for this code.
No type information for this code.1 ** -2 + 3;
No type information for this code.1 ** -2 - 3;
No type information for this code.1 ** -2 * 3;
No type information for this code.1 ** -2 / 3;
No type information for this code.1 ** -2 % 3;
No type information for this code.
No type information for this code.2 + 3 ** 3;
No type information for this code.2 - 3 ** 3;
No type information for this code.2 * 3 ** 3;
No type information for this code.2 / 3 ** 3;
No type information for this code.2 % 3 ** 3;
No type information for this code.
No type information for this code.(2 + 3) ** 4;
No type information for this code.(2 - 3) ** 4;
No type information for this code.(2 * 3) ** 4;
No type information for this code.(2 / 3) ** 4;
No type information for this code.
@@ -0,0 +1,207 @@
=== tests/cases/conformance/es7/exponentiationOperator/emitExponentiationOperator1.ts ===
1 ** -2;
>1 ** -2 : number
>1 : number
>-2 : number
>2 : number
1 ** 2;
>1 ** 2 : number
>1 : number
>2 : number
(-1) ** 2
>(-1) ** 2 : number
>(-1) : number
>-1 : number
>1 : number
>2 : number
1 ** 2 ** 3;
>1 ** 2 ** 3 : number
>1 : number
>2 ** 3 : number
>2 : number
>3 : number
1 ** 2 ** -3;
>1 ** 2 ** -3 : number
>1 : number
>2 ** -3 : number
>2 : number
>-3 : number
>3 : number
1 ** -(2 ** 3);
>1 ** -(2 ** 3) : number
>1 : number
>-(2 ** 3) : number
>(2 ** 3) : number
>2 ** 3 : number
>2 : number
>3 : number
(-(1 ** 2)) ** 3;
>(-(1 ** 2)) ** 3 : number
>(-(1 ** 2)) : number
>-(1 ** 2) : number
>(1 ** 2) : number
>1 ** 2 : number
>1 : number
>2 : number
>3 : number
(-(1 ** 2)) ** -3;
>(-(1 ** 2)) ** -3 : number
>(-(1 ** 2)) : number
>-(1 ** 2) : number
>(1 ** 2) : number
>1 ** 2 : number
>1 : number
>2 : number
>-3 : number
>3 : number
1 ** 2 + 3;
>1 ** 2 + 3 : number
>1 ** 2 : number
>1 : number
>2 : number
>3 : number
1 ** 2 - 3;
>1 ** 2 - 3 : number
>1 ** 2 : number
>1 : number
>2 : number
>3 : number
1 ** 2 * 3;
>1 ** 2 * 3 : number
>1 ** 2 : number
>1 : number
>2 : number
>3 : number
1 ** 2 / 3;
>1 ** 2 / 3 : number
>1 ** 2 : number
>1 : number
>2 : number
>3 : number
1 ** 2 % 3;
>1 ** 2 % 3 : number
>1 ** 2 : number
>1 : number
>2 : number
>3 : number
1 ** -2 + 3;
>1 ** -2 + 3 : number
>1 ** -2 : number
>1 : number
>-2 : number
>2 : number
>3 : number
1 ** -2 - 3;
>1 ** -2 - 3 : number
>1 ** -2 : number
>1 : number
>-2 : number
>2 : number
>3 : number
1 ** -2 * 3;
>1 ** -2 * 3 : number
>1 ** -2 : number
>1 : number
>-2 : number
>2 : number
>3 : number
1 ** -2 / 3;
>1 ** -2 / 3 : number
>1 ** -2 : number
>1 : number
>-2 : number
>2 : number
>3 : number
1 ** -2 % 3;
>1 ** -2 % 3 : number
>1 ** -2 : number
>1 : number
>-2 : number
>2 : number
>3 : number
2 + 3 ** 3;
>2 + 3 ** 3 : number
>2 : number
>3 ** 3 : number
>3 : number
>3 : number
2 - 3 ** 3;
>2 - 3 ** 3 : number
>2 : number
>3 ** 3 : number
>3 : number
>3 : number
2 * 3 ** 3;
>2 * 3 ** 3 : number
>2 : number
>3 ** 3 : number
>3 : number
>3 : number
2 / 3 ** 3;
>2 / 3 ** 3 : number
>2 : number
>3 ** 3 : number
>3 : number
>3 : number
2 % 3 ** 3;
>2 % 3 ** 3 : number
>2 : number
>3 ** 3 : number
>3 : number
>3 : number
(2 + 3) ** 4;
>(2 + 3) ** 4 : number
>(2 + 3) : number
>2 + 3 : number
>2 : number
>3 : number
>4 : number
(2 - 3) ** 4;
>(2 - 3) ** 4 : number
>(2 - 3) : number
>2 - 3 : number
>2 : number
>3 : number
>4 : number
(2 * 3) ** 4;
>(2 * 3) ** 4 : number
>(2 * 3) : number
>2 * 3 : number
>2 : number
>3 : number
>4 : number
(2 / 3) ** 4;
>(2 / 3) ** 4 : number
>(2 / 3) : number
>2 / 3 : number
>2 : number
>3 : number
>4 : number
@@ -0,0 +1,104 @@
//// [emitExponentiationOperator2.ts]
var temp = 10;
++temp ** 3;
--temp ** 3;
temp++ ** 3;
temp-- ** 3;
--temp + temp ** 3;
--temp - temp ** 3;
--temp * temp ** 3;
--temp / temp ** 3;
--temp % temp ** 3;
temp-- ** 3;
temp++ ** 3;
temp-- ** -temp;
temp++ ** +temp;
temp-- + temp ** 3;
temp-- - temp ** 3;
temp-- * temp ** 3;
temp-- / temp ** 3;
temp-- % temp ** 3;
--temp + 2 ** 3;
--temp - 2 ** 3;
--temp * 2 ** 3;
--temp / 2 ** 3;
--temp % 2 ** 3;
++temp + 2 ** 3;
++temp - 2 ** 3;
++temp * 2 ** 3;
++temp / 2 ** 3;
3 ** ++temp;
3 ** --temp;
3 ** temp++;
3 ** temp--;
3 ** ++temp ** 2;
3 ** --temp ** 2;
3 ** temp++ ** 2;
3 ** temp-- ** 2;
3 ** ++temp + 2;
3 ** ++temp - 2;
3 ** ++temp * 2;
3 ** ++temp / 2;
3 ** ++temp % 2;
3 ** --temp + 2;
3 ** --temp - 2;
3 ** --temp * 2;
3 ** --temp / 2;
3 ** --temp % 2;
//// [emitExponentiationOperator2.js]
var temp = 10;
Math.pow(++temp, 3);
Math.pow(--temp, 3);
Math.pow(temp++, 3);
Math.pow(temp--, 3);
--temp + Math.pow(temp, 3);
--temp - Math.pow(temp, 3);
--temp * Math.pow(temp, 3);
--temp / Math.pow(temp, 3);
--temp % Math.pow(temp, 3);
Math.pow(temp--, 3);
Math.pow(temp++, 3);
Math.pow(temp--, -temp);
Math.pow(temp++, +temp);
temp-- + Math.pow(temp, 3);
temp-- - Math.pow(temp, 3);
temp-- * Math.pow(temp, 3);
temp-- / Math.pow(temp, 3);
temp-- % Math.pow(temp, 3);
--temp + Math.pow(2, 3);
--temp - Math.pow(2, 3);
--temp * Math.pow(2, 3);
--temp / Math.pow(2, 3);
--temp % Math.pow(2, 3);
++temp + Math.pow(2, 3);
++temp - Math.pow(2, 3);
++temp * Math.pow(2, 3);
++temp / Math.pow(2, 3);
Math.pow(3, ++temp);
Math.pow(3, --temp);
Math.pow(3, temp++);
Math.pow(3, temp--);
Math.pow(3, Math.pow(++temp, 2));
Math.pow(3, Math.pow(--temp, 2));
Math.pow(3, Math.pow(temp++, 2));
Math.pow(3, Math.pow(temp--, 2));
Math.pow(3, ++temp) + 2;
Math.pow(3, ++temp) - 2;
Math.pow(3, ++temp) * 2;
Math.pow(3, ++temp) / 2;
Math.pow(3, ++temp) % 2;
Math.pow(3, --temp) + 2;
Math.pow(3, --temp) - 2;
Math.pow(3, --temp) * 2;
Math.pow(3, --temp) / 2;
Math.pow(3, --temp) % 2;
@@ -0,0 +1,152 @@
=== tests/cases/conformance/es7/exponentiationOperator/emitExponentiationOperator2.ts ===
var temp = 10;
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
++temp ** 3;
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
--temp ** 3;
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
temp++ ** 3;
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
temp-- ** 3;
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
--temp + temp ** 3;
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
--temp - temp ** 3;
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
--temp * temp ** 3;
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
--temp / temp ** 3;
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
--temp % temp ** 3;
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
temp-- ** 3;
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
temp++ ** 3;
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
temp-- ** -temp;
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
temp++ ** +temp;
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
temp-- + temp ** 3;
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
temp-- - temp ** 3;
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
temp-- * temp ** 3;
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
temp-- / temp ** 3;
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
temp-- % temp ** 3;
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
--temp + 2 ** 3;
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
--temp - 2 ** 3;
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
--temp * 2 ** 3;
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
--temp / 2 ** 3;
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
--temp % 2 ** 3;
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
++temp + 2 ** 3;
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
++temp - 2 ** 3;
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
++temp * 2 ** 3;
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
++temp / 2 ** 3;
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
3 ** ++temp;
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
3 ** --temp;
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
3 ** temp++;
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
3 ** temp--;
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
3 ** ++temp ** 2;
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
3 ** --temp ** 2;
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
3 ** temp++ ** 2;
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
3 ** temp-- ** 2;
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
3 ** ++temp + 2;
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
3 ** ++temp - 2;
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
3 ** ++temp * 2;
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
3 ** ++temp / 2;
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
3 ** ++temp % 2;
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
3 ** --temp + 2;
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
3 ** --temp - 2;
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
3 ** --temp * 2;
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
3 ** --temp / 2;
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
3 ** --temp % 2;
>temp : Symbol(temp, Decl(emitExponentiationOperator2.ts, 1, 3))
@@ -0,0 +1,344 @@
=== tests/cases/conformance/es7/exponentiationOperator/emitExponentiationOperator2.ts ===
var temp = 10;
>temp : number
>10 : number
++temp ** 3;
>++temp ** 3 : number
>++temp : number
>temp : number
>3 : number
--temp ** 3;
>--temp ** 3 : number
>--temp : number
>temp : number
>3 : number
temp++ ** 3;
>temp++ ** 3 : number
>temp++ : number
>temp : number
>3 : number
temp-- ** 3;
>temp-- ** 3 : number
>temp-- : number
>temp : number
>3 : number
--temp + temp ** 3;
>--temp + temp ** 3 : number
>--temp : number
>temp : number
>temp ** 3 : number
>temp : number
>3 : number
--temp - temp ** 3;
>--temp - temp ** 3 : number
>--temp : number
>temp : number
>temp ** 3 : number
>temp : number
>3 : number
--temp * temp ** 3;
>--temp * temp ** 3 : number
>--temp : number
>temp : number
>temp ** 3 : number
>temp : number
>3 : number
--temp / temp ** 3;
>--temp / temp ** 3 : number
>--temp : number
>temp : number
>temp ** 3 : number
>temp : number
>3 : number
--temp % temp ** 3;
>--temp % temp ** 3 : number
>--temp : number
>temp : number
>temp ** 3 : number
>temp : number
>3 : number
temp-- ** 3;
>temp-- ** 3 : number
>temp-- : number
>temp : number
>3 : number
temp++ ** 3;
>temp++ ** 3 : number
>temp++ : number
>temp : number
>3 : number
temp-- ** -temp;
>temp-- ** -temp : number
>temp-- : number
>temp : number
>-temp : number
>temp : number
temp++ ** +temp;
>temp++ ** +temp : number
>temp++ : number
>temp : number
>+temp : number
>temp : number
temp-- + temp ** 3;
>temp-- + temp ** 3 : number
>temp-- : number
>temp : number
>temp ** 3 : number
>temp : number
>3 : number
temp-- - temp ** 3;
>temp-- - temp ** 3 : number
>temp-- : number
>temp : number
>temp ** 3 : number
>temp : number
>3 : number
temp-- * temp ** 3;
>temp-- * temp ** 3 : number
>temp-- : number
>temp : number
>temp ** 3 : number
>temp : number
>3 : number
temp-- / temp ** 3;
>temp-- / temp ** 3 : number
>temp-- : number
>temp : number
>temp ** 3 : number
>temp : number
>3 : number
temp-- % temp ** 3;
>temp-- % temp ** 3 : number
>temp-- : number
>temp : number
>temp ** 3 : number
>temp : number
>3 : number
--temp + 2 ** 3;
>--temp + 2 ** 3 : number
>--temp : number
>temp : number
>2 ** 3 : number
>2 : number
>3 : number
--temp - 2 ** 3;
>--temp - 2 ** 3 : number
>--temp : number
>temp : number
>2 ** 3 : number
>2 : number
>3 : number
--temp * 2 ** 3;
>--temp * 2 ** 3 : number
>--temp : number
>temp : number
>2 ** 3 : number
>2 : number
>3 : number
--temp / 2 ** 3;
>--temp / 2 ** 3 : number
>--temp : number
>temp : number
>2 ** 3 : number
>2 : number
>3 : number
--temp % 2 ** 3;
>--temp % 2 ** 3 : number
>--temp : number
>temp : number
>2 ** 3 : number
>2 : number
>3 : number
++temp + 2 ** 3;
>++temp + 2 ** 3 : number
>++temp : number
>temp : number
>2 ** 3 : number
>2 : number
>3 : number
++temp - 2 ** 3;
>++temp - 2 ** 3 : number
>++temp : number
>temp : number
>2 ** 3 : number
>2 : number
>3 : number
++temp * 2 ** 3;
>++temp * 2 ** 3 : number
>++temp : number
>temp : number
>2 ** 3 : number
>2 : number
>3 : number
++temp / 2 ** 3;
>++temp / 2 ** 3 : number
>++temp : number
>temp : number
>2 ** 3 : number
>2 : number
>3 : number
3 ** ++temp;
>3 ** ++temp : number
>3 : number
>++temp : number
>temp : number
3 ** --temp;
>3 ** --temp : number
>3 : number
>--temp : number
>temp : number
3 ** temp++;
>3 ** temp++ : number
>3 : number
>temp++ : number
>temp : number
3 ** temp--;
>3 ** temp-- : number
>3 : number
>temp-- : number
>temp : number
3 ** ++temp ** 2;
>3 ** ++temp ** 2 : number
>3 : number
>++temp ** 2 : number
>++temp : number
>temp : number
>2 : number
3 ** --temp ** 2;
>3 ** --temp ** 2 : number
>3 : number
>--temp ** 2 : number
>--temp : number
>temp : number
>2 : number
3 ** temp++ ** 2;
>3 ** temp++ ** 2 : number
>3 : number
>temp++ ** 2 : number
>temp++ : number
>temp : number
>2 : number
3 ** temp-- ** 2;
>3 ** temp-- ** 2 : number
>3 : number
>temp-- ** 2 : number
>temp-- : number
>temp : number
>2 : number
3 ** ++temp + 2;
>3 ** ++temp + 2 : number
>3 ** ++temp : number
>3 : number
>++temp : number
>temp : number
>2 : number
3 ** ++temp - 2;
>3 ** ++temp - 2 : number
>3 ** ++temp : number
>3 : number
>++temp : number
>temp : number
>2 : number
3 ** ++temp * 2;
>3 ** ++temp * 2 : number
>3 ** ++temp : number
>3 : number
>++temp : number
>temp : number
>2 : number
3 ** ++temp / 2;
>3 ** ++temp / 2 : number
>3 ** ++temp : number
>3 : number
>++temp : number
>temp : number
>2 : number
3 ** ++temp % 2;
>3 ** ++temp % 2 : number
>3 ** ++temp : number
>3 : number
>++temp : number
>temp : number
>2 : number
3 ** --temp + 2;
>3 ** --temp + 2 : number
>3 ** --temp : number
>3 : number
>--temp : number
>temp : number
>2 : number
3 ** --temp - 2;
>3 ** --temp - 2 : number
>3 ** --temp : number
>3 : number
>--temp : number
>temp : number
>2 : number
3 ** --temp * 2;
>3 ** --temp * 2 : number
>3 ** --temp : number
>3 : number
>--temp : number
>temp : number
>2 : number
3 ** --temp / 2;
>3 ** --temp / 2 : number
>3 ** --temp : number
>3 : number
>--temp : number
>temp : number
>2 : number
3 ** --temp % 2;
>3 ** --temp % 2 : number
>3 ** --temp : number
>3 : number
>--temp : number
>temp : number
>2 : number
@@ -0,0 +1,78 @@
//// [emitExponentiationOperator3.ts]
var temp = 10;
(-++temp) ** 3;
(+--temp) ** 3;
(-temp++) ** 3;
(+temp--) ** 3;
(-(1 ** ++temp)) ** 3;
(-(1 ** --temp)) ** 3;
(-(1 ** temp++)) ** 3;
(-(1 ** temp--)) ** 3;
(-3) ** temp++;
(-3) ** temp--;
(-3) ** ++temp;
(-3) ** --temp;
(+3) ** temp++;
(+3) ** temp--;
(+3) ** ++temp;
(+3) ** --temp;
(-3) ** temp++ ** 2;
(-3) ** temp-- ** 2;
(-3) ** ++temp ** 2;
(-3) ** --temp ** 2;
(+3) ** temp++ ** 2;
(+3) ** temp-- ** 2;
(+3) ** ++temp ** 2;
(+3) ** --temp ** 2;
3 ** -temp++;
3 ** -temp--;
3 ** -++temp;
3 ** +--temp;
3 ** (-temp++) ** 2;
3 ** (-temp--) ** 2;
3 ** (+temp++) ** 2;
3 ** (+temp--) ** 2;
3 ** (-++temp) ** 2;
3 ** (+--temp) ** 2;
//// [emitExponentiationOperator3.js]
var temp = 10;
Math.pow((-++temp), 3);
Math.pow((+--temp), 3);
Math.pow((-temp++), 3);
Math.pow((+temp--), 3);
Math.pow((-(Math.pow(1, ++temp))), 3);
Math.pow((-(Math.pow(1, --temp))), 3);
Math.pow((-(Math.pow(1, temp++))), 3);
Math.pow((-(Math.pow(1, temp--))), 3);
Math.pow((-3), temp++);
Math.pow((-3), temp--);
Math.pow((-3), ++temp);
Math.pow((-3), --temp);
Math.pow((+3), temp++);
Math.pow((+3), temp--);
Math.pow((+3), ++temp);
Math.pow((+3), --temp);
Math.pow((-3), Math.pow(temp++, 2));
Math.pow((-3), Math.pow(temp--, 2));
Math.pow((-3), Math.pow(++temp, 2));
Math.pow((-3), Math.pow(--temp, 2));
Math.pow((+3), Math.pow(temp++, 2));
Math.pow((+3), Math.pow(temp--, 2));
Math.pow((+3), Math.pow(++temp, 2));
Math.pow((+3), Math.pow(--temp, 2));
Math.pow(3, -temp++);
Math.pow(3, -temp--);
Math.pow(3, -++temp);
Math.pow(3, +--temp);
Math.pow(3, Math.pow((-temp++), 2));
Math.pow(3, Math.pow((-temp--), 2));
Math.pow(3, Math.pow((+temp++), 2));
Math.pow(3, Math.pow((+temp--), 2));
Math.pow(3, Math.pow((-++temp), 2));
Math.pow(3, Math.pow((+--temp), 2));
@@ -0,0 +1,107 @@
=== tests/cases/conformance/es7/exponentiationOperator/emitExponentiationOperator3.ts ===
var temp = 10;
>temp : Symbol(temp, Decl(emitExponentiationOperator3.ts, 1, 3))
(-++temp) ** 3;
>temp : Symbol(temp, Decl(emitExponentiationOperator3.ts, 1, 3))
(+--temp) ** 3;
>temp : Symbol(temp, Decl(emitExponentiationOperator3.ts, 1, 3))
(-temp++) ** 3;
>temp : Symbol(temp, Decl(emitExponentiationOperator3.ts, 1, 3))
(+temp--) ** 3;
>temp : Symbol(temp, Decl(emitExponentiationOperator3.ts, 1, 3))
(-(1 ** ++temp)) ** 3;
>temp : Symbol(temp, Decl(emitExponentiationOperator3.ts, 1, 3))
(-(1 ** --temp)) ** 3;
>temp : Symbol(temp, Decl(emitExponentiationOperator3.ts, 1, 3))
(-(1 ** temp++)) ** 3;
>temp : Symbol(temp, Decl(emitExponentiationOperator3.ts, 1, 3))
(-(1 ** temp--)) ** 3;
>temp : Symbol(temp, Decl(emitExponentiationOperator3.ts, 1, 3))
(-3) ** temp++;
>temp : Symbol(temp, Decl(emitExponentiationOperator3.ts, 1, 3))
(-3) ** temp--;
>temp : Symbol(temp, Decl(emitExponentiationOperator3.ts, 1, 3))
(-3) ** ++temp;
>temp : Symbol(temp, Decl(emitExponentiationOperator3.ts, 1, 3))
(-3) ** --temp;
>temp : Symbol(temp, Decl(emitExponentiationOperator3.ts, 1, 3))
(+3) ** temp++;
>temp : Symbol(temp, Decl(emitExponentiationOperator3.ts, 1, 3))
(+3) ** temp--;
>temp : Symbol(temp, Decl(emitExponentiationOperator3.ts, 1, 3))
(+3) ** ++temp;
>temp : Symbol(temp, Decl(emitExponentiationOperator3.ts, 1, 3))
(+3) ** --temp;
>temp : Symbol(temp, Decl(emitExponentiationOperator3.ts, 1, 3))
(-3) ** temp++ ** 2;
>temp : Symbol(temp, Decl(emitExponentiationOperator3.ts, 1, 3))
(-3) ** temp-- ** 2;
>temp : Symbol(temp, Decl(emitExponentiationOperator3.ts, 1, 3))
(-3) ** ++temp ** 2;
>temp : Symbol(temp, Decl(emitExponentiationOperator3.ts, 1, 3))
(-3) ** --temp ** 2;
>temp : Symbol(temp, Decl(emitExponentiationOperator3.ts, 1, 3))
(+3) ** temp++ ** 2;
>temp : Symbol(temp, Decl(emitExponentiationOperator3.ts, 1, 3))
(+3) ** temp-- ** 2;
>temp : Symbol(temp, Decl(emitExponentiationOperator3.ts, 1, 3))
(+3) ** ++temp ** 2;
>temp : Symbol(temp, Decl(emitExponentiationOperator3.ts, 1, 3))
(+3) ** --temp ** 2;
>temp : Symbol(temp, Decl(emitExponentiationOperator3.ts, 1, 3))
3 ** -temp++;
>temp : Symbol(temp, Decl(emitExponentiationOperator3.ts, 1, 3))
3 ** -temp--;
>temp : Symbol(temp, Decl(emitExponentiationOperator3.ts, 1, 3))
3 ** -++temp;
>temp : Symbol(temp, Decl(emitExponentiationOperator3.ts, 1, 3))
3 ** +--temp;
>temp : Symbol(temp, Decl(emitExponentiationOperator3.ts, 1, 3))
3 ** (-temp++) ** 2;
>temp : Symbol(temp, Decl(emitExponentiationOperator3.ts, 1, 3))
3 ** (-temp--) ** 2;
>temp : Symbol(temp, Decl(emitExponentiationOperator3.ts, 1, 3))
3 ** (+temp++) ** 2;
>temp : Symbol(temp, Decl(emitExponentiationOperator3.ts, 1, 3))
3 ** (+temp--) ** 2;
>temp : Symbol(temp, Decl(emitExponentiationOperator3.ts, 1, 3))
3 ** (-++temp) ** 2;
>temp : Symbol(temp, Decl(emitExponentiationOperator3.ts, 1, 3))
3 ** (+--temp) ** 2;
>temp : Symbol(temp, Decl(emitExponentiationOperator3.ts, 1, 3))
@@ -0,0 +1,314 @@
=== tests/cases/conformance/es7/exponentiationOperator/emitExponentiationOperator3.ts ===
var temp = 10;
>temp : number
>10 : number
(-++temp) ** 3;
>(-++temp) ** 3 : number
>(-++temp) : number
>-++temp : number
>++temp : number
>temp : number
>3 : number
(+--temp) ** 3;
>(+--temp) ** 3 : number
>(+--temp) : number
>+--temp : number
>--temp : number
>temp : number
>3 : number
(-temp++) ** 3;
>(-temp++) ** 3 : number
>(-temp++) : number
>-temp++ : number
>temp++ : number
>temp : number
>3 : number
(+temp--) ** 3;
>(+temp--) ** 3 : number
>(+temp--) : number
>+temp-- : number
>temp-- : number
>temp : number
>3 : number
(-(1 ** ++temp)) ** 3;
>(-(1 ** ++temp)) ** 3 : number
>(-(1 ** ++temp)) : number
>-(1 ** ++temp) : number
>(1 ** ++temp) : number
>1 ** ++temp : number
>1 : number
>++temp : number
>temp : number
>3 : number
(-(1 ** --temp)) ** 3;
>(-(1 ** --temp)) ** 3 : number
>(-(1 ** --temp)) : number
>-(1 ** --temp) : number
>(1 ** --temp) : number
>1 ** --temp : number
>1 : number
>--temp : number
>temp : number
>3 : number
(-(1 ** temp++)) ** 3;
>(-(1 ** temp++)) ** 3 : number
>(-(1 ** temp++)) : number
>-(1 ** temp++) : number
>(1 ** temp++) : number
>1 ** temp++ : number
>1 : number
>temp++ : number
>temp : number
>3 : number
(-(1 ** temp--)) ** 3;
>(-(1 ** temp--)) ** 3 : number
>(-(1 ** temp--)) : number
>-(1 ** temp--) : number
>(1 ** temp--) : number
>1 ** temp-- : number
>1 : number
>temp-- : number
>temp : number
>3 : number
(-3) ** temp++;
>(-3) ** temp++ : number
>(-3) : number
>-3 : number
>3 : number
>temp++ : number
>temp : number
(-3) ** temp--;
>(-3) ** temp-- : number
>(-3) : number
>-3 : number
>3 : number
>temp-- : number
>temp : number
(-3) ** ++temp;
>(-3) ** ++temp : number
>(-3) : number
>-3 : number
>3 : number
>++temp : number
>temp : number
(-3) ** --temp;
>(-3) ** --temp : number
>(-3) : number
>-3 : number
>3 : number
>--temp : number
>temp : number
(+3) ** temp++;
>(+3) ** temp++ : number
>(+3) : number
>+3 : number
>3 : number
>temp++ : number
>temp : number
(+3) ** temp--;
>(+3) ** temp-- : number
>(+3) : number
>+3 : number
>3 : number
>temp-- : number
>temp : number
(+3) ** ++temp;
>(+3) ** ++temp : number
>(+3) : number
>+3 : number
>3 : number
>++temp : number
>temp : number
(+3) ** --temp;
>(+3) ** --temp : number
>(+3) : number
>+3 : number
>3 : number
>--temp : number
>temp : number
(-3) ** temp++ ** 2;
>(-3) ** temp++ ** 2 : number
>(-3) : number
>-3 : number
>3 : number
>temp++ ** 2 : number
>temp++ : number
>temp : number
>2 : number
(-3) ** temp-- ** 2;
>(-3) ** temp-- ** 2 : number
>(-3) : number
>-3 : number
>3 : number
>temp-- ** 2 : number
>temp-- : number
>temp : number
>2 : number
(-3) ** ++temp ** 2;
>(-3) ** ++temp ** 2 : number
>(-3) : number
>-3 : number
>3 : number
>++temp ** 2 : number
>++temp : number
>temp : number
>2 : number
(-3) ** --temp ** 2;
>(-3) ** --temp ** 2 : number
>(-3) : number
>-3 : number
>3 : number
>--temp ** 2 : number
>--temp : number
>temp : number
>2 : number
(+3) ** temp++ ** 2;
>(+3) ** temp++ ** 2 : number
>(+3) : number
>+3 : number
>3 : number
>temp++ ** 2 : number
>temp++ : number
>temp : number
>2 : number
(+3) ** temp-- ** 2;
>(+3) ** temp-- ** 2 : number
>(+3) : number
>+3 : number
>3 : number
>temp-- ** 2 : number
>temp-- : number
>temp : number
>2 : number
(+3) ** ++temp ** 2;
>(+3) ** ++temp ** 2 : number
>(+3) : number
>+3 : number
>3 : number
>++temp ** 2 : number
>++temp : number
>temp : number
>2 : number
(+3) ** --temp ** 2;
>(+3) ** --temp ** 2 : number
>(+3) : number
>+3 : number
>3 : number
>--temp ** 2 : number
>--temp : number
>temp : number
>2 : number
3 ** -temp++;
>3 ** -temp++ : number
>3 : number
>-temp++ : number
>temp++ : number
>temp : number
3 ** -temp--;
>3 ** -temp-- : number
>3 : number
>-temp-- : number
>temp-- : number
>temp : number
3 ** -++temp;
>3 ** -++temp : number
>3 : number
>-++temp : number
>++temp : number
>temp : number
3 ** +--temp;
>3 ** +--temp : number
>3 : number
>+--temp : number
>--temp : number
>temp : number
3 ** (-temp++) ** 2;
>3 ** (-temp++) ** 2 : number
>3 : number
>(-temp++) ** 2 : number
>(-temp++) : number
>-temp++ : number
>temp++ : number
>temp : number
>2 : number
3 ** (-temp--) ** 2;
>3 ** (-temp--) ** 2 : number
>3 : number
>(-temp--) ** 2 : number
>(-temp--) : number
>-temp-- : number
>temp-- : number
>temp : number
>2 : number
3 ** (+temp++) ** 2;
>3 ** (+temp++) ** 2 : number
>3 : number
>(+temp++) ** 2 : number
>(+temp++) : number
>+temp++ : number
>temp++ : number
>temp : number
>2 : number
3 ** (+temp--) ** 2;
>3 ** (+temp--) ** 2 : number
>3 : number
>(+temp--) ** 2 : number
>(+temp--) : number
>+temp-- : number
>temp-- : number
>temp : number
>2 : number
3 ** (-++temp) ** 2;
>3 ** (-++temp) ** 2 : number
>3 : number
>(-++temp) ** 2 : number
>(-++temp) : number
>-++temp : number
>++temp : number
>temp : number
>2 : number
3 ** (+--temp) ** 2;
>3 ** (+--temp) ** 2 : number
>3 : number
>(+--temp) ** 2 : number
>(+--temp) : number
>+--temp : number
>--temp : number
>temp : number
>2 : number
@@ -0,0 +1,70 @@
//// [emitExponentiationOperator4.ts]
var temp: any;
(<number>temp) ** 3;
(<number>--temp) ** 3;
(<number>++temp) ** 3;
(<number>temp--) ** 3;
(<number>temp++) ** 3;
1 ** (<number>--temp) ** 3;
1 ** (<number>++temp) ** 3;
1 ** (<number>temp--) ** 3;
1 ** (<number>temp++) ** 3;
(void --temp) ** 3;
(void temp--) ** 3;
(void 3) ** 4;
(void temp++) ** 4;
(void temp--) ** 4;
1 ** (void --temp) ** 3;
1 ** (void temp--) ** 3;
1 ** (void 3) ** 4;
1 ** (void temp++) ** 4;
1 ** (void temp--) ** 4;
(~ --temp) ** 3;
(~ temp--) ** 3;
(~ 3) ** 4;
(~ temp++) ** 4;
(~ temp--) ** 4;
1 ** (~ --temp) ** 3;
1 ** (~ temp--) ** 3;
1 ** (~ 3) ** 4;
1 ** (~ temp++) ** 4;
1 ** (~ temp--) ** 4;
//// [emitExponentiationOperator4.js]
var temp;
Math.pow(temp, 3);
Math.pow((--temp), 3);
Math.pow((++temp), 3);
Math.pow((temp--), 3);
Math.pow((temp++), 3);
Math.pow(1, Math.pow((--temp), 3));
Math.pow(1, Math.pow((++temp), 3));
Math.pow(1, Math.pow((temp--), 3));
Math.pow(1, Math.pow((temp++), 3));
Math.pow((void --temp), 3);
Math.pow((void temp--), 3);
Math.pow((void 3), 4);
Math.pow((void temp++), 4);
Math.pow((void temp--), 4);
Math.pow(1, Math.pow((void --temp), 3));
Math.pow(1, Math.pow((void temp--), 3));
Math.pow(1, Math.pow((void 3), 4));
Math.pow(1, Math.pow((void temp++), 4));
Math.pow(1, Math.pow((void temp--), 4));
Math.pow((~--temp), 3);
Math.pow((~temp--), 3);
Math.pow((~3), 4);
Math.pow((~temp++), 4);
Math.pow((~temp--), 4);
Math.pow(1, Math.pow((~--temp), 3));
Math.pow(1, Math.pow((~temp--), 3));
Math.pow(1, Math.pow((~3), 4));
Math.pow(1, Math.pow((~temp++), 4));
Math.pow(1, Math.pow((~temp--), 4));
@@ -0,0 +1,84 @@
=== tests/cases/conformance/es7/exponentiationOperator/emitExponentiationOperator4.ts ===
var temp: any;
>temp : Symbol(temp, Decl(emitExponentiationOperator4.ts, 0, 3))
(<number>temp) ** 3;
>temp : Symbol(temp, Decl(emitExponentiationOperator4.ts, 0, 3))
(<number>--temp) ** 3;
>temp : Symbol(temp, Decl(emitExponentiationOperator4.ts, 0, 3))
(<number>++temp) ** 3;
>temp : Symbol(temp, Decl(emitExponentiationOperator4.ts, 0, 3))
(<number>temp--) ** 3;
>temp : Symbol(temp, Decl(emitExponentiationOperator4.ts, 0, 3))
(<number>temp++) ** 3;
>temp : Symbol(temp, Decl(emitExponentiationOperator4.ts, 0, 3))
1 ** (<number>--temp) ** 3;
>temp : Symbol(temp, Decl(emitExponentiationOperator4.ts, 0, 3))
1 ** (<number>++temp) ** 3;
>temp : Symbol(temp, Decl(emitExponentiationOperator4.ts, 0, 3))
1 ** (<number>temp--) ** 3;
>temp : Symbol(temp, Decl(emitExponentiationOperator4.ts, 0, 3))
1 ** (<number>temp++) ** 3;
>temp : Symbol(temp, Decl(emitExponentiationOperator4.ts, 0, 3))
(void --temp) ** 3;
>temp : Symbol(temp, Decl(emitExponentiationOperator4.ts, 0, 3))
(void temp--) ** 3;
>temp : Symbol(temp, Decl(emitExponentiationOperator4.ts, 0, 3))
(void 3) ** 4;
(void temp++) ** 4;
>temp : Symbol(temp, Decl(emitExponentiationOperator4.ts, 0, 3))
(void temp--) ** 4;
>temp : Symbol(temp, Decl(emitExponentiationOperator4.ts, 0, 3))
1 ** (void --temp) ** 3;
>temp : Symbol(temp, Decl(emitExponentiationOperator4.ts, 0, 3))
1 ** (void temp--) ** 3;
>temp : Symbol(temp, Decl(emitExponentiationOperator4.ts, 0, 3))
1 ** (void 3) ** 4;
1 ** (void temp++) ** 4;
>temp : Symbol(temp, Decl(emitExponentiationOperator4.ts, 0, 3))
1 ** (void temp--) ** 4;
>temp : Symbol(temp, Decl(emitExponentiationOperator4.ts, 0, 3))
(~ --temp) ** 3;
>temp : Symbol(temp, Decl(emitExponentiationOperator4.ts, 0, 3))
(~ temp--) ** 3;
>temp : Symbol(temp, Decl(emitExponentiationOperator4.ts, 0, 3))
(~ 3) ** 4;
(~ temp++) ** 4;
>temp : Symbol(temp, Decl(emitExponentiationOperator4.ts, 0, 3))
(~ temp--) ** 4;
>temp : Symbol(temp, Decl(emitExponentiationOperator4.ts, 0, 3))
1 ** (~ --temp) ** 3;
>temp : Symbol(temp, Decl(emitExponentiationOperator4.ts, 0, 3))
1 ** (~ temp--) ** 3;
>temp : Symbol(temp, Decl(emitExponentiationOperator4.ts, 0, 3))
1 ** (~ 3) ** 4;
1 ** (~ temp++) ** 4;
>temp : Symbol(temp, Decl(emitExponentiationOperator4.ts, 0, 3))
1 ** (~ temp--) ** 4;
>temp : Symbol(temp, Decl(emitExponentiationOperator4.ts, 0, 3))
@@ -0,0 +1,260 @@
=== tests/cases/conformance/es7/exponentiationOperator/emitExponentiationOperator4.ts ===
var temp: any;
>temp : any
(<number>temp) ** 3;
>(<number>temp) ** 3 : number
>(<number>temp) : number
><number>temp : number
>temp : any
>3 : number
(<number>--temp) ** 3;
>(<number>--temp) ** 3 : number
>(<number>--temp) : number
><number>--temp : number
>--temp : number
>temp : any
>3 : number
(<number>++temp) ** 3;
>(<number>++temp) ** 3 : number
>(<number>++temp) : number
><number>++temp : number
>++temp : number
>temp : any
>3 : number
(<number>temp--) ** 3;
>(<number>temp--) ** 3 : number
>(<number>temp--) : number
><number>temp-- : number
>temp-- : number
>temp : any
>3 : number
(<number>temp++) ** 3;
>(<number>temp++) ** 3 : number
>(<number>temp++) : number
><number>temp++ : number
>temp++ : number
>temp : any
>3 : number
1 ** (<number>--temp) ** 3;
>1 ** (<number>--temp) ** 3 : number
>1 : number
>(<number>--temp) ** 3 : number
>(<number>--temp) : number
><number>--temp : number
>--temp : number
>temp : any
>3 : number
1 ** (<number>++temp) ** 3;
>1 ** (<number>++temp) ** 3 : number
>1 : number
>(<number>++temp) ** 3 : number
>(<number>++temp) : number
><number>++temp : number
>++temp : number
>temp : any
>3 : number
1 ** (<number>temp--) ** 3;
>1 ** (<number>temp--) ** 3 : number
>1 : number
>(<number>temp--) ** 3 : number
>(<number>temp--) : number
><number>temp-- : number
>temp-- : number
>temp : any
>3 : number
1 ** (<number>temp++) ** 3;
>1 ** (<number>temp++) ** 3 : number
>1 : number
>(<number>temp++) ** 3 : number
>(<number>temp++) : number
><number>temp++ : number
>temp++ : number
>temp : any
>3 : number
(void --temp) ** 3;
>(void --temp) ** 3 : number
>(void --temp) : undefined
>void --temp : undefined
>--temp : number
>temp : any
>3 : number
(void temp--) ** 3;
>(void temp--) ** 3 : number
>(void temp--) : undefined
>void temp-- : undefined
>temp-- : number
>temp : any
>3 : number
(void 3) ** 4;
>(void 3) ** 4 : number
>(void 3) : undefined
>void 3 : undefined
>3 : number
>4 : number
(void temp++) ** 4;
>(void temp++) ** 4 : number
>(void temp++) : undefined
>void temp++ : undefined
>temp++ : number
>temp : any
>4 : number
(void temp--) ** 4;
>(void temp--) ** 4 : number
>(void temp--) : undefined
>void temp-- : undefined
>temp-- : number
>temp : any
>4 : number
1 ** (void --temp) ** 3;
>1 ** (void --temp) ** 3 : number
>1 : number
>(void --temp) ** 3 : number
>(void --temp) : undefined
>void --temp : undefined
>--temp : number
>temp : any
>3 : number
1 ** (void temp--) ** 3;
>1 ** (void temp--) ** 3 : number
>1 : number
>(void temp--) ** 3 : number
>(void temp--) : undefined
>void temp-- : undefined
>temp-- : number
>temp : any
>3 : number
1 ** (void 3) ** 4;
>1 ** (void 3) ** 4 : number
>1 : number
>(void 3) ** 4 : number
>(void 3) : undefined
>void 3 : undefined
>3 : number
>4 : number
1 ** (void temp++) ** 4;
>1 ** (void temp++) ** 4 : number
>1 : number
>(void temp++) ** 4 : number
>(void temp++) : undefined
>void temp++ : undefined
>temp++ : number
>temp : any
>4 : number
1 ** (void temp--) ** 4;
>1 ** (void temp--) ** 4 : number
>1 : number
>(void temp--) ** 4 : number
>(void temp--) : undefined
>void temp-- : undefined
>temp-- : number
>temp : any
>4 : number
(~ --temp) ** 3;
>(~ --temp) ** 3 : number
>(~ --temp) : number
>~ --temp : number
>--temp : number
>temp : any
>3 : number
(~ temp--) ** 3;
>(~ temp--) ** 3 : number
>(~ temp--) : number
>~ temp-- : number
>temp-- : number
>temp : any
>3 : number
(~ 3) ** 4;
>(~ 3) ** 4 : number
>(~ 3) : number
>~ 3 : number
>3 : number
>4 : number
(~ temp++) ** 4;
>(~ temp++) ** 4 : number
>(~ temp++) : number
>~ temp++ : number
>temp++ : number
>temp : any
>4 : number
(~ temp--) ** 4;
>(~ temp--) ** 4 : number
>(~ temp--) : number
>~ temp-- : number
>temp-- : number
>temp : any
>4 : number
1 ** (~ --temp) ** 3;
>1 ** (~ --temp) ** 3 : number
>1 : number
>(~ --temp) ** 3 : number
>(~ --temp) : number
>~ --temp : number
>--temp : number
>temp : any
>3 : number
1 ** (~ temp--) ** 3;
>1 ** (~ temp--) ** 3 : number
>1 : number
>(~ temp--) ** 3 : number
>(~ temp--) : number
>~ temp-- : number
>temp-- : number
>temp : any
>3 : number
1 ** (~ 3) ** 4;
>1 ** (~ 3) ** 4 : number
>1 : number
>(~ 3) ** 4 : number
>(~ 3) : number
>~ 3 : number
>3 : number
>4 : number
1 ** (~ temp++) ** 4;
>1 ** (~ temp++) ** 4 : number
>1 : number
>(~ temp++) ** 4 : number
>(~ temp++) : number
>~ temp++ : number
>temp++ : number
>temp : any
>4 : number
1 ** (~ temp--) ** 4;
>1 ** (~ temp--) ** 4 : number
>1 : number
>(~ temp--) ** 4 : number
>(~ temp--) : number
>~ temp-- : number
>temp-- : number
>temp : any
>4 : number
@@ -0,0 +1,53 @@
//// [emitExponentiationOperatorInTempalteString4.ts]
var t1 = 10;
var t2 = 10;
var s;
// With TemplateTail
`${t1 ** -t2} world`;
`${(-t1) ** t2 - t1} world`;
`${(-++t1) ** t2 - t1} world`;
`${(-t1++) ** t2 - t1} world`;
`${(~t1) ** t2 ** --t1 } world`;
`${typeof (t1 ** t2 ** t1) } world`;
// TempateHead & TemplateTail are empt
`${t1 ** -t2} hello world ${t1 ** -t2}`;
`${(-t1) ** t2 - t1} hello world ${(-t1) ** t2 - t1}`;
`${(-++t1) ** t2 - t1} hello world ${t1 ** (-++t1) **- t1}`;
`${(-t1++) ** t2 - t1} hello world ${t2 ** (-t1++) ** - t1}`;
`${(~t1) ** t2 ** --t1 } hello world ${(~t1) ** t2 ** --t1 }`;
`${typeof (t1 ** t2 ** t1)} hello world ${typeof (t1 ** t2 ** t1)}`;
// With templateHead
`hello ${(-t1) ** t2 - t1}`;
`hello ${(-++t1) ** t2 - t1}`;
`hello ${(-t1++) ** t2 - t1}`;
`hello ${(~t1) ** t2 ** --t1 }`;
`hello ${typeof (t1 ** t2 ** t1)}`;
//// [emitExponentiationOperatorInTempalteString4.js]
var t1 = 10;
var t2 = 10;
var s;
// With TemplateTail
(Math.pow(t1, -t2)) + " world";
(Math.pow((-t1), t2) - t1) + " world";
(Math.pow((-++t1), t2) - t1) + " world";
(Math.pow((-t1++), t2) - t1) + " world";
(Math.pow((~t1), Math.pow(t2, --t1))) + " world";
typeof (Math.pow(t1, Math.pow(t2, t1))) + " world";
// TempateHead & TemplateTail are empt
(Math.pow(t1, -t2)) + " hello world " + (Math.pow(t1, -t2));
(Math.pow((-t1), t2) - t1) + " hello world " + (Math.pow((-t1), t2) - t1);
(Math.pow((-++t1), t2) - t1) + " hello world " + (Math.pow(t1, Math.pow((-++t1), -t1)));
(Math.pow((-t1++), t2) - t1) + " hello world " + (Math.pow(t2, Math.pow((-t1++), -t1)));
(Math.pow((~t1), Math.pow(t2, --t1))) + " hello world " + (Math.pow((~t1), Math.pow(t2, --t1)));
typeof (Math.pow(t1, Math.pow(t2, t1))) + " hello world " + typeof (Math.pow(t1, Math.pow(t2, t1)));
// With templateHead
"hello " + (Math.pow((-t1), t2) - t1);
"hello " + (Math.pow((-++t1), t2) - t1);
"hello " + (Math.pow((-t1++), t2) - t1);
"hello " + (Math.pow((~t1), Math.pow(t2, --t1)));
"hello " + typeof (Math.pow(t1, Math.pow(t2, t1)));
@@ -0,0 +1,114 @@
=== tests/cases/conformance/es7/exponentiationOperator/emitExponentiationOperatorInTempalteString4.ts ===
var t1 = 10;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4.ts, 1, 3))
var t2 = 10;
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTempalteString4.ts, 2, 3))
var s;
>s : Symbol(s, Decl(emitExponentiationOperatorInTempalteString4.ts, 3, 3))
// With TemplateTail
`${t1 ** -t2} world`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTempalteString4.ts, 2, 3))
`${(-t1) ** t2 - t1} world`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTempalteString4.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4.ts, 1, 3))
`${(-++t1) ** t2 - t1} world`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTempalteString4.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4.ts, 1, 3))
`${(-t1++) ** t2 - t1} world`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTempalteString4.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4.ts, 1, 3))
`${(~t1) ** t2 ** --t1 } world`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTempalteString4.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4.ts, 1, 3))
`${typeof (t1 ** t2 ** t1) } world`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTempalteString4.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4.ts, 1, 3))
// TempateHead & TemplateTail are empt
`${t1 ** -t2} hello world ${t1 ** -t2}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTempalteString4.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTempalteString4.ts, 2, 3))
`${(-t1) ** t2 - t1} hello world ${(-t1) ** t2 - t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTempalteString4.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTempalteString4.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4.ts, 1, 3))
`${(-++t1) ** t2 - t1} hello world ${t1 ** (-++t1) **- t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTempalteString4.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4.ts, 1, 3))
`${(-t1++) ** t2 - t1} hello world ${t2 ** (-t1++) ** - t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTempalteString4.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTempalteString4.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4.ts, 1, 3))
`${(~t1) ** t2 ** --t1 } hello world ${(~t1) ** t2 ** --t1 }`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTempalteString4.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTempalteString4.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4.ts, 1, 3))
`${typeof (t1 ** t2 ** t1)} hello world ${typeof (t1 ** t2 ** t1)}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTempalteString4.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTempalteString4.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4.ts, 1, 3))
// With templateHead
`hello ${(-t1) ** t2 - t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTempalteString4.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4.ts, 1, 3))
`hello ${(-++t1) ** t2 - t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTempalteString4.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4.ts, 1, 3))
`hello ${(-t1++) ** t2 - t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTempalteString4.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4.ts, 1, 3))
`hello ${(~t1) ** t2 ** --t1 }`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTempalteString4.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4.ts, 1, 3))
`hello ${typeof (t1 ** t2 ** t1)}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTempalteString4.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4.ts, 1, 3))
@@ -0,0 +1,233 @@
=== tests/cases/conformance/es7/exponentiationOperator/emitExponentiationOperatorInTempalteString4.ts ===
var t1 = 10;
>t1 : number
>10 : number
var t2 = 10;
>t2 : number
>10 : number
var s;
>s : any
// With TemplateTail
`${t1 ** -t2} world`;
>`${t1 ** -t2} world` : string
>t1 ** -t2 : number
>t1 : number
>-t2 : number
>t2 : number
`${(-t1) ** t2 - t1} world`;
>`${(-t1) ** t2 - t1} world` : string
>(-t1) ** t2 - t1 : number
>(-t1) ** t2 : number
>(-t1) : number
>-t1 : number
>t1 : number
>t2 : number
>t1 : number
`${(-++t1) ** t2 - t1} world`;
>`${(-++t1) ** t2 - t1} world` : string
>(-++t1) ** t2 - t1 : number
>(-++t1) ** t2 : number
>(-++t1) : number
>-++t1 : number
>++t1 : number
>t1 : number
>t2 : number
>t1 : number
`${(-t1++) ** t2 - t1} world`;
>`${(-t1++) ** t2 - t1} world` : string
>(-t1++) ** t2 - t1 : number
>(-t1++) ** t2 : number
>(-t1++) : number
>-t1++ : number
>t1++ : number
>t1 : number
>t2 : number
>t1 : number
`${(~t1) ** t2 ** --t1 } world`;
>`${(~t1) ** t2 ** --t1 } world` : string
>(~t1) ** t2 ** --t1 : number
>(~t1) : number
>~t1 : number
>t1 : number
>t2 ** --t1 : number
>t2 : number
>--t1 : number
>t1 : number
`${typeof (t1 ** t2 ** t1) } world`;
>`${typeof (t1 ** t2 ** t1) } world` : string
>typeof (t1 ** t2 ** t1) : string
>(t1 ** t2 ** t1) : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
// TempateHead & TemplateTail are empt
`${t1 ** -t2} hello world ${t1 ** -t2}`;
>`${t1 ** -t2} hello world ${t1 ** -t2}` : string
>t1 ** -t2 : number
>t1 : number
>-t2 : number
>t2 : number
>t1 ** -t2 : number
>t1 : number
>-t2 : number
>t2 : number
`${(-t1) ** t2 - t1} hello world ${(-t1) ** t2 - t1}`;
>`${(-t1) ** t2 - t1} hello world ${(-t1) ** t2 - t1}` : string
>(-t1) ** t2 - t1 : number
>(-t1) ** t2 : number
>(-t1) : number
>-t1 : number
>t1 : number
>t2 : number
>t1 : number
>(-t1) ** t2 - t1 : number
>(-t1) ** t2 : number
>(-t1) : number
>-t1 : number
>t1 : number
>t2 : number
>t1 : number
`${(-++t1) ** t2 - t1} hello world ${t1 ** (-++t1) **- t1}`;
>`${(-++t1) ** t2 - t1} hello world ${t1 ** (-++t1) **- t1}` : string
>(-++t1) ** t2 - t1 : number
>(-++t1) ** t2 : number
>(-++t1) : number
>-++t1 : number
>++t1 : number
>t1 : number
>t2 : number
>t1 : number
>t1 ** (-++t1) **- t1 : number
>t1 : number
>(-++t1) **- t1 : number
>(-++t1) : number
>-++t1 : number
>++t1 : number
>t1 : number
>- t1 : number
>t1 : number
`${(-t1++) ** t2 - t1} hello world ${t2 ** (-t1++) ** - t1}`;
>`${(-t1++) ** t2 - t1} hello world ${t2 ** (-t1++) ** - t1}` : string
>(-t1++) ** t2 - t1 : number
>(-t1++) ** t2 : number
>(-t1++) : number
>-t1++ : number
>t1++ : number
>t1 : number
>t2 : number
>t1 : number
>t2 ** (-t1++) ** - t1 : number
>t2 : number
>(-t1++) ** - t1 : number
>(-t1++) : number
>-t1++ : number
>t1++ : number
>t1 : number
>- t1 : number
>t1 : number
`${(~t1) ** t2 ** --t1 } hello world ${(~t1) ** t2 ** --t1 }`;
>`${(~t1) ** t2 ** --t1 } hello world ${(~t1) ** t2 ** --t1 }` : string
>(~t1) ** t2 ** --t1 : number
>(~t1) : number
>~t1 : number
>t1 : number
>t2 ** --t1 : number
>t2 : number
>--t1 : number
>t1 : number
>(~t1) ** t2 ** --t1 : number
>(~t1) : number
>~t1 : number
>t1 : number
>t2 ** --t1 : number
>t2 : number
>--t1 : number
>t1 : number
`${typeof (t1 ** t2 ** t1)} hello world ${typeof (t1 ** t2 ** t1)}`;
>`${typeof (t1 ** t2 ** t1)} hello world ${typeof (t1 ** t2 ** t1)}` : string
>typeof (t1 ** t2 ** t1) : string
>(t1 ** t2 ** t1) : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
>typeof (t1 ** t2 ** t1) : string
>(t1 ** t2 ** t1) : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
// With templateHead
`hello ${(-t1) ** t2 - t1}`;
>`hello ${(-t1) ** t2 - t1}` : string
>(-t1) ** t2 - t1 : number
>(-t1) ** t2 : number
>(-t1) : number
>-t1 : number
>t1 : number
>t2 : number
>t1 : number
`hello ${(-++t1) ** t2 - t1}`;
>`hello ${(-++t1) ** t2 - t1}` : string
>(-++t1) ** t2 - t1 : number
>(-++t1) ** t2 : number
>(-++t1) : number
>-++t1 : number
>++t1 : number
>t1 : number
>t2 : number
>t1 : number
`hello ${(-t1++) ** t2 - t1}`;
>`hello ${(-t1++) ** t2 - t1}` : string
>(-t1++) ** t2 - t1 : number
>(-t1++) ** t2 : number
>(-t1++) : number
>-t1++ : number
>t1++ : number
>t1 : number
>t2 : number
>t1 : number
`hello ${(~t1) ** t2 ** --t1 }`;
>`hello ${(~t1) ** t2 ** --t1 }` : string
>(~t1) ** t2 ** --t1 : number
>(~t1) : number
>~t1 : number
>t1 : number
>t2 ** --t1 : number
>t2 : number
>--t1 : number
>t1 : number
`hello ${typeof (t1 ** t2 ** t1)}`;
>`hello ${typeof (t1 ** t2 ** t1)}` : string
>typeof (t1 ** t2 ** t1) : string
>(t1 ** t2 ** t1) : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
@@ -0,0 +1,53 @@
//// [emitExponentiationOperatorInTempalteString4ES6.ts]
var t1 = 10;
var t2 = 10;
var s;
// With TemplateTail
`${t1 ** -t2} world`;
`${(-t1) ** t2 - t1} world`;
`${(-++t1) ** t2 - t1} world`;
`${(-t1++) ** t2 - t1} world`;
`${(~t1) ** t2 ** --t1 } world`;
`${typeof (t1 ** t2 ** t1) } world`;
// TempateHead & TemplateTail are empt
`${t1 ** -t2} hello world ${t1 ** -t2}`;
`${(-t1) ** t2 - t1} hello world ${(-t1) ** t2 - t1}`;
`${(-++t1) ** t2 - t1} hello world ${t1 ** (-++t1) **- t1}`;
`${(-t1++) ** t2 - t1} hello world ${t2 ** (-t1++) ** - t1}`;
`${(~t1) ** t2 ** --t1 } hello world ${(~t1) ** t2 ** --t1 }`;
`${typeof (t1 ** t2 ** t1)} hello world ${typeof (t1 ** t2 ** t1)}`;
// With templateHead
`hello ${(-t1) ** t2 - t1}`;
`hello ${(-++t1) ** t2 - t1}`;
`hello ${(-t1++) ** t2 - t1}`;
`hello ${(~t1) ** t2 ** --t1 }`;
`hello ${typeof (t1 ** t2 ** t1)}`;
//// [emitExponentiationOperatorInTempalteString4ES6.js]
var t1 = 10;
var t2 = 10;
var s;
// With TemplateTail
`${Math.pow(t1, -t2)} world`;
`${Math.pow((-t1), t2) - t1} world`;
`${Math.pow((-++t1), t2) - t1} world`;
`${Math.pow((-t1++), t2) - t1} world`;
`${Math.pow((~t1), Math.pow(t2, --t1))} world`;
`${typeof (Math.pow(t1, Math.pow(t2, t1)))} world`;
// TempateHead & TemplateTail are empt
`${Math.pow(t1, -t2)} hello world ${Math.pow(t1, -t2)}`;
`${Math.pow((-t1), t2) - t1} hello world ${Math.pow((-t1), t2) - t1}`;
`${Math.pow((-++t1), t2) - t1} hello world ${Math.pow(t1, Math.pow((-++t1), -t1))}`;
`${Math.pow((-t1++), t2) - t1} hello world ${Math.pow(t2, Math.pow((-t1++), -t1))}`;
`${Math.pow((~t1), Math.pow(t2, --t1))} hello world ${Math.pow((~t1), Math.pow(t2, --t1))}`;
`${typeof (Math.pow(t1, Math.pow(t2, t1)))} hello world ${typeof (Math.pow(t1, Math.pow(t2, t1)))}`;
// With templateHead
`hello ${Math.pow((-t1), t2) - t1}`;
`hello ${Math.pow((-++t1), t2) - t1}`;
`hello ${Math.pow((-t1++), t2) - t1}`;
`hello ${Math.pow((~t1), Math.pow(t2, --t1))}`;
`hello ${typeof (Math.pow(t1, Math.pow(t2, t1)))}`;
@@ -0,0 +1,114 @@
=== tests/cases/conformance/es7/exponentiationOperator/emitExponentiationOperatorInTempalteString4ES6.ts ===
var t1 = 10;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 1, 3))
var t2 = 10;
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 2, 3))
var s;
>s : Symbol(s, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 3, 3))
// With TemplateTail
`${t1 ** -t2} world`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 2, 3))
`${(-t1) ** t2 - t1} world`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 1, 3))
`${(-++t1) ** t2 - t1} world`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 1, 3))
`${(-t1++) ** t2 - t1} world`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 1, 3))
`${(~t1) ** t2 ** --t1 } world`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 1, 3))
`${typeof (t1 ** t2 ** t1) } world`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 1, 3))
// TempateHead & TemplateTail are empt
`${t1 ** -t2} hello world ${t1 ** -t2}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 2, 3))
`${(-t1) ** t2 - t1} hello world ${(-t1) ** t2 - t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 1, 3))
`${(-++t1) ** t2 - t1} hello world ${t1 ** (-++t1) **- t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 1, 3))
`${(-t1++) ** t2 - t1} hello world ${t2 ** (-t1++) ** - t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 1, 3))
`${(~t1) ** t2 ** --t1 } hello world ${(~t1) ** t2 ** --t1 }`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 1, 3))
`${typeof (t1 ** t2 ** t1)} hello world ${typeof (t1 ** t2 ** t1)}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 1, 3))
// With templateHead
`hello ${(-t1) ** t2 - t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 1, 3))
`hello ${(-++t1) ** t2 - t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 1, 3))
`hello ${(-t1++) ** t2 - t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 1, 3))
`hello ${(~t1) ** t2 ** --t1 }`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 1, 3))
`hello ${typeof (t1 ** t2 ** t1)}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTempalteString4ES6.ts, 1, 3))
@@ -0,0 +1,233 @@
=== tests/cases/conformance/es7/exponentiationOperator/emitExponentiationOperatorInTempalteString4ES6.ts ===
var t1 = 10;
>t1 : number
>10 : number
var t2 = 10;
>t2 : number
>10 : number
var s;
>s : any
// With TemplateTail
`${t1 ** -t2} world`;
>`${t1 ** -t2} world` : string
>t1 ** -t2 : number
>t1 : number
>-t2 : number
>t2 : number
`${(-t1) ** t2 - t1} world`;
>`${(-t1) ** t2 - t1} world` : string
>(-t1) ** t2 - t1 : number
>(-t1) ** t2 : number
>(-t1) : number
>-t1 : number
>t1 : number
>t2 : number
>t1 : number
`${(-++t1) ** t2 - t1} world`;
>`${(-++t1) ** t2 - t1} world` : string
>(-++t1) ** t2 - t1 : number
>(-++t1) ** t2 : number
>(-++t1) : number
>-++t1 : number
>++t1 : number
>t1 : number
>t2 : number
>t1 : number
`${(-t1++) ** t2 - t1} world`;
>`${(-t1++) ** t2 - t1} world` : string
>(-t1++) ** t2 - t1 : number
>(-t1++) ** t2 : number
>(-t1++) : number
>-t1++ : number
>t1++ : number
>t1 : number
>t2 : number
>t1 : number
`${(~t1) ** t2 ** --t1 } world`;
>`${(~t1) ** t2 ** --t1 } world` : string
>(~t1) ** t2 ** --t1 : number
>(~t1) : number
>~t1 : number
>t1 : number
>t2 ** --t1 : number
>t2 : number
>--t1 : number
>t1 : number
`${typeof (t1 ** t2 ** t1) } world`;
>`${typeof (t1 ** t2 ** t1) } world` : string
>typeof (t1 ** t2 ** t1) : string
>(t1 ** t2 ** t1) : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
// TempateHead & TemplateTail are empt
`${t1 ** -t2} hello world ${t1 ** -t2}`;
>`${t1 ** -t2} hello world ${t1 ** -t2}` : string
>t1 ** -t2 : number
>t1 : number
>-t2 : number
>t2 : number
>t1 ** -t2 : number
>t1 : number
>-t2 : number
>t2 : number
`${(-t1) ** t2 - t1} hello world ${(-t1) ** t2 - t1}`;
>`${(-t1) ** t2 - t1} hello world ${(-t1) ** t2 - t1}` : string
>(-t1) ** t2 - t1 : number
>(-t1) ** t2 : number
>(-t1) : number
>-t1 : number
>t1 : number
>t2 : number
>t1 : number
>(-t1) ** t2 - t1 : number
>(-t1) ** t2 : number
>(-t1) : number
>-t1 : number
>t1 : number
>t2 : number
>t1 : number
`${(-++t1) ** t2 - t1} hello world ${t1 ** (-++t1) **- t1}`;
>`${(-++t1) ** t2 - t1} hello world ${t1 ** (-++t1) **- t1}` : string
>(-++t1) ** t2 - t1 : number
>(-++t1) ** t2 : number
>(-++t1) : number
>-++t1 : number
>++t1 : number
>t1 : number
>t2 : number
>t1 : number
>t1 ** (-++t1) **- t1 : number
>t1 : number
>(-++t1) **- t1 : number
>(-++t1) : number
>-++t1 : number
>++t1 : number
>t1 : number
>- t1 : number
>t1 : number
`${(-t1++) ** t2 - t1} hello world ${t2 ** (-t1++) ** - t1}`;
>`${(-t1++) ** t2 - t1} hello world ${t2 ** (-t1++) ** - t1}` : string
>(-t1++) ** t2 - t1 : number
>(-t1++) ** t2 : number
>(-t1++) : number
>-t1++ : number
>t1++ : number
>t1 : number
>t2 : number
>t1 : number
>t2 ** (-t1++) ** - t1 : number
>t2 : number
>(-t1++) ** - t1 : number
>(-t1++) : number
>-t1++ : number
>t1++ : number
>t1 : number
>- t1 : number
>t1 : number
`${(~t1) ** t2 ** --t1 } hello world ${(~t1) ** t2 ** --t1 }`;
>`${(~t1) ** t2 ** --t1 } hello world ${(~t1) ** t2 ** --t1 }` : string
>(~t1) ** t2 ** --t1 : number
>(~t1) : number
>~t1 : number
>t1 : number
>t2 ** --t1 : number
>t2 : number
>--t1 : number
>t1 : number
>(~t1) ** t2 ** --t1 : number
>(~t1) : number
>~t1 : number
>t1 : number
>t2 ** --t1 : number
>t2 : number
>--t1 : number
>t1 : number
`${typeof (t1 ** t2 ** t1)} hello world ${typeof (t1 ** t2 ** t1)}`;
>`${typeof (t1 ** t2 ** t1)} hello world ${typeof (t1 ** t2 ** t1)}` : string
>typeof (t1 ** t2 ** t1) : string
>(t1 ** t2 ** t1) : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
>typeof (t1 ** t2 ** t1) : string
>(t1 ** t2 ** t1) : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
// With templateHead
`hello ${(-t1) ** t2 - t1}`;
>`hello ${(-t1) ** t2 - t1}` : string
>(-t1) ** t2 - t1 : number
>(-t1) ** t2 : number
>(-t1) : number
>-t1 : number
>t1 : number
>t2 : number
>t1 : number
`hello ${(-++t1) ** t2 - t1}`;
>`hello ${(-++t1) ** t2 - t1}` : string
>(-++t1) ** t2 - t1 : number
>(-++t1) ** t2 : number
>(-++t1) : number
>-++t1 : number
>++t1 : number
>t1 : number
>t2 : number
>t1 : number
`hello ${(-t1++) ** t2 - t1}`;
>`hello ${(-t1++) ** t2 - t1}` : string
>(-t1++) ** t2 - t1 : number
>(-t1++) ** t2 : number
>(-t1++) : number
>-t1++ : number
>t1++ : number
>t1 : number
>t2 : number
>t1 : number
`hello ${(~t1) ** t2 ** --t1 }`;
>`hello ${(~t1) ** t2 ** --t1 }` : string
>(~t1) ** t2 ** --t1 : number
>(~t1) : number
>~t1 : number
>t1 : number
>t2 ** --t1 : number
>t2 : number
>--t1 : number
>t1 : number
`hello ${typeof (t1 ** t2 ** t1)}`;
>`hello ${typeof (t1 ** t2 ** t1)}` : string
>typeof (t1 ** t2 ** t1) : string
>(t1 ** t2 ** t1) : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
@@ -0,0 +1,53 @@
//// [emitExponentiationOperatorInTemplateString1.ts]
var t1 = 10;
var t2 = 10;
var s;
// TempateHead & TemplateTail are empty
`${t1 ** t2}`;
`${t1 ** t2 ** t1}`;
`${t1 + t2 ** t1}`;
`${t1 ** t2 + t1}`;
`${t1 + t2 ** t2 + t1 }`;
`${typeof (t1 ** t2 ** t1) }`;
`${1 + typeof (t1 ** t2 ** t1) }`;
`${t1 ** t2}${t1 ** t2}`;
`${t1 ** t2 ** t1}${t1 ** t2 ** t1}`;
`${t1 + t2 ** t1}${t1 + t2 ** t1}`;
`${t1 ** t2 + t1}${t1 ** t2 + t1}`;
`${t1 + t2 ** t2 + t1}${t1 + t2 ** t2 + t1}`;
`${typeof (t1 ** t2 ** t1)}${typeof (t1 ** t2 ** t1)}`;
`${t1 ** t2} hello world ${t1 ** t2}`;
`${t1 ** t2 ** t1} hello world ${t1 ** t2 ** t1}`;
`${t1 + t2 ** t1} hello world ${t1 + t2 ** t1}`;
`${t1 ** t2 + t1} hello world ${t1 ** t2 + t1}`;
`${t1 + t2 ** t2 + t1} hello world ${t1 + t2 ** t2 + t1}`;
`${typeof (t1 ** t2 ** t1) } hello world ${typeof (t1 ** t2 ** t1) }`;
//// [emitExponentiationOperatorInTemplateString1.js]
var t1 = 10;
var t2 = 10;
var s;
// TempateHead & TemplateTail are empty
"" + (Math.pow(t1, t2));
"" + (Math.pow(t1, Math.pow(t2, t1)));
"" + (t1 + Math.pow(t2, t1));
"" + (Math.pow(t1, t2) + t1);
"" + (t1 + Math.pow(t2, t2) + t1);
"" + typeof (Math.pow(t1, Math.pow(t2, t1)));
"" + (1 + typeof (Math.pow(t1, Math.pow(t2, t1))));
"" + (Math.pow(t1, t2)) + (Math.pow(t1, t2));
"" + (Math.pow(t1, Math.pow(t2, t1))) + (Math.pow(t1, Math.pow(t2, t1)));
"" + (t1 + Math.pow(t2, t1)) + (t1 + Math.pow(t2, t1));
"" + (Math.pow(t1, t2) + t1) + (Math.pow(t1, t2) + t1);
"" + (t1 + Math.pow(t2, t2) + t1) + (t1 + Math.pow(t2, t2) + t1);
"" + typeof (Math.pow(t1, Math.pow(t2, t1))) + typeof (Math.pow(t1, Math.pow(t2, t1)));
(Math.pow(t1, t2)) + " hello world " + (Math.pow(t1, t2));
(Math.pow(t1, Math.pow(t2, t1))) + " hello world " + (Math.pow(t1, Math.pow(t2, t1)));
(t1 + Math.pow(t2, t1)) + " hello world " + (t1 + Math.pow(t2, t1));
(Math.pow(t1, t2) + t1) + " hello world " + (Math.pow(t1, t2) + t1);
(t1 + Math.pow(t2, t2) + t1) + " hello world " + (t1 + Math.pow(t2, t2) + t1);
typeof (Math.pow(t1, Math.pow(t2, t1))) + " hello world " + typeof (Math.pow(t1, Math.pow(t2, t1)));
@@ -0,0 +1,143 @@
=== tests/cases/conformance/es7/exponentiationOperator/emitExponentiationOperatorInTemplateString1.ts ===
var t1 = 10;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
var t2 = 10;
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1.ts, 2, 3))
var s;
>s : Symbol(s, Decl(emitExponentiationOperatorInTemplateString1.ts, 3, 3))
// TempateHead & TemplateTail are empty
`${t1 ** t2}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1.ts, 2, 3))
`${t1 ** t2 ** t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
`${t1 + t2 ** t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
`${t1 ** t2 + t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
`${t1 + t2 ** t2 + t1 }`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1.ts, 2, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
`${typeof (t1 ** t2 ** t1) }`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
`${1 + typeof (t1 ** t2 ** t1) }`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
`${t1 ** t2}${t1 ** t2}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1.ts, 2, 3))
`${t1 ** t2 ** t1}${t1 ** t2 ** t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
`${t1 + t2 ** t1}${t1 + t2 ** t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
`${t1 ** t2 + t1}${t1 ** t2 + t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
`${t1 + t2 ** t2 + t1}${t1 + t2 ** t2 + t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1.ts, 2, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1.ts, 2, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
`${typeof (t1 ** t2 ** t1)}${typeof (t1 ** t2 ** t1)}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
`${t1 ** t2} hello world ${t1 ** t2}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1.ts, 2, 3))
`${t1 ** t2 ** t1} hello world ${t1 ** t2 ** t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
`${t1 + t2 ** t1} hello world ${t1 + t2 ** t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
`${t1 ** t2 + t1} hello world ${t1 ** t2 + t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
`${t1 + t2 ** t2 + t1} hello world ${t1 + t2 ** t2 + t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1.ts, 2, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1.ts, 2, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
`${typeof (t1 ** t2 ** t1) } hello world ${typeof (t1 ** t2 ** t1) }`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1.ts, 1, 3))
@@ -0,0 +1,240 @@
=== tests/cases/conformance/es7/exponentiationOperator/emitExponentiationOperatorInTemplateString1.ts ===
var t1 = 10;
>t1 : number
>10 : number
var t2 = 10;
>t2 : number
>10 : number
var s;
>s : any
// TempateHead & TemplateTail are empty
`${t1 ** t2}`;
>`${t1 ** t2}` : string
>t1 ** t2 : number
>t1 : number
>t2 : number
`${t1 ** t2 ** t1}`;
>`${t1 ** t2 ** t1}` : string
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`${t1 + t2 ** t1}`;
>`${t1 + t2 ** t1}` : string
>t1 + t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`${t1 ** t2 + t1}`;
>`${t1 ** t2 + t1}` : string
>t1 ** t2 + t1 : number
>t1 ** t2 : number
>t1 : number
>t2 : number
>t1 : number
`${t1 + t2 ** t2 + t1 }`;
>`${t1 + t2 ** t2 + t1 }` : string
>t1 + t2 ** t2 + t1 : number
>t1 + t2 ** t2 : number
>t1 : number
>t2 ** t2 : number
>t2 : number
>t2 : number
>t1 : number
`${typeof (t1 ** t2 ** t1) }`;
>`${typeof (t1 ** t2 ** t1) }` : string
>typeof (t1 ** t2 ** t1) : string
>(t1 ** t2 ** t1) : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`${1 + typeof (t1 ** t2 ** t1) }`;
>`${1 + typeof (t1 ** t2 ** t1) }` : string
>1 + typeof (t1 ** t2 ** t1) : string
>1 : number
>typeof (t1 ** t2 ** t1) : string
>(t1 ** t2 ** t1) : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`${t1 ** t2}${t1 ** t2}`;
>`${t1 ** t2}${t1 ** t2}` : string
>t1 ** t2 : number
>t1 : number
>t2 : number
>t1 ** t2 : number
>t1 : number
>t2 : number
`${t1 ** t2 ** t1}${t1 ** t2 ** t1}`;
>`${t1 ** t2 ** t1}${t1 ** t2 ** t1}` : string
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`${t1 + t2 ** t1}${t1 + t2 ** t1}`;
>`${t1 + t2 ** t1}${t1 + t2 ** t1}` : string
>t1 + t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
>t1 + t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`${t1 ** t2 + t1}${t1 ** t2 + t1}`;
>`${t1 ** t2 + t1}${t1 ** t2 + t1}` : string
>t1 ** t2 + t1 : number
>t1 ** t2 : number
>t1 : number
>t2 : number
>t1 : number
>t1 ** t2 + t1 : number
>t1 ** t2 : number
>t1 : number
>t2 : number
>t1 : number
`${t1 + t2 ** t2 + t1}${t1 + t2 ** t2 + t1}`;
>`${t1 + t2 ** t2 + t1}${t1 + t2 ** t2 + t1}` : string
>t1 + t2 ** t2 + t1 : number
>t1 + t2 ** t2 : number
>t1 : number
>t2 ** t2 : number
>t2 : number
>t2 : number
>t1 : number
>t1 + t2 ** t2 + t1 : number
>t1 + t2 ** t2 : number
>t1 : number
>t2 ** t2 : number
>t2 : number
>t2 : number
>t1 : number
`${typeof (t1 ** t2 ** t1)}${typeof (t1 ** t2 ** t1)}`;
>`${typeof (t1 ** t2 ** t1)}${typeof (t1 ** t2 ** t1)}` : string
>typeof (t1 ** t2 ** t1) : string
>(t1 ** t2 ** t1) : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
>typeof (t1 ** t2 ** t1) : string
>(t1 ** t2 ** t1) : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`${t1 ** t2} hello world ${t1 ** t2}`;
>`${t1 ** t2} hello world ${t1 ** t2}` : string
>t1 ** t2 : number
>t1 : number
>t2 : number
>t1 ** t2 : number
>t1 : number
>t2 : number
`${t1 ** t2 ** t1} hello world ${t1 ** t2 ** t1}`;
>`${t1 ** t2 ** t1} hello world ${t1 ** t2 ** t1}` : string
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`${t1 + t2 ** t1} hello world ${t1 + t2 ** t1}`;
>`${t1 + t2 ** t1} hello world ${t1 + t2 ** t1}` : string
>t1 + t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
>t1 + t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`${t1 ** t2 + t1} hello world ${t1 ** t2 + t1}`;
>`${t1 ** t2 + t1} hello world ${t1 ** t2 + t1}` : string
>t1 ** t2 + t1 : number
>t1 ** t2 : number
>t1 : number
>t2 : number
>t1 : number
>t1 ** t2 + t1 : number
>t1 ** t2 : number
>t1 : number
>t2 : number
>t1 : number
`${t1 + t2 ** t2 + t1} hello world ${t1 + t2 ** t2 + t1}`;
>`${t1 + t2 ** t2 + t1} hello world ${t1 + t2 ** t2 + t1}` : string
>t1 + t2 ** t2 + t1 : number
>t1 + t2 ** t2 : number
>t1 : number
>t2 ** t2 : number
>t2 : number
>t2 : number
>t1 : number
>t1 + t2 ** t2 + t1 : number
>t1 + t2 ** t2 : number
>t1 : number
>t2 ** t2 : number
>t2 : number
>t2 : number
>t1 : number
`${typeof (t1 ** t2 ** t1) } hello world ${typeof (t1 ** t2 ** t1) }`;
>`${typeof (t1 ** t2 ** t1) } hello world ${typeof (t1 ** t2 ** t1) }` : string
>typeof (t1 ** t2 ** t1) : string
>(t1 ** t2 ** t1) : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
>typeof (t1 ** t2 ** t1) : string
>(t1 ** t2 ** t1) : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
@@ -0,0 +1,53 @@
//// [emitExponentiationOperatorInTemplateString1ES6.ts]
var t1 = 10;
var t2 = 10;
var s;
// TempateHead & TemplateTail are empty
`${t1 ** t2}`;
`${t1 ** t2 ** t1}`;
`${t1 + t2 ** t1}`;
`${t1 ** t2 + t1}`;
`${t1 + t2 ** t2 + t1 }`;
`${typeof (t1 ** t2 ** t1) }`;
`${1 + typeof (t1 ** t2 ** t1) }`;
`${t1 ** t2}${t1 ** t2}`;
`${t1 ** t2 ** t1}${t1 ** t2 ** t1}`;
`${t1 + t2 ** t1}${t1 + t2 ** t1}`;
`${t1 ** t2 + t1}${t1 ** t2 + t1}`;
`${t1 + t2 ** t2 + t1}${t1 + t2 ** t2 + t1}`;
`${typeof (t1 ** t2 ** t1)}${typeof (t1 ** t2 ** t1)}`;
`${t1 ** t2} hello world ${t1 ** t2}`;
`${t1 ** t2 ** t1} hello world ${t1 ** t2 ** t1}`;
`${t1 + t2 ** t1} hello world ${t1 + t2 ** t1}`;
`${t1 ** t2 + t1} hello world ${t1 ** t2 + t1}`;
`${t1 + t2 ** t2 + t1} hello world ${t1 + t2 ** t2 + t1}`;
`${typeof (t1 ** t2 ** t1) } hello world ${typeof (t1 ** t2 ** t1) }`;
//// [emitExponentiationOperatorInTemplateString1ES6.js]
var t1 = 10;
var t2 = 10;
var s;
// TempateHead & TemplateTail are empty
`${Math.pow(t1, t2)}`;
`${Math.pow(t1, Math.pow(t2, t1))}`;
`${t1 + Math.pow(t2, t1)}`;
`${Math.pow(t1, t2) + t1}`;
`${t1 + Math.pow(t2, t2) + t1}`;
`${typeof (Math.pow(t1, Math.pow(t2, t1)))}`;
`${1 + typeof (Math.pow(t1, Math.pow(t2, t1)))}`;
`${Math.pow(t1, t2)}${Math.pow(t1, t2)}`;
`${Math.pow(t1, Math.pow(t2, t1))}${Math.pow(t1, Math.pow(t2, t1))}`;
`${t1 + Math.pow(t2, t1)}${t1 + Math.pow(t2, t1)}`;
`${Math.pow(t1, t2) + t1}${Math.pow(t1, t2) + t1}`;
`${t1 + Math.pow(t2, t2) + t1}${t1 + Math.pow(t2, t2) + t1}`;
`${typeof (Math.pow(t1, Math.pow(t2, t1)))}${typeof (Math.pow(t1, Math.pow(t2, t1)))}`;
`${Math.pow(t1, t2)} hello world ${Math.pow(t1, t2)}`;
`${Math.pow(t1, Math.pow(t2, t1))} hello world ${Math.pow(t1, Math.pow(t2, t1))}`;
`${t1 + Math.pow(t2, t1)} hello world ${t1 + Math.pow(t2, t1)}`;
`${Math.pow(t1, t2) + t1} hello world ${Math.pow(t1, t2) + t1}`;
`${t1 + Math.pow(t2, t2) + t1} hello world ${t1 + Math.pow(t2, t2) + t1}`;
`${typeof (Math.pow(t1, Math.pow(t2, t1)))} hello world ${typeof (Math.pow(t1, Math.pow(t2, t1)))}`;
@@ -0,0 +1,143 @@
=== tests/cases/conformance/es7/exponentiationOperator/emitExponentiationOperatorInTemplateString1ES6.ts ===
var t1 = 10;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
var t2 = 10;
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 2, 3))
var s;
>s : Symbol(s, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 3, 3))
// TempateHead & TemplateTail are empty
`${t1 ** t2}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 2, 3))
`${t1 ** t2 ** t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
`${t1 + t2 ** t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
`${t1 ** t2 + t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
`${t1 + t2 ** t2 + t1 }`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 2, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
`${typeof (t1 ** t2 ** t1) }`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
`${1 + typeof (t1 ** t2 ** t1) }`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
`${t1 ** t2}${t1 ** t2}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 2, 3))
`${t1 ** t2 ** t1}${t1 ** t2 ** t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
`${t1 + t2 ** t1}${t1 + t2 ** t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
`${t1 ** t2 + t1}${t1 ** t2 + t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
`${t1 + t2 ** t2 + t1}${t1 + t2 ** t2 + t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 2, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 2, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
`${typeof (t1 ** t2 ** t1)}${typeof (t1 ** t2 ** t1)}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
`${t1 ** t2} hello world ${t1 ** t2}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 2, 3))
`${t1 ** t2 ** t1} hello world ${t1 ** t2 ** t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
`${t1 + t2 ** t1} hello world ${t1 + t2 ** t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
`${t1 ** t2 + t1} hello world ${t1 ** t2 + t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
`${t1 + t2 ** t2 + t1} hello world ${t1 + t2 ** t2 + t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 2, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 2, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
`${typeof (t1 ** t2 ** t1) } hello world ${typeof (t1 ** t2 ** t1) }`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString1ES6.ts, 1, 3))
@@ -0,0 +1,240 @@
=== tests/cases/conformance/es7/exponentiationOperator/emitExponentiationOperatorInTemplateString1ES6.ts ===
var t1 = 10;
>t1 : number
>10 : number
var t2 = 10;
>t2 : number
>10 : number
var s;
>s : any
// TempateHead & TemplateTail are empty
`${t1 ** t2}`;
>`${t1 ** t2}` : string
>t1 ** t2 : number
>t1 : number
>t2 : number
`${t1 ** t2 ** t1}`;
>`${t1 ** t2 ** t1}` : string
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`${t1 + t2 ** t1}`;
>`${t1 + t2 ** t1}` : string
>t1 + t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`${t1 ** t2 + t1}`;
>`${t1 ** t2 + t1}` : string
>t1 ** t2 + t1 : number
>t1 ** t2 : number
>t1 : number
>t2 : number
>t1 : number
`${t1 + t2 ** t2 + t1 }`;
>`${t1 + t2 ** t2 + t1 }` : string
>t1 + t2 ** t2 + t1 : number
>t1 + t2 ** t2 : number
>t1 : number
>t2 ** t2 : number
>t2 : number
>t2 : number
>t1 : number
`${typeof (t1 ** t2 ** t1) }`;
>`${typeof (t1 ** t2 ** t1) }` : string
>typeof (t1 ** t2 ** t1) : string
>(t1 ** t2 ** t1) : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`${1 + typeof (t1 ** t2 ** t1) }`;
>`${1 + typeof (t1 ** t2 ** t1) }` : string
>1 + typeof (t1 ** t2 ** t1) : string
>1 : number
>typeof (t1 ** t2 ** t1) : string
>(t1 ** t2 ** t1) : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`${t1 ** t2}${t1 ** t2}`;
>`${t1 ** t2}${t1 ** t2}` : string
>t1 ** t2 : number
>t1 : number
>t2 : number
>t1 ** t2 : number
>t1 : number
>t2 : number
`${t1 ** t2 ** t1}${t1 ** t2 ** t1}`;
>`${t1 ** t2 ** t1}${t1 ** t2 ** t1}` : string
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`${t1 + t2 ** t1}${t1 + t2 ** t1}`;
>`${t1 + t2 ** t1}${t1 + t2 ** t1}` : string
>t1 + t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
>t1 + t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`${t1 ** t2 + t1}${t1 ** t2 + t1}`;
>`${t1 ** t2 + t1}${t1 ** t2 + t1}` : string
>t1 ** t2 + t1 : number
>t1 ** t2 : number
>t1 : number
>t2 : number
>t1 : number
>t1 ** t2 + t1 : number
>t1 ** t2 : number
>t1 : number
>t2 : number
>t1 : number
`${t1 + t2 ** t2 + t1}${t1 + t2 ** t2 + t1}`;
>`${t1 + t2 ** t2 + t1}${t1 + t2 ** t2 + t1}` : string
>t1 + t2 ** t2 + t1 : number
>t1 + t2 ** t2 : number
>t1 : number
>t2 ** t2 : number
>t2 : number
>t2 : number
>t1 : number
>t1 + t2 ** t2 + t1 : number
>t1 + t2 ** t2 : number
>t1 : number
>t2 ** t2 : number
>t2 : number
>t2 : number
>t1 : number
`${typeof (t1 ** t2 ** t1)}${typeof (t1 ** t2 ** t1)}`;
>`${typeof (t1 ** t2 ** t1)}${typeof (t1 ** t2 ** t1)}` : string
>typeof (t1 ** t2 ** t1) : string
>(t1 ** t2 ** t1) : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
>typeof (t1 ** t2 ** t1) : string
>(t1 ** t2 ** t1) : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`${t1 ** t2} hello world ${t1 ** t2}`;
>`${t1 ** t2} hello world ${t1 ** t2}` : string
>t1 ** t2 : number
>t1 : number
>t2 : number
>t1 ** t2 : number
>t1 : number
>t2 : number
`${t1 ** t2 ** t1} hello world ${t1 ** t2 ** t1}`;
>`${t1 ** t2 ** t1} hello world ${t1 ** t2 ** t1}` : string
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`${t1 + t2 ** t1} hello world ${t1 + t2 ** t1}`;
>`${t1 + t2 ** t1} hello world ${t1 + t2 ** t1}` : string
>t1 + t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
>t1 + t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`${t1 ** t2 + t1} hello world ${t1 ** t2 + t1}`;
>`${t1 ** t2 + t1} hello world ${t1 ** t2 + t1}` : string
>t1 ** t2 + t1 : number
>t1 ** t2 : number
>t1 : number
>t2 : number
>t1 : number
>t1 ** t2 + t1 : number
>t1 ** t2 : number
>t1 : number
>t2 : number
>t1 : number
`${t1 + t2 ** t2 + t1} hello world ${t1 + t2 ** t2 + t1}`;
>`${t1 + t2 ** t2 + t1} hello world ${t1 + t2 ** t2 + t1}` : string
>t1 + t2 ** t2 + t1 : number
>t1 + t2 ** t2 : number
>t1 : number
>t2 ** t2 : number
>t2 : number
>t2 : number
>t1 : number
>t1 + t2 ** t2 + t1 : number
>t1 + t2 ** t2 : number
>t1 : number
>t2 ** t2 : number
>t2 : number
>t2 : number
>t1 : number
`${typeof (t1 ** t2 ** t1) } hello world ${typeof (t1 ** t2 ** t1) }`;
>`${typeof (t1 ** t2 ** t1) } hello world ${typeof (t1 ** t2 ** t1) }` : string
>typeof (t1 ** t2 ** t1) : string
>(t1 ** t2 ** t1) : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
>typeof (t1 ** t2 ** t1) : string
>(t1 ** t2 ** t1) : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
@@ -0,0 +1,53 @@
//// [emitExponentiationOperatorInTemplateString2.ts]
var t1 = 10;
var t2 = 10;
var s;
// With templateHead
`hello ${t1 ** t2}`;
`hello ${t1 ** t2 ** t1}`;
`hello ${t1 + t2 ** t1}`;
`hello ${t1 ** t2 + t1}`;
`hello ${t1 + t2 ** t2 + t1 }`;
`hello ${typeof (t1 ** t2 ** t1) }`;
`hello ${1 + typeof (t1 ** t2 ** t1) }`;
`hello ${t1 ** t2}${t1 ** t2}`;
`hello ${t1 ** t2 ** t1}${t1 ** t2 ** t1}`;
`hello ${t1 + t2 ** t1}${t1 + t2 ** t1}`;
`hello ${t1 ** t2 + t1}${t1 ** t2 + t1}`;
`hello ${t1 + t2 ** t2 + t1}${t1 + t2 ** t2 + t1}`;
`hello ${typeof (t1 ** t2 ** t1) }${typeof (t1 ** t2 ** t1) }`;
`hello ${t1 ** t2} hello world ${t1 ** t2}`;
`hello ${t1 ** t2 ** t1} hello world ${t1 ** t2 ** t1}`;
`hello ${t1 + t2 ** t1} hello world ${t1 + t2 ** t1}`;
`hello ${t1 ** t2 + t1} hello world ${t1 ** t2 + t1}`;
`hello ${t1 + t2 ** t2 + t1} hello world ${t1 + t2 ** t2 + t1}`;
`hello ${typeof (t1 ** t2 ** t1) } hello world ${typeof (t1 ** t2 ** t1) }`;
//// [emitExponentiationOperatorInTemplateString2.js]
var t1 = 10;
var t2 = 10;
var s;
// With templateHead
"hello " + (Math.pow(t1, t2));
"hello " + (Math.pow(t1, Math.pow(t2, t1)));
"hello " + (t1 + Math.pow(t2, t1));
"hello " + (Math.pow(t1, t2) + t1);
"hello " + (t1 + Math.pow(t2, t2) + t1);
"hello " + typeof (Math.pow(t1, Math.pow(t2, t1)));
"hello " + (1 + typeof (Math.pow(t1, Math.pow(t2, t1))));
"hello " + (Math.pow(t1, t2)) + (Math.pow(t1, t2));
"hello " + (Math.pow(t1, Math.pow(t2, t1))) + (Math.pow(t1, Math.pow(t2, t1)));
"hello " + (t1 + Math.pow(t2, t1)) + (t1 + Math.pow(t2, t1));
"hello " + (Math.pow(t1, t2) + t1) + (Math.pow(t1, t2) + t1);
"hello " + (t1 + Math.pow(t2, t2) + t1) + (t1 + Math.pow(t2, t2) + t1);
"hello " + typeof (Math.pow(t1, Math.pow(t2, t1))) + typeof (Math.pow(t1, Math.pow(t2, t1)));
"hello " + (Math.pow(t1, t2)) + " hello world " + (Math.pow(t1, t2));
"hello " + (Math.pow(t1, Math.pow(t2, t1))) + " hello world " + (Math.pow(t1, Math.pow(t2, t1)));
"hello " + (t1 + Math.pow(t2, t1)) + " hello world " + (t1 + Math.pow(t2, t1));
"hello " + (Math.pow(t1, t2) + t1) + " hello world " + (Math.pow(t1, t2) + t1);
"hello " + (t1 + Math.pow(t2, t2) + t1) + " hello world " + (t1 + Math.pow(t2, t2) + t1);
"hello " + typeof (Math.pow(t1, Math.pow(t2, t1))) + " hello world " + typeof (Math.pow(t1, Math.pow(t2, t1)));
@@ -0,0 +1,143 @@
=== tests/cases/conformance/es7/exponentiationOperator/emitExponentiationOperatorInTemplateString2.ts ===
var t1 = 10;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
var t2 = 10;
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2.ts, 2, 3))
var s;
>s : Symbol(s, Decl(emitExponentiationOperatorInTemplateString2.ts, 3, 3))
// With templateHead
`hello ${t1 ** t2}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2.ts, 2, 3))
`hello ${t1 ** t2 ** t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
`hello ${t1 + t2 ** t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
`hello ${t1 ** t2 + t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
`hello ${t1 + t2 ** t2 + t1 }`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2.ts, 2, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
`hello ${typeof (t1 ** t2 ** t1) }`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
`hello ${1 + typeof (t1 ** t2 ** t1) }`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
`hello ${t1 ** t2}${t1 ** t2}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2.ts, 2, 3))
`hello ${t1 ** t2 ** t1}${t1 ** t2 ** t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
`hello ${t1 + t2 ** t1}${t1 + t2 ** t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
`hello ${t1 ** t2 + t1}${t1 ** t2 + t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
`hello ${t1 + t2 ** t2 + t1}${t1 + t2 ** t2 + t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2.ts, 2, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2.ts, 2, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
`hello ${typeof (t1 ** t2 ** t1) }${typeof (t1 ** t2 ** t1) }`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
`hello ${t1 ** t2} hello world ${t1 ** t2}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2.ts, 2, 3))
`hello ${t1 ** t2 ** t1} hello world ${t1 ** t2 ** t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
`hello ${t1 + t2 ** t1} hello world ${t1 + t2 ** t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
`hello ${t1 ** t2 + t1} hello world ${t1 ** t2 + t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
`hello ${t1 + t2 ** t2 + t1} hello world ${t1 + t2 ** t2 + t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2.ts, 2, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2.ts, 2, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
`hello ${typeof (t1 ** t2 ** t1) } hello world ${typeof (t1 ** t2 ** t1) }`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2.ts, 1, 3))
@@ -0,0 +1,240 @@
=== tests/cases/conformance/es7/exponentiationOperator/emitExponentiationOperatorInTemplateString2.ts ===
var t1 = 10;
>t1 : number
>10 : number
var t2 = 10;
>t2 : number
>10 : number
var s;
>s : any
// With templateHead
`hello ${t1 ** t2}`;
>`hello ${t1 ** t2}` : string
>t1 ** t2 : number
>t1 : number
>t2 : number
`hello ${t1 ** t2 ** t1}`;
>`hello ${t1 ** t2 ** t1}` : string
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`hello ${t1 + t2 ** t1}`;
>`hello ${t1 + t2 ** t1}` : string
>t1 + t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`hello ${t1 ** t2 + t1}`;
>`hello ${t1 ** t2 + t1}` : string
>t1 ** t2 + t1 : number
>t1 ** t2 : number
>t1 : number
>t2 : number
>t1 : number
`hello ${t1 + t2 ** t2 + t1 }`;
>`hello ${t1 + t2 ** t2 + t1 }` : string
>t1 + t2 ** t2 + t1 : number
>t1 + t2 ** t2 : number
>t1 : number
>t2 ** t2 : number
>t2 : number
>t2 : number
>t1 : number
`hello ${typeof (t1 ** t2 ** t1) }`;
>`hello ${typeof (t1 ** t2 ** t1) }` : string
>typeof (t1 ** t2 ** t1) : string
>(t1 ** t2 ** t1) : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`hello ${1 + typeof (t1 ** t2 ** t1) }`;
>`hello ${1 + typeof (t1 ** t2 ** t1) }` : string
>1 + typeof (t1 ** t2 ** t1) : string
>1 : number
>typeof (t1 ** t2 ** t1) : string
>(t1 ** t2 ** t1) : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`hello ${t1 ** t2}${t1 ** t2}`;
>`hello ${t1 ** t2}${t1 ** t2}` : string
>t1 ** t2 : number
>t1 : number
>t2 : number
>t1 ** t2 : number
>t1 : number
>t2 : number
`hello ${t1 ** t2 ** t1}${t1 ** t2 ** t1}`;
>`hello ${t1 ** t2 ** t1}${t1 ** t2 ** t1}` : string
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`hello ${t1 + t2 ** t1}${t1 + t2 ** t1}`;
>`hello ${t1 + t2 ** t1}${t1 + t2 ** t1}` : string
>t1 + t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
>t1 + t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`hello ${t1 ** t2 + t1}${t1 ** t2 + t1}`;
>`hello ${t1 ** t2 + t1}${t1 ** t2 + t1}` : string
>t1 ** t2 + t1 : number
>t1 ** t2 : number
>t1 : number
>t2 : number
>t1 : number
>t1 ** t2 + t1 : number
>t1 ** t2 : number
>t1 : number
>t2 : number
>t1 : number
`hello ${t1 + t2 ** t2 + t1}${t1 + t2 ** t2 + t1}`;
>`hello ${t1 + t2 ** t2 + t1}${t1 + t2 ** t2 + t1}` : string
>t1 + t2 ** t2 + t1 : number
>t1 + t2 ** t2 : number
>t1 : number
>t2 ** t2 : number
>t2 : number
>t2 : number
>t1 : number
>t1 + t2 ** t2 + t1 : number
>t1 + t2 ** t2 : number
>t1 : number
>t2 ** t2 : number
>t2 : number
>t2 : number
>t1 : number
`hello ${typeof (t1 ** t2 ** t1) }${typeof (t1 ** t2 ** t1) }`;
>`hello ${typeof (t1 ** t2 ** t1) }${typeof (t1 ** t2 ** t1) }` : string
>typeof (t1 ** t2 ** t1) : string
>(t1 ** t2 ** t1) : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
>typeof (t1 ** t2 ** t1) : string
>(t1 ** t2 ** t1) : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`hello ${t1 ** t2} hello world ${t1 ** t2}`;
>`hello ${t1 ** t2} hello world ${t1 ** t2}` : string
>t1 ** t2 : number
>t1 : number
>t2 : number
>t1 ** t2 : number
>t1 : number
>t2 : number
`hello ${t1 ** t2 ** t1} hello world ${t1 ** t2 ** t1}`;
>`hello ${t1 ** t2 ** t1} hello world ${t1 ** t2 ** t1}` : string
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`hello ${t1 + t2 ** t1} hello world ${t1 + t2 ** t1}`;
>`hello ${t1 + t2 ** t1} hello world ${t1 + t2 ** t1}` : string
>t1 + t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
>t1 + t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`hello ${t1 ** t2 + t1} hello world ${t1 ** t2 + t1}`;
>`hello ${t1 ** t2 + t1} hello world ${t1 ** t2 + t1}` : string
>t1 ** t2 + t1 : number
>t1 ** t2 : number
>t1 : number
>t2 : number
>t1 : number
>t1 ** t2 + t1 : number
>t1 ** t2 : number
>t1 : number
>t2 : number
>t1 : number
`hello ${t1 + t2 ** t2 + t1} hello world ${t1 + t2 ** t2 + t1}`;
>`hello ${t1 + t2 ** t2 + t1} hello world ${t1 + t2 ** t2 + t1}` : string
>t1 + t2 ** t2 + t1 : number
>t1 + t2 ** t2 : number
>t1 : number
>t2 ** t2 : number
>t2 : number
>t2 : number
>t1 : number
>t1 + t2 ** t2 + t1 : number
>t1 + t2 ** t2 : number
>t1 : number
>t2 ** t2 : number
>t2 : number
>t2 : number
>t1 : number
`hello ${typeof (t1 ** t2 ** t1) } hello world ${typeof (t1 ** t2 ** t1) }`;
>`hello ${typeof (t1 ** t2 ** t1) } hello world ${typeof (t1 ** t2 ** t1) }` : string
>typeof (t1 ** t2 ** t1) : string
>(t1 ** t2 ** t1) : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
>typeof (t1 ** t2 ** t1) : string
>(t1 ** t2 ** t1) : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
@@ -0,0 +1,53 @@
//// [emitExponentiationOperatorInTemplateString2ES6.ts]
var t1 = 10;
var t2 = 10;
var s;
// With templateHead
`hello ${t1 ** t2}`;
`hello ${t1 ** t2 ** t1}`;
`hello ${t1 + t2 ** t1}`;
`hello ${t1 ** t2 + t1}`;
`hello ${t1 + t2 ** t2 + t1 }`;
`hello ${typeof (t1 ** t2 ** t1) }`;
`hello ${1 + typeof (t1 ** t2 ** t1) }`;
`hello ${t1 ** t2}${t1 ** t2}`;
`hello ${t1 ** t2 ** t1}${t1 ** t2 ** t1}`;
`hello ${t1 + t2 ** t1}${t1 + t2 ** t1}`;
`hello ${t1 ** t2 + t1}${t1 ** t2 + t1}`;
`hello ${t1 + t2 ** t2 + t1}${t1 + t2 ** t2 + t1}`;
`hello ${typeof (t1 ** t2 ** t1) }${typeof (t1 ** t2 ** t1) }`;
`hello ${t1 ** t2} hello world ${t1 ** t2}`;
`hello ${t1 ** t2 ** t1} hello world ${t1 ** t2 ** t1}`;
`hello ${t1 + t2 ** t1} hello world ${t1 + t2 ** t1}`;
`hello ${t1 ** t2 + t1} hello world ${t1 ** t2 + t1}`;
`hello ${t1 + t2 ** t2 + t1} hello world ${t1 + t2 ** t2 + t1}`;
`hello ${typeof (t1 ** t2 ** t1) } hello world ${typeof (t1 ** t2 ** t1) }`;
//// [emitExponentiationOperatorInTemplateString2ES6.js]
var t1 = 10;
var t2 = 10;
var s;
// With templateHead
`hello ${Math.pow(t1, t2)}`;
`hello ${Math.pow(t1, Math.pow(t2, t1))}`;
`hello ${t1 + Math.pow(t2, t1)}`;
`hello ${Math.pow(t1, t2) + t1}`;
`hello ${t1 + Math.pow(t2, t2) + t1}`;
`hello ${typeof (Math.pow(t1, Math.pow(t2, t1)))}`;
`hello ${1 + typeof (Math.pow(t1, Math.pow(t2, t1)))}`;
`hello ${Math.pow(t1, t2)}${Math.pow(t1, t2)}`;
`hello ${Math.pow(t1, Math.pow(t2, t1))}${Math.pow(t1, Math.pow(t2, t1))}`;
`hello ${t1 + Math.pow(t2, t1)}${t1 + Math.pow(t2, t1)}`;
`hello ${Math.pow(t1, t2) + t1}${Math.pow(t1, t2) + t1}`;
`hello ${t1 + Math.pow(t2, t2) + t1}${t1 + Math.pow(t2, t2) + t1}`;
`hello ${typeof (Math.pow(t1, Math.pow(t2, t1)))}${typeof (Math.pow(t1, Math.pow(t2, t1)))}`;
`hello ${Math.pow(t1, t2)} hello world ${Math.pow(t1, t2)}`;
`hello ${Math.pow(t1, Math.pow(t2, t1))} hello world ${Math.pow(t1, Math.pow(t2, t1))}`;
`hello ${t1 + Math.pow(t2, t1)} hello world ${t1 + Math.pow(t2, t1)}`;
`hello ${Math.pow(t1, t2) + t1} hello world ${Math.pow(t1, t2) + t1}`;
`hello ${t1 + Math.pow(t2, t2) + t1} hello world ${t1 + Math.pow(t2, t2) + t1}`;
`hello ${typeof (Math.pow(t1, Math.pow(t2, t1)))} hello world ${typeof (Math.pow(t1, Math.pow(t2, t1)))}`;
@@ -0,0 +1,143 @@
=== tests/cases/conformance/es7/exponentiationOperator/emitExponentiationOperatorInTemplateString2ES6.ts ===
var t1 = 10;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
var t2 = 10;
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 2, 3))
var s;
>s : Symbol(s, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 3, 3))
// With templateHead
`hello ${t1 ** t2}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 2, 3))
`hello ${t1 ** t2 ** t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
`hello ${t1 + t2 ** t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
`hello ${t1 ** t2 + t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
`hello ${t1 + t2 ** t2 + t1 }`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 2, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
`hello ${typeof (t1 ** t2 ** t1) }`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
`hello ${1 + typeof (t1 ** t2 ** t1) }`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
`hello ${t1 ** t2}${t1 ** t2}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 2, 3))
`hello ${t1 ** t2 ** t1}${t1 ** t2 ** t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
`hello ${t1 + t2 ** t1}${t1 + t2 ** t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
`hello ${t1 ** t2 + t1}${t1 ** t2 + t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
`hello ${t1 + t2 ** t2 + t1}${t1 + t2 ** t2 + t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 2, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 2, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
`hello ${typeof (t1 ** t2 ** t1) }${typeof (t1 ** t2 ** t1) }`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
`hello ${t1 ** t2} hello world ${t1 ** t2}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 2, 3))
`hello ${t1 ** t2 ** t1} hello world ${t1 ** t2 ** t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
`hello ${t1 + t2 ** t1} hello world ${t1 + t2 ** t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
`hello ${t1 ** t2 + t1} hello world ${t1 ** t2 + t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
`hello ${t1 + t2 ** t2 + t1} hello world ${t1 + t2 ** t2 + t1}`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 2, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 2, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
`hello ${typeof (t1 ** t2 ** t1) } hello world ${typeof (t1 ** t2 ** t1) }`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString2ES6.ts, 1, 3))
@@ -0,0 +1,240 @@
=== tests/cases/conformance/es7/exponentiationOperator/emitExponentiationOperatorInTemplateString2ES6.ts ===
var t1 = 10;
>t1 : number
>10 : number
var t2 = 10;
>t2 : number
>10 : number
var s;
>s : any
// With templateHead
`hello ${t1 ** t2}`;
>`hello ${t1 ** t2}` : string
>t1 ** t2 : number
>t1 : number
>t2 : number
`hello ${t1 ** t2 ** t1}`;
>`hello ${t1 ** t2 ** t1}` : string
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`hello ${t1 + t2 ** t1}`;
>`hello ${t1 + t2 ** t1}` : string
>t1 + t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`hello ${t1 ** t2 + t1}`;
>`hello ${t1 ** t2 + t1}` : string
>t1 ** t2 + t1 : number
>t1 ** t2 : number
>t1 : number
>t2 : number
>t1 : number
`hello ${t1 + t2 ** t2 + t1 }`;
>`hello ${t1 + t2 ** t2 + t1 }` : string
>t1 + t2 ** t2 + t1 : number
>t1 + t2 ** t2 : number
>t1 : number
>t2 ** t2 : number
>t2 : number
>t2 : number
>t1 : number
`hello ${typeof (t1 ** t2 ** t1) }`;
>`hello ${typeof (t1 ** t2 ** t1) }` : string
>typeof (t1 ** t2 ** t1) : string
>(t1 ** t2 ** t1) : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`hello ${1 + typeof (t1 ** t2 ** t1) }`;
>`hello ${1 + typeof (t1 ** t2 ** t1) }` : string
>1 + typeof (t1 ** t2 ** t1) : string
>1 : number
>typeof (t1 ** t2 ** t1) : string
>(t1 ** t2 ** t1) : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`hello ${t1 ** t2}${t1 ** t2}`;
>`hello ${t1 ** t2}${t1 ** t2}` : string
>t1 ** t2 : number
>t1 : number
>t2 : number
>t1 ** t2 : number
>t1 : number
>t2 : number
`hello ${t1 ** t2 ** t1}${t1 ** t2 ** t1}`;
>`hello ${t1 ** t2 ** t1}${t1 ** t2 ** t1}` : string
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`hello ${t1 + t2 ** t1}${t1 + t2 ** t1}`;
>`hello ${t1 + t2 ** t1}${t1 + t2 ** t1}` : string
>t1 + t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
>t1 + t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`hello ${t1 ** t2 + t1}${t1 ** t2 + t1}`;
>`hello ${t1 ** t2 + t1}${t1 ** t2 + t1}` : string
>t1 ** t2 + t1 : number
>t1 ** t2 : number
>t1 : number
>t2 : number
>t1 : number
>t1 ** t2 + t1 : number
>t1 ** t2 : number
>t1 : number
>t2 : number
>t1 : number
`hello ${t1 + t2 ** t2 + t1}${t1 + t2 ** t2 + t1}`;
>`hello ${t1 + t2 ** t2 + t1}${t1 + t2 ** t2 + t1}` : string
>t1 + t2 ** t2 + t1 : number
>t1 + t2 ** t2 : number
>t1 : number
>t2 ** t2 : number
>t2 : number
>t2 : number
>t1 : number
>t1 + t2 ** t2 + t1 : number
>t1 + t2 ** t2 : number
>t1 : number
>t2 ** t2 : number
>t2 : number
>t2 : number
>t1 : number
`hello ${typeof (t1 ** t2 ** t1) }${typeof (t1 ** t2 ** t1) }`;
>`hello ${typeof (t1 ** t2 ** t1) }${typeof (t1 ** t2 ** t1) }` : string
>typeof (t1 ** t2 ** t1) : string
>(t1 ** t2 ** t1) : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
>typeof (t1 ** t2 ** t1) : string
>(t1 ** t2 ** t1) : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`hello ${t1 ** t2} hello world ${t1 ** t2}`;
>`hello ${t1 ** t2} hello world ${t1 ** t2}` : string
>t1 ** t2 : number
>t1 : number
>t2 : number
>t1 ** t2 : number
>t1 : number
>t2 : number
`hello ${t1 ** t2 ** t1} hello world ${t1 ** t2 ** t1}`;
>`hello ${t1 ** t2 ** t1} hello world ${t1 ** t2 ** t1}` : string
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`hello ${t1 + t2 ** t1} hello world ${t1 + t2 ** t1}`;
>`hello ${t1 + t2 ** t1} hello world ${t1 + t2 ** t1}` : string
>t1 + t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
>t1 + t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`hello ${t1 ** t2 + t1} hello world ${t1 ** t2 + t1}`;
>`hello ${t1 ** t2 + t1} hello world ${t1 ** t2 + t1}` : string
>t1 ** t2 + t1 : number
>t1 ** t2 : number
>t1 : number
>t2 : number
>t1 : number
>t1 ** t2 + t1 : number
>t1 ** t2 : number
>t1 : number
>t2 : number
>t1 : number
`hello ${t1 + t2 ** t2 + t1} hello world ${t1 + t2 ** t2 + t1}`;
>`hello ${t1 + t2 ** t2 + t1} hello world ${t1 + t2 ** t2 + t1}` : string
>t1 + t2 ** t2 + t1 : number
>t1 + t2 ** t2 : number
>t1 : number
>t2 ** t2 : number
>t2 : number
>t2 : number
>t1 : number
>t1 + t2 ** t2 + t1 : number
>t1 + t2 ** t2 : number
>t1 : number
>t2 ** t2 : number
>t2 : number
>t2 : number
>t1 : number
`hello ${typeof (t1 ** t2 ** t1) } hello world ${typeof (t1 ** t2 ** t1) }`;
>`hello ${typeof (t1 ** t2 ** t1) } hello world ${typeof (t1 ** t2 ** t1) }` : string
>typeof (t1 ** t2 ** t1) : string
>(t1 ** t2 ** t1) : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
>typeof (t1 ** t2 ** t1) : string
>(t1 ** t2 ** t1) : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
@@ -0,0 +1,54 @@
//// [emitExponentiationOperatorInTemplateString3.ts]
var t1 = 10;
var t2 = 10;
var s;
// With TemplateTail
`${t1 ** t2} world`;
`${t1 ** t2 ** t1} world`;
`${t1 + t2 ** t1} world`;
`${t1 ** t2 + t1} world`;
`${t1 + t2 ** t2 + t1 } world`;
`${typeof (t1 ** t2 ** t1) } world`;
`${1 + typeof (t1 ** t2 ** t1) } world`;
`${t1 ** t2}${t1 ** t2} world`;
`${t1 ** t2 ** t1}${t1 ** t2 ** t1} world`;
`${t1 + t2 ** t1}${t1 + t2 ** t1} world`;
`${t1 ** t2 + t1}${t1 ** t2 + t1} world`;
`${t1 + t2 ** t2 + t1}${t1 + t2 ** t2 + t1} world`;
`${typeof (t1 ** t2 ** t1) }${typeof (t1 ** t2 ** t1) } world`;
`${t1 ** t2} hello world ${t1 ** t2} !!`;
`${t1 ** t2 ** t1} hello world ${t1 ** t2 ** t1} !!`;
`${t1 + t2 ** t1} hello world ${t1 + t2 ** t1} !!`;
`${t1 ** t2 + t1} hello world ${t1 ** t2 + t1} !!`;
`${t1 + t2 ** t2 + t1} hello world ${t1 + t2 ** t2 + t1} !!`;
`${typeof (t1 ** t2 ** t1) } hello world ${typeof (t1 ** t2 ** t1)} !!`;
//// [emitExponentiationOperatorInTemplateString3.js]
var t1 = 10;
var t2 = 10;
var s;
// With TemplateTail
(Math.pow(t1, t2)) + " world";
(Math.pow(t1, Math.pow(t2, t1))) + " world";
(t1 + Math.pow(t2, t1)) + " world";
(Math.pow(t1, t2) + t1) + " world";
(t1 + Math.pow(t2, t2) + t1) + " world";
typeof (Math.pow(t1, Math.pow(t2, t1))) + " world";
(1 + typeof (Math.pow(t1, Math.pow(t2, t1)))) + " world";
"" + (Math.pow(t1, t2)) + (Math.pow(t1, t2)) + " world";
"" + (Math.pow(t1, Math.pow(t2, t1))) + (Math.pow(t1, Math.pow(t2, t1))) + " world";
"" + (t1 + Math.pow(t2, t1)) + (t1 + Math.pow(t2, t1)) + " world";
"" + (Math.pow(t1, t2) + t1) + (Math.pow(t1, t2) + t1) + " world";
"" + (t1 + Math.pow(t2, t2) + t1) + (t1 + Math.pow(t2, t2) + t1) + " world";
"" + typeof (Math.pow(t1, Math.pow(t2, t1))) + typeof (Math.pow(t1, Math.pow(t2, t1))) + " world";
(Math.pow(t1, t2)) + " hello world " + (Math.pow(t1, t2)) + " !!";
(Math.pow(t1, Math.pow(t2, t1))) + " hello world " + (Math.pow(t1, Math.pow(t2, t1))) + " !!";
(t1 + Math.pow(t2, t1)) + " hello world " + (t1 + Math.pow(t2, t1)) + " !!";
(Math.pow(t1, t2) + t1) + " hello world " + (Math.pow(t1, t2) + t1) + " !!";
(t1 + Math.pow(t2, t2) + t1) + " hello world " + (t1 + Math.pow(t2, t2) + t1) + " !!";
typeof (Math.pow(t1, Math.pow(t2, t1))) + " hello world " + typeof (Math.pow(t1, Math.pow(t2, t1))) + " !!";
@@ -0,0 +1,143 @@
=== tests/cases/conformance/es7/exponentiationOperator/emitExponentiationOperatorInTemplateString3.ts ===
var t1 = 10;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
var t2 = 10;
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3.ts, 2, 3))
var s;
>s : Symbol(s, Decl(emitExponentiationOperatorInTemplateString3.ts, 3, 3))
// With TemplateTail
`${t1 ** t2} world`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3.ts, 2, 3))
`${t1 ** t2 ** t1} world`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
`${t1 + t2 ** t1} world`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
`${t1 ** t2 + t1} world`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
`${t1 + t2 ** t2 + t1 } world`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3.ts, 2, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
`${typeof (t1 ** t2 ** t1) } world`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
`${1 + typeof (t1 ** t2 ** t1) } world`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
`${t1 ** t2}${t1 ** t2} world`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3.ts, 2, 3))
`${t1 ** t2 ** t1}${t1 ** t2 ** t1} world`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
`${t1 + t2 ** t1}${t1 + t2 ** t1} world`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
`${t1 ** t2 + t1}${t1 ** t2 + t1} world`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
`${t1 + t2 ** t2 + t1}${t1 + t2 ** t2 + t1} world`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3.ts, 2, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3.ts, 2, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
`${typeof (t1 ** t2 ** t1) }${typeof (t1 ** t2 ** t1) } world`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
`${t1 ** t2} hello world ${t1 ** t2} !!`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3.ts, 2, 3))
`${t1 ** t2 ** t1} hello world ${t1 ** t2 ** t1} !!`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
`${t1 + t2 ** t1} hello world ${t1 + t2 ** t1} !!`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
`${t1 ** t2 + t1} hello world ${t1 ** t2 + t1} !!`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
`${t1 + t2 ** t2 + t1} hello world ${t1 + t2 ** t2 + t1} !!`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3.ts, 2, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3.ts, 2, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
`${typeof (t1 ** t2 ** t1) } hello world ${typeof (t1 ** t2 ** t1)} !!`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3.ts, 1, 3))
@@ -0,0 +1,240 @@
=== tests/cases/conformance/es7/exponentiationOperator/emitExponentiationOperatorInTemplateString3.ts ===
var t1 = 10;
>t1 : number
>10 : number
var t2 = 10;
>t2 : number
>10 : number
var s;
>s : any
// With TemplateTail
`${t1 ** t2} world`;
>`${t1 ** t2} world` : string
>t1 ** t2 : number
>t1 : number
>t2 : number
`${t1 ** t2 ** t1} world`;
>`${t1 ** t2 ** t1} world` : string
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`${t1 + t2 ** t1} world`;
>`${t1 + t2 ** t1} world` : string
>t1 + t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`${t1 ** t2 + t1} world`;
>`${t1 ** t2 + t1} world` : string
>t1 ** t2 + t1 : number
>t1 ** t2 : number
>t1 : number
>t2 : number
>t1 : number
`${t1 + t2 ** t2 + t1 } world`;
>`${t1 + t2 ** t2 + t1 } world` : string
>t1 + t2 ** t2 + t1 : number
>t1 + t2 ** t2 : number
>t1 : number
>t2 ** t2 : number
>t2 : number
>t2 : number
>t1 : number
`${typeof (t1 ** t2 ** t1) } world`;
>`${typeof (t1 ** t2 ** t1) } world` : string
>typeof (t1 ** t2 ** t1) : string
>(t1 ** t2 ** t1) : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`${1 + typeof (t1 ** t2 ** t1) } world`;
>`${1 + typeof (t1 ** t2 ** t1) } world` : string
>1 + typeof (t1 ** t2 ** t1) : string
>1 : number
>typeof (t1 ** t2 ** t1) : string
>(t1 ** t2 ** t1) : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`${t1 ** t2}${t1 ** t2} world`;
>`${t1 ** t2}${t1 ** t2} world` : string
>t1 ** t2 : number
>t1 : number
>t2 : number
>t1 ** t2 : number
>t1 : number
>t2 : number
`${t1 ** t2 ** t1}${t1 ** t2 ** t1} world`;
>`${t1 ** t2 ** t1}${t1 ** t2 ** t1} world` : string
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`${t1 + t2 ** t1}${t1 + t2 ** t1} world`;
>`${t1 + t2 ** t1}${t1 + t2 ** t1} world` : string
>t1 + t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
>t1 + t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`${t1 ** t2 + t1}${t1 ** t2 + t1} world`;
>`${t1 ** t2 + t1}${t1 ** t2 + t1} world` : string
>t1 ** t2 + t1 : number
>t1 ** t2 : number
>t1 : number
>t2 : number
>t1 : number
>t1 ** t2 + t1 : number
>t1 ** t2 : number
>t1 : number
>t2 : number
>t1 : number
`${t1 + t2 ** t2 + t1}${t1 + t2 ** t2 + t1} world`;
>`${t1 + t2 ** t2 + t1}${t1 + t2 ** t2 + t1} world` : string
>t1 + t2 ** t2 + t1 : number
>t1 + t2 ** t2 : number
>t1 : number
>t2 ** t2 : number
>t2 : number
>t2 : number
>t1 : number
>t1 + t2 ** t2 + t1 : number
>t1 + t2 ** t2 : number
>t1 : number
>t2 ** t2 : number
>t2 : number
>t2 : number
>t1 : number
`${typeof (t1 ** t2 ** t1) }${typeof (t1 ** t2 ** t1) } world`;
>`${typeof (t1 ** t2 ** t1) }${typeof (t1 ** t2 ** t1) } world` : string
>typeof (t1 ** t2 ** t1) : string
>(t1 ** t2 ** t1) : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
>typeof (t1 ** t2 ** t1) : string
>(t1 ** t2 ** t1) : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`${t1 ** t2} hello world ${t1 ** t2} !!`;
>`${t1 ** t2} hello world ${t1 ** t2} !!` : string
>t1 ** t2 : number
>t1 : number
>t2 : number
>t1 ** t2 : number
>t1 : number
>t2 : number
`${t1 ** t2 ** t1} hello world ${t1 ** t2 ** t1} !!`;
>`${t1 ** t2 ** t1} hello world ${t1 ** t2 ** t1} !!` : string
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`${t1 + t2 ** t1} hello world ${t1 + t2 ** t1} !!`;
>`${t1 + t2 ** t1} hello world ${t1 + t2 ** t1} !!` : string
>t1 + t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
>t1 + t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`${t1 ** t2 + t1} hello world ${t1 ** t2 + t1} !!`;
>`${t1 ** t2 + t1} hello world ${t1 ** t2 + t1} !!` : string
>t1 ** t2 + t1 : number
>t1 ** t2 : number
>t1 : number
>t2 : number
>t1 : number
>t1 ** t2 + t1 : number
>t1 ** t2 : number
>t1 : number
>t2 : number
>t1 : number
`${t1 + t2 ** t2 + t1} hello world ${t1 + t2 ** t2 + t1} !!`;
>`${t1 + t2 ** t2 + t1} hello world ${t1 + t2 ** t2 + t1} !!` : string
>t1 + t2 ** t2 + t1 : number
>t1 + t2 ** t2 : number
>t1 : number
>t2 ** t2 : number
>t2 : number
>t2 : number
>t1 : number
>t1 + t2 ** t2 + t1 : number
>t1 + t2 ** t2 : number
>t1 : number
>t2 ** t2 : number
>t2 : number
>t2 : number
>t1 : number
`${typeof (t1 ** t2 ** t1) } hello world ${typeof (t1 ** t2 ** t1)} !!`;
>`${typeof (t1 ** t2 ** t1) } hello world ${typeof (t1 ** t2 ** t1)} !!` : string
>typeof (t1 ** t2 ** t1) : string
>(t1 ** t2 ** t1) : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
>typeof (t1 ** t2 ** t1) : string
>(t1 ** t2 ** t1) : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
@@ -0,0 +1,54 @@
//// [emitExponentiationOperatorInTemplateString3ES6.ts]
var t1 = 10;
var t2 = 10;
var s;
// With TemplateTail
`${t1 ** t2} world`;
`${t1 ** t2 ** t1} world`;
`${t1 + t2 ** t1} world`;
`${t1 ** t2 + t1} world`;
`${t1 + t2 ** t2 + t1 } world`;
`${typeof (t1 ** t2 ** t1) } world`;
`${1 + typeof (t1 ** t2 ** t1) } world`;
`${t1 ** t2}${t1 ** t2} world`;
`${t1 ** t2 ** t1}${t1 ** t2 ** t1} world`;
`${t1 + t2 ** t1}${t1 + t2 ** t1} world`;
`${t1 ** t2 + t1}${t1 ** t2 + t1} world`;
`${t1 + t2 ** t2 + t1}${t1 + t2 ** t2 + t1} world`;
`${typeof (t1 ** t2 ** t1) }${typeof (t1 ** t2 ** t1) } world`;
`${t1 ** t2} hello world ${t1 ** t2} !!`;
`${t1 ** t2 ** t1} hello world ${t1 ** t2 ** t1} !!`;
`${t1 + t2 ** t1} hello world ${t1 + t2 ** t1} !!`;
`${t1 ** t2 + t1} hello world ${t1 ** t2 + t1} !!`;
`${t1 + t2 ** t2 + t1} hello world ${t1 + t2 ** t2 + t1} !!`;
`${typeof (t1 ** t2 ** t1) } hello world ${typeof (t1 ** t2 ** t1)} !!`;
//// [emitExponentiationOperatorInTemplateString3ES6.js]
var t1 = 10;
var t2 = 10;
var s;
// With TemplateTail
`${Math.pow(t1, t2)} world`;
`${Math.pow(t1, Math.pow(t2, t1))} world`;
`${t1 + Math.pow(t2, t1)} world`;
`${Math.pow(t1, t2) + t1} world`;
`${t1 + Math.pow(t2, t2) + t1} world`;
`${typeof (Math.pow(t1, Math.pow(t2, t1)))} world`;
`${1 + typeof (Math.pow(t1, Math.pow(t2, t1)))} world`;
`${Math.pow(t1, t2)}${Math.pow(t1, t2)} world`;
`${Math.pow(t1, Math.pow(t2, t1))}${Math.pow(t1, Math.pow(t2, t1))} world`;
`${t1 + Math.pow(t2, t1)}${t1 + Math.pow(t2, t1)} world`;
`${Math.pow(t1, t2) + t1}${Math.pow(t1, t2) + t1} world`;
`${t1 + Math.pow(t2, t2) + t1}${t1 + Math.pow(t2, t2) + t1} world`;
`${typeof (Math.pow(t1, Math.pow(t2, t1)))}${typeof (Math.pow(t1, Math.pow(t2, t1)))} world`;
`${Math.pow(t1, t2)} hello world ${Math.pow(t1, t2)} !!`;
`${Math.pow(t1, Math.pow(t2, t1))} hello world ${Math.pow(t1, Math.pow(t2, t1))} !!`;
`${t1 + Math.pow(t2, t1)} hello world ${t1 + Math.pow(t2, t1)} !!`;
`${Math.pow(t1, t2) + t1} hello world ${Math.pow(t1, t2) + t1} !!`;
`${t1 + Math.pow(t2, t2) + t1} hello world ${t1 + Math.pow(t2, t2) + t1} !!`;
`${typeof (Math.pow(t1, Math.pow(t2, t1)))} hello world ${typeof (Math.pow(t1, Math.pow(t2, t1)))} !!`;
@@ -0,0 +1,143 @@
=== tests/cases/conformance/es7/exponentiationOperator/emitExponentiationOperatorInTemplateString3ES6.ts ===
var t1 = 10;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
var t2 = 10;
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 2, 3))
var s;
>s : Symbol(s, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 3, 3))
// With TemplateTail
`${t1 ** t2} world`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 2, 3))
`${t1 ** t2 ** t1} world`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
`${t1 + t2 ** t1} world`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
`${t1 ** t2 + t1} world`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
`${t1 + t2 ** t2 + t1 } world`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 2, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
`${typeof (t1 ** t2 ** t1) } world`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
`${1 + typeof (t1 ** t2 ** t1) } world`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
`${t1 ** t2}${t1 ** t2} world`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 2, 3))
`${t1 ** t2 ** t1}${t1 ** t2 ** t1} world`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
`${t1 + t2 ** t1}${t1 + t2 ** t1} world`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
`${t1 ** t2 + t1}${t1 ** t2 + t1} world`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
`${t1 + t2 ** t2 + t1}${t1 + t2 ** t2 + t1} world`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 2, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 2, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
`${typeof (t1 ** t2 ** t1) }${typeof (t1 ** t2 ** t1) } world`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
`${t1 ** t2} hello world ${t1 ** t2} !!`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 2, 3))
`${t1 ** t2 ** t1} hello world ${t1 ** t2 ** t1} !!`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
`${t1 + t2 ** t1} hello world ${t1 + t2 ** t1} !!`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
`${t1 ** t2 + t1} hello world ${t1 ** t2 + t1} !!`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
`${t1 + t2 ** t2 + t1} hello world ${t1 + t2 ** t2 + t1} !!`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 2, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 2, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
`${typeof (t1 ** t2 ** t1) } hello world ${typeof (t1 ** t2 ** t1)} !!`;
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
>t2 : Symbol(t2, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 2, 3))
>t1 : Symbol(t1, Decl(emitExponentiationOperatorInTemplateString3ES6.ts, 1, 3))
@@ -0,0 +1,240 @@
=== tests/cases/conformance/es7/exponentiationOperator/emitExponentiationOperatorInTemplateString3ES6.ts ===
var t1 = 10;
>t1 : number
>10 : number
var t2 = 10;
>t2 : number
>10 : number
var s;
>s : any
// With TemplateTail
`${t1 ** t2} world`;
>`${t1 ** t2} world` : string
>t1 ** t2 : number
>t1 : number
>t2 : number
`${t1 ** t2 ** t1} world`;
>`${t1 ** t2 ** t1} world` : string
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`${t1 + t2 ** t1} world`;
>`${t1 + t2 ** t1} world` : string
>t1 + t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`${t1 ** t2 + t1} world`;
>`${t1 ** t2 + t1} world` : string
>t1 ** t2 + t1 : number
>t1 ** t2 : number
>t1 : number
>t2 : number
>t1 : number
`${t1 + t2 ** t2 + t1 } world`;
>`${t1 + t2 ** t2 + t1 } world` : string
>t1 + t2 ** t2 + t1 : number
>t1 + t2 ** t2 : number
>t1 : number
>t2 ** t2 : number
>t2 : number
>t2 : number
>t1 : number
`${typeof (t1 ** t2 ** t1) } world`;
>`${typeof (t1 ** t2 ** t1) } world` : string
>typeof (t1 ** t2 ** t1) : string
>(t1 ** t2 ** t1) : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`${1 + typeof (t1 ** t2 ** t1) } world`;
>`${1 + typeof (t1 ** t2 ** t1) } world` : string
>1 + typeof (t1 ** t2 ** t1) : string
>1 : number
>typeof (t1 ** t2 ** t1) : string
>(t1 ** t2 ** t1) : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`${t1 ** t2}${t1 ** t2} world`;
>`${t1 ** t2}${t1 ** t2} world` : string
>t1 ** t2 : number
>t1 : number
>t2 : number
>t1 ** t2 : number
>t1 : number
>t2 : number
`${t1 ** t2 ** t1}${t1 ** t2 ** t1} world`;
>`${t1 ** t2 ** t1}${t1 ** t2 ** t1} world` : string
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`${t1 + t2 ** t1}${t1 + t2 ** t1} world`;
>`${t1 + t2 ** t1}${t1 + t2 ** t1} world` : string
>t1 + t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
>t1 + t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`${t1 ** t2 + t1}${t1 ** t2 + t1} world`;
>`${t1 ** t2 + t1}${t1 ** t2 + t1} world` : string
>t1 ** t2 + t1 : number
>t1 ** t2 : number
>t1 : number
>t2 : number
>t1 : number
>t1 ** t2 + t1 : number
>t1 ** t2 : number
>t1 : number
>t2 : number
>t1 : number
`${t1 + t2 ** t2 + t1}${t1 + t2 ** t2 + t1} world`;
>`${t1 + t2 ** t2 + t1}${t1 + t2 ** t2 + t1} world` : string
>t1 + t2 ** t2 + t1 : number
>t1 + t2 ** t2 : number
>t1 : number
>t2 ** t2 : number
>t2 : number
>t2 : number
>t1 : number
>t1 + t2 ** t2 + t1 : number
>t1 + t2 ** t2 : number
>t1 : number
>t2 ** t2 : number
>t2 : number
>t2 : number
>t1 : number
`${typeof (t1 ** t2 ** t1) }${typeof (t1 ** t2 ** t1) } world`;
>`${typeof (t1 ** t2 ** t1) }${typeof (t1 ** t2 ** t1) } world` : string
>typeof (t1 ** t2 ** t1) : string
>(t1 ** t2 ** t1) : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
>typeof (t1 ** t2 ** t1) : string
>(t1 ** t2 ** t1) : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`${t1 ** t2} hello world ${t1 ** t2} !!`;
>`${t1 ** t2} hello world ${t1 ** t2} !!` : string
>t1 ** t2 : number
>t1 : number
>t2 : number
>t1 ** t2 : number
>t1 : number
>t2 : number
`${t1 ** t2 ** t1} hello world ${t1 ** t2 ** t1} !!`;
>`${t1 ** t2 ** t1} hello world ${t1 ** t2 ** t1} !!` : string
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`${t1 + t2 ** t1} hello world ${t1 + t2 ** t1} !!`;
>`${t1 + t2 ** t1} hello world ${t1 + t2 ** t1} !!` : string
>t1 + t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
>t1 + t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
`${t1 ** t2 + t1} hello world ${t1 ** t2 + t1} !!`;
>`${t1 ** t2 + t1} hello world ${t1 ** t2 + t1} !!` : string
>t1 ** t2 + t1 : number
>t1 ** t2 : number
>t1 : number
>t2 : number
>t1 : number
>t1 ** t2 + t1 : number
>t1 ** t2 : number
>t1 : number
>t2 : number
>t1 : number
`${t1 + t2 ** t2 + t1} hello world ${t1 + t2 ** t2 + t1} !!`;
>`${t1 + t2 ** t2 + t1} hello world ${t1 + t2 ** t2 + t1} !!` : string
>t1 + t2 ** t2 + t1 : number
>t1 + t2 ** t2 : number
>t1 : number
>t2 ** t2 : number
>t2 : number
>t2 : number
>t1 : number
>t1 + t2 ** t2 + t1 : number
>t1 + t2 ** t2 : number
>t1 : number
>t2 ** t2 : number
>t2 : number
>t2 : number
>t1 : number
`${typeof (t1 ** t2 ** t1) } hello world ${typeof (t1 ** t2 ** t1)} !!`;
>`${typeof (t1 ** t2 ** t1) } hello world ${typeof (t1 ** t2 ** t1)} !!` : string
>typeof (t1 ** t2 ** t1) : string
>(t1 ** t2 ** t1) : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
>typeof (t1 ** t2 ** t1) : string
>(t1 ** t2 ** t1) : number
>t1 ** t2 ** t1 : number
>t1 : number
>t2 ** t1 : number
>t2 : number
>t1 : number
@@ -0,0 +1,165 @@
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError1.ts(8,8): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError1.ts(8,8): error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError1.ts(9,4): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError1.ts(10,4): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError1.ts(11,4): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError1.ts(12,4): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError1.ts(12,4): error TS17006: An unary expression with the '!' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError1.ts(13,4): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError1.ts(13,4): error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError1.ts(15,4): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError1.ts(15,21): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError1.ts(16,4): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError1.ts(16,23): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError1.ts(17,4): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError1.ts(17,23): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError1.ts(18,4): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError1.ts(18,4): error TS17006: An unary expression with the '!' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError1.ts(18,25): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError1.ts(18,25): error TS17006: An unary expression with the '!' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError1.ts(19,4): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError1.ts(19,4): error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError1.ts(19,28): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError1.ts(19,28): error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError1.ts(20,8): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError1.ts(20,8): error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError1.ts(20,36): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError1.ts(20,36): error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError1.ts(22,4): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError1.ts(22,34): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError1.ts(23,4): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError1.ts(23,36): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError1.ts(24,4): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError1.ts(24,36): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError1.ts(25,4): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError1.ts(25,4): error TS17006: An unary expression with the '!' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError1.ts(25,38): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError1.ts(25,38): error TS17006: An unary expression with the '!' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError1.ts(26,4): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError1.ts(26,4): error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError1.ts(26,41): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError1.ts(26,41): error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError1.ts(27,8): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError1.ts(27,8): error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError1.ts(27,49): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError1.ts(27,49): error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
==== tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError1.ts (45 errors) ====
var t1 = 10;
var t2 = 10;
var s;
// Error: early syntax error using ES7 SimpleUnaryExpression on left-hand side without ()
// TempateHead & TemplateTail are empty
`${1 + typeof t1 ** t2 ** t1}`;
~~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~~
!!! error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`${-t1 ** t2 - t1}`;
~~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`${-++t1 ** t2 - t1}`;
~~~~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`${-t1++ ** t2 - t1}`;
~~~~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`${!t1 ** t2 ** --t1 }`;
~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~
!!! error TS17006: An unary expression with the '!' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`${typeof t1 ** t2 ** t1}`;
~~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~~
!!! error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`${-t1 ** t2 - t1}${-t1 ** t2 - t1}`;
~~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
~~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`${-++t1 ** t2 - t1}${-++t1 ** t2 - t1}`;
~~~~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
~~~~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`${-t1++ ** t2 - t1}${-t1++ ** t2 - t1}`;
~~~~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
~~~~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`${!t1 ** t2 ** --t1 }${!t1 ** t2 ** --t1 }`;
~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~
!!! error TS17006: An unary expression with the '!' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~
!!! error TS17006: An unary expression with the '!' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`${typeof t1 ** t2 ** t1}${typeof t1 ** t2 ** t1}`;
~~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~~
!!! error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
~~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~~
!!! error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`${1 + typeof t1 ** t2 ** t1}${1 + typeof t1 ** t2 ** t1}`;
~~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~~
!!! error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
~~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~~
!!! error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`${-t1 ** t2 - t1} hello world ${-t1 ** t2 - t1}`;
~~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
~~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`${-++t1 ** t2 - t1} hello world ${-++t1 ** t2 - t1}`;
~~~~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
~~~~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`${-t1++ ** t2 - t1} hello world ${-t1++ ** t2 - t1}`;
~~~~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
~~~~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`${!t1 ** t2 ** --t1 } hello world ${!t1 ** t2 ** --t1 }`;
~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~
!!! error TS17006: An unary expression with the '!' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~
!!! error TS17006: An unary expression with the '!' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`${typeof t1 ** t2 ** t1} hello world ${typeof t1 ** t2 ** t1}`;
~~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~~
!!! error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
~~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~~
!!! error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`${1 + typeof t1 ** t2 ** t1} hello world ${1 + typeof t1 ** t2 ** t1}`;
~~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~~
!!! error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
~~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~~
!!! error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
@@ -0,0 +1,53 @@
//// [exponentiationOperatorInTemplateStringWithSyntaxError1.ts]
var t1 = 10;
var t2 = 10;
var s;
// Error: early syntax error using ES7 SimpleUnaryExpression on left-hand side without ()
// TempateHead & TemplateTail are empty
`${1 + typeof t1 ** t2 ** t1}`;
`${-t1 ** t2 - t1}`;
`${-++t1 ** t2 - t1}`;
`${-t1++ ** t2 - t1}`;
`${!t1 ** t2 ** --t1 }`;
`${typeof t1 ** t2 ** t1}`;
`${-t1 ** t2 - t1}${-t1 ** t2 - t1}`;
`${-++t1 ** t2 - t1}${-++t1 ** t2 - t1}`;
`${-t1++ ** t2 - t1}${-t1++ ** t2 - t1}`;
`${!t1 ** t2 ** --t1 }${!t1 ** t2 ** --t1 }`;
`${typeof t1 ** t2 ** t1}${typeof t1 ** t2 ** t1}`;
`${1 + typeof t1 ** t2 ** t1}${1 + typeof t1 ** t2 ** t1}`;
`${-t1 ** t2 - t1} hello world ${-t1 ** t2 - t1}`;
`${-++t1 ** t2 - t1} hello world ${-++t1 ** t2 - t1}`;
`${-t1++ ** t2 - t1} hello world ${-t1++ ** t2 - t1}`;
`${!t1 ** t2 ** --t1 } hello world ${!t1 ** t2 ** --t1 }`;
`${typeof t1 ** t2 ** t1} hello world ${typeof t1 ** t2 ** t1}`;
`${1 + typeof t1 ** t2 ** t1} hello world ${1 + typeof t1 ** t2 ** t1}`;
//// [exponentiationOperatorInTemplateStringWithSyntaxError1.js]
var t1 = 10;
var t2 = 10;
var s;
// Error: early syntax error using ES7 SimpleUnaryExpression on left-hand side without ()
// TempateHead & TemplateTail are empty
"" + (1 + Math.pow(typeof t1, Math.pow(t2, t1)));
"" + (Math.pow(-t1, t2) - t1);
"" + (Math.pow(-++t1, t2) - t1);
"" + (Math.pow(-t1++, t2) - t1);
"" + (Math.pow(!t1, Math.pow(t2, --t1)));
"" + (Math.pow(typeof t1, Math.pow(t2, t1)));
"" + (Math.pow(-t1, t2) - t1) + (Math.pow(-t1, t2) - t1);
"" + (Math.pow(-++t1, t2) - t1) + (Math.pow(-++t1, t2) - t1);
"" + (Math.pow(-t1++, t2) - t1) + (Math.pow(-t1++, t2) - t1);
"" + (Math.pow(!t1, Math.pow(t2, --t1))) + (Math.pow(!t1, Math.pow(t2, --t1)));
"" + (Math.pow(typeof t1, Math.pow(t2, t1))) + (Math.pow(typeof t1, Math.pow(t2, t1)));
"" + (1 + Math.pow(typeof t1, Math.pow(t2, t1))) + (1 + Math.pow(typeof t1, Math.pow(t2, t1)));
(Math.pow(-t1, t2) - t1) + " hello world " + (Math.pow(-t1, t2) - t1);
(Math.pow(-++t1, t2) - t1) + " hello world " + (Math.pow(-++t1, t2) - t1);
(Math.pow(-t1++, t2) - t1) + " hello world " + (Math.pow(-t1++, t2) - t1);
(Math.pow(!t1, Math.pow(t2, --t1))) + " hello world " + (Math.pow(!t1, Math.pow(t2, --t1)));
(Math.pow(typeof t1, Math.pow(t2, t1))) + " hello world " + (Math.pow(typeof t1, Math.pow(t2, t1)));
(1 + Math.pow(typeof t1, Math.pow(t2, t1))) + " hello world " + (1 + Math.pow(typeof t1, Math.pow(t2, t1)));
@@ -0,0 +1,166 @@
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError2.ts(8,10): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError2.ts(9,10): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError2.ts(10,10): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError2.ts(11,10): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError2.ts(11,10): error TS17006: An unary expression with the '!' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError2.ts(12,10): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError2.ts(12,10): error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError2.ts(13,14): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError2.ts(13,14): error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError2.ts(15,10): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError2.ts(15,27): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError2.ts(16,10): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError2.ts(16,29): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError2.ts(17,10): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError2.ts(17,29): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError2.ts(18,10): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError2.ts(18,10): error TS17006: An unary expression with the '!' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError2.ts(18,31): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError2.ts(18,31): error TS17006: An unary expression with the '!' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError2.ts(19,10): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError2.ts(19,10): error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError2.ts(19,34): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError2.ts(19,34): error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError2.ts(20,14): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError2.ts(20,14): error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError2.ts(20,42): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError2.ts(20,42): error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError2.ts(22,10): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError2.ts(22,40): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError2.ts(23,10): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError2.ts(23,42): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError2.ts(24,10): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError2.ts(24,42): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError2.ts(25,10): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError2.ts(25,10): error TS17006: An unary expression with the '!' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError2.ts(25,44): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError2.ts(25,44): error TS17006: An unary expression with the '!' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError2.ts(26,10): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError2.ts(26,10): error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError2.ts(26,47): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError2.ts(26,47): error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError2.ts(27,14): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError2.ts(27,14): error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError2.ts(27,55): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError2.ts(27,55): error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
==== tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError2.ts (45 errors) ====
var t1 = 10;
var t2 = 10;
var s;
// Error: early syntax error using ES7 SimpleUnaryExpression on left-hand side without ()
// With templateHead
`hello ${-t1 ** t2 - t1}`;
~~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`hello ${-++t1 ** t2 - t1}`;
~~~~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`hello ${-t1++ ** t2 - t1}`;
~~~~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`hello ${!t1 ** t2 ** --t1 }`;
~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~
!!! error TS17006: An unary expression with the '!' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`hello ${typeof t1 ** t2 ** t1}`;
~~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~~
!!! error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`hello ${1 + typeof t1 ** t2 ** t1}`;
~~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~~
!!! error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`hello ${-t1 ** t2 - t1}${-t1 ** t2 - t1}`;
~~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
~~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`hello ${-++t1 ** t2 - t1}${-++t1 ** t2 - t1}`;
~~~~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
~~~~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`hello ${-t1++ ** t2 - t1}${-t1++ ** t2 - t1}`;
~~~~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
~~~~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`hello ${!t1 ** t2 ** --t1 }${!t1 ** t2 ** --t1 }`;
~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~
!!! error TS17006: An unary expression with the '!' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~
!!! error TS17006: An unary expression with the '!' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`hello ${typeof t1 ** t2 ** t1}${typeof t1 ** t2 ** t1}`;
~~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~~
!!! error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
~~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~~
!!! error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`hello ${1 + typeof t1 ** t2 ** t1}${1 + typeof t1 ** t2 ** t1}`;
~~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~~
!!! error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
~~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~~
!!! error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`hello ${-t1 ** t2 - t1} hello world ${-t1 ** t2 - t1}`;
~~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
~~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`hello ${-++t1 ** t2 - t1} hello world ${-++t1 ** t2 - t1}`;
~~~~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
~~~~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`hello ${-t1++ ** t2 - t1} hello world ${-t1++ ** t2 - t1}`;
~~~~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
~~~~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`hello ${!t1 ** t2 ** --t1 } hello world ${!t1 ** t2 ** --t1 }`;
~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~
!!! error TS17006: An unary expression with the '!' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~
!!! error TS17006: An unary expression with the '!' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`hello ${typeof t1 ** t2 ** t1} hello world ${typeof t1 ** t2 ** t1}`;
~~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~~
!!! error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
~~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~~
!!! error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`hello ${1 + typeof t1 ** t2 ** t1} hello world ${1 + typeof t1 ** t2 ** t1}`;
~~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~~
!!! error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
~~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~~
!!! error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
@@ -0,0 +1,54 @@
//// [exponentiationOperatorInTemplateStringWithSyntaxError2.ts]
var t1 = 10;
var t2 = 10;
var s;
// Error: early syntax error using ES7 SimpleUnaryExpression on left-hand side without ()
// With templateHead
`hello ${-t1 ** t2 - t1}`;
`hello ${-++t1 ** t2 - t1}`;
`hello ${-t1++ ** t2 - t1}`;
`hello ${!t1 ** t2 ** --t1 }`;
`hello ${typeof t1 ** t2 ** t1}`;
`hello ${1 + typeof t1 ** t2 ** t1}`;
`hello ${-t1 ** t2 - t1}${-t1 ** t2 - t1}`;
`hello ${-++t1 ** t2 - t1}${-++t1 ** t2 - t1}`;
`hello ${-t1++ ** t2 - t1}${-t1++ ** t2 - t1}`;
`hello ${!t1 ** t2 ** --t1 }${!t1 ** t2 ** --t1 }`;
`hello ${typeof t1 ** t2 ** t1}${typeof t1 ** t2 ** t1}`;
`hello ${1 + typeof t1 ** t2 ** t1}${1 + typeof t1 ** t2 ** t1}`;
`hello ${-t1 ** t2 - t1} hello world ${-t1 ** t2 - t1}`;
`hello ${-++t1 ** t2 - t1} hello world ${-++t1 ** t2 - t1}`;
`hello ${-t1++ ** t2 - t1} hello world ${-t1++ ** t2 - t1}`;
`hello ${!t1 ** t2 ** --t1 } hello world ${!t1 ** t2 ** --t1 }`;
`hello ${typeof t1 ** t2 ** t1} hello world ${typeof t1 ** t2 ** t1}`;
`hello ${1 + typeof t1 ** t2 ** t1} hello world ${1 + typeof t1 ** t2 ** t1}`;
//// [exponentiationOperatorInTemplateStringWithSyntaxError2.js]
var t1 = 10;
var t2 = 10;
var s;
// Error: early syntax error using ES7 SimpleUnaryExpression on left-hand side without ()
// With templateHead
"hello " + (Math.pow(-t1, t2) - t1);
"hello " + (Math.pow(-++t1, t2) - t1);
"hello " + (Math.pow(-t1++, t2) - t1);
"hello " + (Math.pow(!t1, Math.pow(t2, --t1)));
"hello " + (Math.pow(typeof t1, Math.pow(t2, t1)));
"hello " + (1 + Math.pow(typeof t1, Math.pow(t2, t1)));
"hello " + (Math.pow(-t1, t2) - t1) + (Math.pow(-t1, t2) - t1);
"hello " + (Math.pow(-++t1, t2) - t1) + (Math.pow(-++t1, t2) - t1);
"hello " + (Math.pow(-t1++, t2) - t1) + (Math.pow(-t1++, t2) - t1);
"hello " + (Math.pow(!t1, Math.pow(t2, --t1))) + (Math.pow(!t1, Math.pow(t2, --t1)));
"hello " + (Math.pow(typeof t1, Math.pow(t2, t1))) + (Math.pow(typeof t1, Math.pow(t2, t1)));
"hello " + (1 + Math.pow(typeof t1, Math.pow(t2, t1))) + (1 + Math.pow(typeof t1, Math.pow(t2, t1)));
"hello " + (Math.pow(-t1, t2) - t1) + " hello world " + (Math.pow(-t1, t2) - t1);
"hello " + (Math.pow(-++t1, t2) - t1) + " hello world " + (Math.pow(-++t1, t2) - t1);
"hello " + (Math.pow(-t1++, t2) - t1) + " hello world " + (Math.pow(-t1++, t2) - t1);
"hello " + (Math.pow(!t1, Math.pow(t2, --t1))) + " hello world " + (Math.pow(!t1, Math.pow(t2, --t1)));
"hello " + (Math.pow(typeof t1, Math.pow(t2, t1))) + " hello world " + (Math.pow(typeof t1, Math.pow(t2, t1)));
"hello " + (1 + Math.pow(typeof t1, Math.pow(t2, t1))) + " hello world " + (1 + Math.pow(typeof t1, Math.pow(t2, t1)));
@@ -0,0 +1,165 @@
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError3.ts(8,4): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError3.ts(9,4): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError3.ts(10,4): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError3.ts(11,4): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError3.ts(11,4): error TS17006: An unary expression with the '!' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError3.ts(12,4): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError3.ts(12,4): error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError3.ts(13,8): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError3.ts(13,8): error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError3.ts(15,4): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError3.ts(15,21): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError3.ts(16,4): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError3.ts(16,23): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError3.ts(17,4): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError3.ts(17,23): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError3.ts(18,4): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError3.ts(18,4): error TS17006: An unary expression with the '!' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError3.ts(18,25): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError3.ts(18,25): error TS17006: An unary expression with the '!' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError3.ts(19,4): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError3.ts(19,4): error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError3.ts(19,28): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError3.ts(19,28): error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError3.ts(20,8): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError3.ts(20,8): error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError3.ts(20,36): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError3.ts(20,36): error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError3.ts(22,4): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError3.ts(22,34): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError3.ts(23,4): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError3.ts(23,36): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError3.ts(24,4): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError3.ts(24,36): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError3.ts(25,4): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError3.ts(25,4): error TS17006: An unary expression with the '!' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError3.ts(25,38): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError3.ts(25,38): error TS17006: An unary expression with the '!' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError3.ts(26,4): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError3.ts(26,4): error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError3.ts(26,41): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError3.ts(26,41): error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError3.ts(27,8): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError3.ts(27,8): error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError3.ts(27,49): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError3.ts(27,49): error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
==== tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorInTemplateStringWithSyntaxError3.ts (45 errors) ====
var t1 = 10;
var t2 = 10;
var s;
// Error: early syntax error using ES7 SimpleUnaryExpression on left-hand side without ()
// With TemplateTail
`${-t1 ** t2 - t1} world`;
~~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`${-++t1 ** t2 - t1} world`;
~~~~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`${-t1++ ** t2 - t1} world`;
~~~~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`${!t1 ** t2 ** --t1 } world`;
~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~
!!! error TS17006: An unary expression with the '!' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`${typeof t1 ** t2 ** t1} world`;
~~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~~
!!! error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`${1 + typeof t1 ** t2 ** t1} world`;
~~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~~
!!! error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`${-t1 ** t2 - t1}${-t1 ** t2 - t1} world`;
~~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
~~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`${-++t1 ** t2 - t1}${-++t1 ** t2 - t1} world`;
~~~~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
~~~~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`${-t1++ ** t2 - t1}${-t1++ ** t2 - t1} world`;
~~~~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
~~~~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`${!t1 ** t2 ** --t1 }${!t1 ** t2 ** --t1 } world`;
~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~
!!! error TS17006: An unary expression with the '!' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~
!!! error TS17006: An unary expression with the '!' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`${typeof t1 ** t2 ** t1}${typeof t1 ** t2 ** t1} world`;
~~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~~
!!! error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
~~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~~
!!! error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`${1 + typeof t1 ** t2 ** t1}${1 + typeof t1 ** t2 ** t1} world`;
~~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~~
!!! error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
~~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~~
!!! error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`${-t1 ** t2 - t1} hello world ${-t1 ** t2 - t1} !!`;
~~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
~~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`${-++t1 ** t2 - t1} hello world ${-++t1 ** t2 - t1} !!`;
~~~~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
~~~~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`${-t1++ ** t2 - t1} hello world ${-t1++ ** t2 - t1} !!`;
~~~~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
~~~~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`${!t1 ** t2 ** --t1 } hello world ${!t1 ** t2 ** --t1 } !!`;
~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~
!!! error TS17006: An unary expression with the '!' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~
!!! error TS17006: An unary expression with the '!' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`${typeof t1 ** t2 ** t1} hello world ${typeof t1 ** t2 ** t1} !!`;
~~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~~
!!! error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
~~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~~
!!! error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
`${1 + typeof t1 ** t2 ** t1} hello world ${1 + typeof t1 ** t2 ** t1} !!`;
~~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~~
!!! error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
~~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~~
!!! error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
@@ -0,0 +1,53 @@
//// [exponentiationOperatorInTemplateStringWithSyntaxError3.ts]
var t1 = 10;
var t2 = 10;
var s;
// Error: early syntax error using ES7 SimpleUnaryExpression on left-hand side without ()
// With TemplateTail
`${-t1 ** t2 - t1} world`;
`${-++t1 ** t2 - t1} world`;
`${-t1++ ** t2 - t1} world`;
`${!t1 ** t2 ** --t1 } world`;
`${typeof t1 ** t2 ** t1} world`;
`${1 + typeof t1 ** t2 ** t1} world`;
`${-t1 ** t2 - t1}${-t1 ** t2 - t1} world`;
`${-++t1 ** t2 - t1}${-++t1 ** t2 - t1} world`;
`${-t1++ ** t2 - t1}${-t1++ ** t2 - t1} world`;
`${!t1 ** t2 ** --t1 }${!t1 ** t2 ** --t1 } world`;
`${typeof t1 ** t2 ** t1}${typeof t1 ** t2 ** t1} world`;
`${1 + typeof t1 ** t2 ** t1}${1 + typeof t1 ** t2 ** t1} world`;
`${-t1 ** t2 - t1} hello world ${-t1 ** t2 - t1} !!`;
`${-++t1 ** t2 - t1} hello world ${-++t1 ** t2 - t1} !!`;
`${-t1++ ** t2 - t1} hello world ${-t1++ ** t2 - t1} !!`;
`${!t1 ** t2 ** --t1 } hello world ${!t1 ** t2 ** --t1 } !!`;
`${typeof t1 ** t2 ** t1} hello world ${typeof t1 ** t2 ** t1} !!`;
`${1 + typeof t1 ** t2 ** t1} hello world ${1 + typeof t1 ** t2 ** t1} !!`;
//// [exponentiationOperatorInTemplateStringWithSyntaxError3.js]
var t1 = 10;
var t2 = 10;
var s;
// Error: early syntax error using ES7 SimpleUnaryExpression on left-hand side without ()
// With TemplateTail
(Math.pow(-t1, t2) - t1) + " world";
(Math.pow(-++t1, t2) - t1) + " world";
(Math.pow(-t1++, t2) - t1) + " world";
(Math.pow(!t1, Math.pow(t2, --t1))) + " world";
(Math.pow(typeof t1, Math.pow(t2, t1))) + " world";
(1 + Math.pow(typeof t1, Math.pow(t2, t1))) + " world";
"" + (Math.pow(-t1, t2) - t1) + (Math.pow(-t1, t2) - t1) + " world";
"" + (Math.pow(-++t1, t2) - t1) + (Math.pow(-++t1, t2) - t1) + " world";
"" + (Math.pow(-t1++, t2) - t1) + (Math.pow(-t1++, t2) - t1) + " world";
"" + (Math.pow(!t1, Math.pow(t2, --t1))) + (Math.pow(!t1, Math.pow(t2, --t1))) + " world";
"" + (Math.pow(typeof t1, Math.pow(t2, t1))) + (Math.pow(typeof t1, Math.pow(t2, t1))) + " world";
"" + (1 + Math.pow(typeof t1, Math.pow(t2, t1))) + (1 + Math.pow(typeof t1, Math.pow(t2, t1))) + " world";
(Math.pow(-t1, t2) - t1) + " hello world " + (Math.pow(-t1, t2) - t1) + " !!";
(Math.pow(-++t1, t2) - t1) + " hello world " + (Math.pow(-++t1, t2) - t1) + " !!";
(Math.pow(-t1++, t2) - t1) + " hello world " + (Math.pow(-t1++, t2) - t1) + " !!";
(Math.pow(!t1, Math.pow(t2, --t1))) + " hello world " + (Math.pow(!t1, Math.pow(t2, --t1))) + " !!";
(Math.pow(typeof t1, Math.pow(t2, t1))) + " hello world " + (Math.pow(typeof t1, Math.pow(t2, t1))) + " !!";
(1 + Math.pow(typeof t1, Math.pow(t2, t1))) + " hello world " + (1 + Math.pow(typeof t1, Math.pow(t2, t1))) + " !!";
@@ -0,0 +1,135 @@
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError1.ts(3,1): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError1.ts(4,1): error TS17006: An unary expression with the '+' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError1.ts(5,6): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError1.ts(6,6): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError1.ts(7,1): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError1.ts(7,7): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError1.ts(8,1): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError1.ts(12,1): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError1.ts(13,1): error TS17006: An unary expression with the '+' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError1.ts(14,1): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError1.ts(15,1): error TS17006: An unary expression with the '+' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError1.ts(16,6): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError1.ts(17,6): error TS17006: An unary expression with the '+' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError1.ts(18,6): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError1.ts(19,6): error TS17006: An unary expression with the '+' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError1.ts(21,1): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError1.ts(22,1): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError1.ts(23,1): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError1.ts(24,1): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError1.ts(25,1): error TS17006: An unary expression with the '+' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError1.ts(26,1): error TS17006: An unary expression with the '+' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError1.ts(27,1): error TS17006: An unary expression with the '+' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError1.ts(28,1): error TS17006: An unary expression with the '+' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError1.ts(29,1): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError1.ts(30,1): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError1.ts(31,1): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError1.ts(32,1): error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError1.ts(33,1): error TS17006: An unary expression with the '+' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError1.ts(34,1): error TS17006: An unary expression with the '+' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError1.ts(35,1): error TS17006: An unary expression with the '+' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError1.ts(36,1): error TS17006: An unary expression with the '+' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
==== tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError1.ts (31 errors) ====
// Error: early syntax error using ES7 SimpleUnaryExpression on left-hand side without ()
-1 ** 2;
~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
+1 ** 2
~~
!!! error TS17006: An unary expression with the '+' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
1 ** -2 ** 3;
~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
1 ** -2 ** -3;
~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
-1 ** -2 ** -3;
~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
-(1 ** 2) ** 3;
~~~~~~~~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
var temp = 10;
-++temp ** 3;
~~~~~~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
+--temp ** 3;
~~~~~~~
!!! error TS17006: An unary expression with the '+' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
-temp++ ** 3;
~~~~~~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
+temp-- ** 3;
~~~~~~~
!!! error TS17006: An unary expression with the '+' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
1 ** -++temp ** 3;
~~~~~~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
1 ** +--temp ** 3;
~~~~~~~
!!! error TS17006: An unary expression with the '+' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
1 ** -temp++ ** 3;
~~~~~~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
1 ** +temp-- ** 3;
~~~~~~~
!!! error TS17006: An unary expression with the '+' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
-3 ** temp++;
~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
-3 ** temp--;
~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
-3 ** ++temp;
~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
-3 ** --temp;
~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
+3 ** temp++;
~~
!!! error TS17006: An unary expression with the '+' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
+3 ** temp--;
~~
!!! error TS17006: An unary expression with the '+' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
+3 ** ++temp;
~~
!!! error TS17006: An unary expression with the '+' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
+3 ** --temp;
~~
!!! error TS17006: An unary expression with the '+' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
-3 ** temp++ ** 2;
~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
-3 ** temp-- ** 2;
~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
-3 ** ++temp ** 2;
~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
-3 ** --temp ** 2;
~~
!!! error TS17006: An unary expression with the '-' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
+3 ** temp++ ** 2;
~~
!!! error TS17006: An unary expression with the '+' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
+3 ** temp-- ** 2;
~~
!!! error TS17006: An unary expression with the '+' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
+3 ** ++temp ** 2;
~~
!!! error TS17006: An unary expression with the '+' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
+3 ** --temp ** 2;
~~
!!! error TS17006: An unary expression with the '+' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
@@ -0,0 +1,74 @@
//// [exponentiationOperatorSyntaxError1.ts]
// Error: early syntax error using ES7 SimpleUnaryExpression on left-hand side without ()
-1 ** 2;
+1 ** 2
1 ** -2 ** 3;
1 ** -2 ** -3;
-1 ** -2 ** -3;
-(1 ** 2) ** 3;
var temp = 10;
-++temp ** 3;
+--temp ** 3;
-temp++ ** 3;
+temp-- ** 3;
1 ** -++temp ** 3;
1 ** +--temp ** 3;
1 ** -temp++ ** 3;
1 ** +temp-- ** 3;
-3 ** temp++;
-3 ** temp--;
-3 ** ++temp;
-3 ** --temp;
+3 ** temp++;
+3 ** temp--;
+3 ** ++temp;
+3 ** --temp;
-3 ** temp++ ** 2;
-3 ** temp-- ** 2;
-3 ** ++temp ** 2;
-3 ** --temp ** 2;
+3 ** temp++ ** 2;
+3 ** temp-- ** 2;
+3 ** ++temp ** 2;
+3 ** --temp ** 2;
//// [exponentiationOperatorSyntaxError1.js]
// Error: early syntax error using ES7 SimpleUnaryExpression on left-hand side without ()
Math.pow(-1, 2);
Math.pow(+1, 2);
Math.pow(1, Math.pow(-2, 3));
Math.pow(1, Math.pow(-2, -3));
Math.pow(-1, Math.pow(-2, -3));
Math.pow(-(Math.pow(1, 2)), 3);
var temp = 10;
Math.pow(-++temp, 3);
Math.pow(+--temp, 3);
Math.pow(-temp++, 3);
Math.pow(+temp--, 3);
Math.pow(1, Math.pow(-++temp, 3));
Math.pow(1, Math.pow(+--temp, 3));
Math.pow(1, Math.pow(-temp++, 3));
Math.pow(1, Math.pow(+temp--, 3));
Math.pow(-3, temp++);
Math.pow(-3, temp--);
Math.pow(-3, ++temp);
Math.pow(-3, --temp);
Math.pow(+3, temp++);
Math.pow(+3, temp--);
Math.pow(+3, ++temp);
Math.pow(+3, --temp);
Math.pow(-3, Math.pow(temp++, 2));
Math.pow(-3, Math.pow(temp--, 2));
Math.pow(-3, Math.pow(++temp, 2));
Math.pow(-3, Math.pow(--temp, 2));
Math.pow(+3, Math.pow(temp++, 2));
Math.pow(+3, Math.pow(temp--, 2));
Math.pow(+3, Math.pow(++temp, 2));
Math.pow(+3, Math.pow(--temp, 2));
@@ -0,0 +1,314 @@
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(5,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(5,1): error TS17006: An unary expression with the 'delete' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(6,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(6,1): error TS17006: An unary expression with the 'delete' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(7,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(7,1): error TS17006: An unary expression with the 'delete' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(8,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(8,1): error TS17006: An unary expression with the 'delete' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(11,6): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(11,6): error TS17006: An unary expression with the 'delete' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(12,6): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(12,6): error TS17006: An unary expression with the 'delete' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(13,6): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(13,6): error TS17006: An unary expression with the 'delete' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(14,6): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(14,6): error TS17006: An unary expression with the 'delete' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(16,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(16,1): error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(17,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(17,1): error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(18,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(18,1): error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(19,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(19,1): error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(20,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(20,1): error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(22,6): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(22,6): error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(23,6): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(23,6): error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(24,6): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(24,6): error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(25,6): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(25,6): error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(26,6): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(26,6): error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(28,1): error TS17006: An unary expression with the 'void' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(29,1): error TS17006: An unary expression with the 'void' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(30,1): error TS17006: An unary expression with the 'void' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(31,1): error TS17006: An unary expression with the 'void' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(32,1): error TS17006: An unary expression with the 'void' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(34,6): error TS17006: An unary expression with the 'void' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(35,6): error TS17006: An unary expression with the 'void' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(36,6): error TS17006: An unary expression with the 'void' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(37,6): error TS17006: An unary expression with the 'void' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(38,6): error TS17006: An unary expression with the 'void' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(40,1): error TS17006: An unary expression with the '~' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(41,1): error TS17006: An unary expression with the '~' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(42,1): error TS17006: An unary expression with the '~' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(43,1): error TS17006: An unary expression with the '~' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(44,1): error TS17006: An unary expression with the '~' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(46,6): error TS17006: An unary expression with the '~' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(47,6): error TS17006: An unary expression with the '~' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(48,6): error TS17006: An unary expression with the '~' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(49,6): error TS17006: An unary expression with the '~' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(50,6): error TS17006: An unary expression with the '~' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(52,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(52,1): error TS17006: An unary expression with the '!' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(53,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(53,1): error TS17006: An unary expression with the '!' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(54,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(54,1): error TS17006: An unary expression with the '!' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(55,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(55,1): error TS17006: An unary expression with the '!' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(56,1): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(56,1): error TS17006: An unary expression with the '!' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(58,6): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(58,6): error TS17006: An unary expression with the '!' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(59,6): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(59,6): error TS17006: An unary expression with the '!' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(60,6): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(60,6): error TS17006: An unary expression with the '!' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(61,6): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(61,6): error TS17006: An unary expression with the '!' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(62,6): error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(62,6): error TS17006: An unary expression with the '!' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(64,1): error TS17007: A type assertion expression is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(65,1): error TS17007: A type assertion expression is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(66,1): error TS17007: A type assertion expression is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(67,1): error TS17007: A type assertion expression is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts(68,1): error TS17007: A type assertion expression is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
==== tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorSyntaxError2.ts (81 errors) ====
// Error: early syntax error using ES7 SimpleUnaryExpression on left-hand side without ()
var temp;
delete --temp ** 3;
~~~~~~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~~~~~~
!!! error TS17006: An unary expression with the 'delete' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
delete ++temp ** 3;
~~~~~~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~~~~~~
!!! error TS17006: An unary expression with the 'delete' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
delete temp-- ** 3;
~~~~~~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~~~~~~
!!! error TS17006: An unary expression with the 'delete' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
delete temp++ ** 3;
~~~~~~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~~~~~~
!!! error TS17006: An unary expression with the 'delete' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
1 ** delete --temp ** 3;
~~~~~~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~~~~~~
!!! error TS17006: An unary expression with the 'delete' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
1 ** delete ++temp ** 3;
~~~~~~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~~~~~~
!!! error TS17006: An unary expression with the 'delete' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
1 ** delete temp-- ** 3;
~~~~~~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~~~~~~
!!! error TS17006: An unary expression with the 'delete' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
1 ** delete temp++ ** 3;
~~~~~~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~~~~~~
!!! error TS17006: An unary expression with the 'delete' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
typeof --temp ** 3;
~~~~~~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~~~~~~
!!! error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
typeof temp-- ** 3;
~~~~~~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~~~~~~
!!! error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
typeof 3 ** 4;
~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~
!!! error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
typeof temp++ ** 4;
~~~~~~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~~~~~~
!!! error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
typeof temp-- ** 4;
~~~~~~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~~~~~~
!!! error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
1 ** typeof --temp ** 3;
~~~~~~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~~~~~~
!!! error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
1 ** typeof temp-- ** 3;
~~~~~~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~~~~~~
!!! error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
1 ** typeof 3 ** 4;
~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~
!!! error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
1 ** typeof temp++ ** 4;
~~~~~~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~~~~~~
!!! error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
1 ** typeof temp-- ** 4;
~~~~~~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~~~~~~
!!! error TS17006: An unary expression with the 'typeof' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
void --temp ** 3;
~~~~~~~~~~~
!!! error TS17006: An unary expression with the 'void' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
void temp-- ** 3;
~~~~~~~~~~~
!!! error TS17006: An unary expression with the 'void' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
void 3 ** 4;
~~~~~~
!!! error TS17006: An unary expression with the 'void' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
void temp++ ** 4;
~~~~~~~~~~~
!!! error TS17006: An unary expression with the 'void' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
void temp-- ** 4;
~~~~~~~~~~~
!!! error TS17006: An unary expression with the 'void' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
1 ** void --temp ** 3;
~~~~~~~~~~~
!!! error TS17006: An unary expression with the 'void' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
1 ** void temp-- ** 3;
~~~~~~~~~~~
!!! error TS17006: An unary expression with the 'void' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
1 ** void 3 ** 4;
~~~~~~
!!! error TS17006: An unary expression with the 'void' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
1 ** void temp++ ** 4;
~~~~~~~~~~~
!!! error TS17006: An unary expression with the 'void' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
1 ** void temp-- ** 4 ;
~~~~~~~~~~~
!!! error TS17006: An unary expression with the 'void' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
~ --temp ** 3;
~~~~~~~~
!!! error TS17006: An unary expression with the '~' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
~temp-- ** 3;
~~~~~~~
!!! error TS17006: An unary expression with the '~' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
~3 ** 4;
~~
!!! error TS17006: An unary expression with the '~' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
~temp++ ** 4;
~~~~~~~
!!! error TS17006: An unary expression with the '~' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
~temp-- ** 4;
~~~~~~~
!!! error TS17006: An unary expression with the '~' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
1 ** ~ --temp ** 3;
~~~~~~~~
!!! error TS17006: An unary expression with the '~' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
1 ** ~temp-- ** 3;
~~~~~~~
!!! error TS17006: An unary expression with the '~' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
1 ** ~3 ** 4;
~~
!!! error TS17006: An unary expression with the '~' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
1 ** ~temp++ ** 4;
~~~~~~~
!!! error TS17006: An unary expression with the '~' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
1 ** ~temp-- ** 4;
~~~~~~~
!!! error TS17006: An unary expression with the '~' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
! --temp ** 3;
~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~
!!! error TS17006: An unary expression with the '!' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
!temp-- ** 3;
~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~
!!! error TS17006: An unary expression with the '!' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
!3 ** 4;
~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~
!!! error TS17006: An unary expression with the '!' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
!temp++ ** 4;
~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~
!!! error TS17006: An unary expression with the '!' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
!temp-- ** 4;
~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~
!!! error TS17006: An unary expression with the '!' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
1 ** ! --temp ** 3;
~~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~~
!!! error TS17006: An unary expression with the '!' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
1 ** !temp-- ** 3;
~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~
!!! error TS17006: An unary expression with the '!' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
1 ** !3 ** 4;
~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~
!!! error TS17006: An unary expression with the '!' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
1 ** !temp++ ** 4;
~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~
!!! error TS17006: An unary expression with the '!' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
1 ** !temp-- ** 4;
~~~~~~~
!!! error TS2362: The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type.
~~~~~~~
!!! error TS17006: An unary expression with the '!' operator is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
<number>temp ** 3;
~~~~~~~~~~~~
!!! error TS17007: A type assertion expression is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
<number>++temp ** 3;
~~~~~~~~~~~~~~
!!! error TS17007: A type assertion expression is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
<number>--temp ** 3;
~~~~~~~~~~~~~~
!!! error TS17007: A type assertion expression is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
<number>temp++ ** 3;
~~~~~~~~~~~~~~
!!! error TS17007: A type assertion expression is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
<number>temp-- ** 3;
~~~~~~~~~~~~~~
!!! error TS17007: A type assertion expression is not allowed in the left-hand side of an exponentiation expression. Consider enclosing the expression in parentheses.
@@ -0,0 +1,126 @@
//// [exponentiationOperatorSyntaxError2.ts]
// Error: early syntax error using ES7 SimpleUnaryExpression on left-hand side without ()
var temp;
delete --temp ** 3;
delete ++temp ** 3;
delete temp-- ** 3;
delete temp++ ** 3;
1 ** delete --temp ** 3;
1 ** delete ++temp ** 3;
1 ** delete temp-- ** 3;
1 ** delete temp++ ** 3;
typeof --temp ** 3;
typeof temp-- ** 3;
typeof 3 ** 4;
typeof temp++ ** 4;
typeof temp-- ** 4;
1 ** typeof --temp ** 3;
1 ** typeof temp-- ** 3;
1 ** typeof 3 ** 4;
1 ** typeof temp++ ** 4;
1 ** typeof temp-- ** 4;
void --temp ** 3;
void temp-- ** 3;
void 3 ** 4;
void temp++ ** 4;
void temp-- ** 4;
1 ** void --temp ** 3;
1 ** void temp-- ** 3;
1 ** void 3 ** 4;
1 ** void temp++ ** 4;
1 ** void temp-- ** 4 ;
~ --temp ** 3;
~temp-- ** 3;
~3 ** 4;
~temp++ ** 4;
~temp-- ** 4;
1 ** ~ --temp ** 3;
1 ** ~temp-- ** 3;
1 ** ~3 ** 4;
1 ** ~temp++ ** 4;
1 ** ~temp-- ** 4;
! --temp ** 3;
!temp-- ** 3;
!3 ** 4;
!temp++ ** 4;
!temp-- ** 4;
1 ** ! --temp ** 3;
1 ** !temp-- ** 3;
1 ** !3 ** 4;
1 ** !temp++ ** 4;
1 ** !temp-- ** 4;
<number>temp ** 3;
<number>++temp ** 3;
<number>--temp ** 3;
<number>temp++ ** 3;
<number>temp-- ** 3;
//// [exponentiationOperatorSyntaxError2.js]
// Error: early syntax error using ES7 SimpleUnaryExpression on left-hand side without ()
var temp;
Math.pow(delete --temp, 3);
Math.pow(delete ++temp, 3);
Math.pow(delete temp--, 3);
Math.pow(delete temp++, 3);
Math.pow(1, Math.pow(delete --temp, 3));
Math.pow(1, Math.pow(delete ++temp, 3));
Math.pow(1, Math.pow(delete temp--, 3));
Math.pow(1, Math.pow(delete temp++, 3));
Math.pow(typeof --temp, 3);
Math.pow(typeof temp--, 3);
Math.pow(typeof 3, 4);
Math.pow(typeof temp++, 4);
Math.pow(typeof temp--, 4);
Math.pow(1, Math.pow(typeof --temp, 3));
Math.pow(1, Math.pow(typeof temp--, 3));
Math.pow(1, Math.pow(typeof 3, 4));
Math.pow(1, Math.pow(typeof temp++, 4));
Math.pow(1, Math.pow(typeof temp--, 4));
Math.pow(void --temp, 3);
Math.pow(void temp--, 3);
Math.pow(void 3, 4);
Math.pow(void temp++, 4);
Math.pow(void temp--, 4);
Math.pow(1, Math.pow(void --temp, 3));
Math.pow(1, Math.pow(void temp--, 3));
Math.pow(1, Math.pow(void 3, 4));
Math.pow(1, Math.pow(void temp++, 4));
Math.pow(1, Math.pow(void temp--, 4));
Math.pow(~--temp, 3);
Math.pow(~temp--, 3);
Math.pow(~3, 4);
Math.pow(~temp++, 4);
Math.pow(~temp--, 4);
Math.pow(1, Math.pow(~--temp, 3));
Math.pow(1, Math.pow(~temp--, 3));
Math.pow(1, Math.pow(~3, 4));
Math.pow(1, Math.pow(~temp++, 4));
Math.pow(1, Math.pow(~temp--, 4));
Math.pow(!--temp, 3);
Math.pow(!temp--, 3);
Math.pow(!3, 4);
Math.pow(!temp++, 4);
Math.pow(!temp--, 4);
Math.pow(1, Math.pow(!--temp, 3));
Math.pow(1, Math.pow(!temp--, 3));
Math.pow(1, Math.pow(!3, 4));
Math.pow(1, Math.pow(!temp++, 4));
Math.pow(1, Math.pow(!temp--, 4));
Math.pow(temp, 3);
Math.pow(++temp, 3);
Math.pow(--temp, 3);
Math.pow(temp++, 3);
Math.pow(temp--, 3);
@@ -0,0 +1,26 @@
//// [exponentiationOperatorWithAnyAndNumber.ts]
var a: any;
var b: number;
// operator **
var r1 = a ** a;
var r2 = a ** b;
var r3 = a ** 0;
var r4 = 0 ** a;
var r5 = 0 ** 0;
var r6 = b ** 0;
var r7 = 0 ** b;
var r8 = b ** b;
//// [exponentiationOperatorWithAnyAndNumber.js]
var a;
var b;
// operator **
var r1 = Math.pow(a, a);
var r2 = Math.pow(a, b);
var r3 = Math.pow(a, 0);
var r4 = Math.pow(0, a);
var r5 = Math.pow(0, 0);
var r6 = Math.pow(b, 0);
var r7 = Math.pow(0, b);
var r8 = Math.pow(b, b);
@@ -0,0 +1,42 @@
=== tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorWithAnyAndNumber.ts ===
var a: any;
>a : Symbol(a, Decl(exponentiationOperatorWithAnyAndNumber.ts, 0, 3))
var b: number;
>b : Symbol(b, Decl(exponentiationOperatorWithAnyAndNumber.ts, 1, 3))
// operator **
var r1 = a ** a;
>r1 : Symbol(r1, Decl(exponentiationOperatorWithAnyAndNumber.ts, 4, 3))
>a : Symbol(a, Decl(exponentiationOperatorWithAnyAndNumber.ts, 0, 3))
>a : Symbol(a, Decl(exponentiationOperatorWithAnyAndNumber.ts, 0, 3))
var r2 = a ** b;
>r2 : Symbol(r2, Decl(exponentiationOperatorWithAnyAndNumber.ts, 5, 3))
>a : Symbol(a, Decl(exponentiationOperatorWithAnyAndNumber.ts, 0, 3))
>b : Symbol(b, Decl(exponentiationOperatorWithAnyAndNumber.ts, 1, 3))
var r3 = a ** 0;
>r3 : Symbol(r3, Decl(exponentiationOperatorWithAnyAndNumber.ts, 6, 3))
>a : Symbol(a, Decl(exponentiationOperatorWithAnyAndNumber.ts, 0, 3))
var r4 = 0 ** a;
>r4 : Symbol(r4, Decl(exponentiationOperatorWithAnyAndNumber.ts, 7, 3))
>a : Symbol(a, Decl(exponentiationOperatorWithAnyAndNumber.ts, 0, 3))
var r5 = 0 ** 0;
>r5 : Symbol(r5, Decl(exponentiationOperatorWithAnyAndNumber.ts, 8, 3))
var r6 = b ** 0;
>r6 : Symbol(r6, Decl(exponentiationOperatorWithAnyAndNumber.ts, 9, 3))
>b : Symbol(b, Decl(exponentiationOperatorWithAnyAndNumber.ts, 1, 3))
var r7 = 0 ** b;
>r7 : Symbol(r7, Decl(exponentiationOperatorWithAnyAndNumber.ts, 10, 3))
>b : Symbol(b, Decl(exponentiationOperatorWithAnyAndNumber.ts, 1, 3))
var r8 = b ** b;
>r8 : Symbol(r8, Decl(exponentiationOperatorWithAnyAndNumber.ts, 11, 3))
>b : Symbol(b, Decl(exponentiationOperatorWithAnyAndNumber.ts, 1, 3))
>b : Symbol(b, Decl(exponentiationOperatorWithAnyAndNumber.ts, 1, 3))
@@ -0,0 +1,56 @@
=== tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorWithAnyAndNumber.ts ===
var a: any;
>a : any
var b: number;
>b : number
// operator **
var r1 = a ** a;
>r1 : number
>a ** a : number
>a : any
>a : any
var r2 = a ** b;
>r2 : number
>a ** b : number
>a : any
>b : number
var r3 = a ** 0;
>r3 : number
>a ** 0 : number
>a : any
>0 : number
var r4 = 0 ** a;
>r4 : number
>0 ** a : number
>0 : number
>a : any
var r5 = 0 ** 0;
>r5 : number
>0 ** 0 : number
>0 : number
>0 : number
var r6 = b ** 0;
>r6 : number
>b ** 0 : number
>b : number
>0 : number
var r7 = 0 ** b;
>r7 : number
>0 ** b : number
>0 : number
>b : number
var r8 = b ** b;
>r8 : number
>b ** b : number
>b : number
>b : number
@@ -0,0 +1,49 @@
//// [exponentiationOperatorWithEnum.ts]
// operands of an enum type are treated as having the primitive type Number.
enum E {
a,
b
}
var a: any;
var b: number;
var c: E;
// operator **
var r1 = c ** a;
var r2 = c ** b;
var r3 = c ** c;
var r4 = a ** c;
var r5 = b ** c;
var r6 = E.a ** a;
var r7 = E.a ** b;
var r8 = E.a ** E.b;
var r9 = E.a ** 1;
var r10 = a ** E.b;
var r11 = b ** E.b;
var r12 = 1 ** E.b;
//// [exponentiationOperatorWithEnum.js]
// operands of an enum type are treated as having the primitive type Number.
var E;
(function (E) {
E[E["a"] = 0] = "a";
E[E["b"] = 1] = "b";
})(E || (E = {}));
var a;
var b;
var c;
// operator **
var r1 = Math.pow(c, a);
var r2 = Math.pow(c, b);
var r3 = Math.pow(c, c);
var r4 = Math.pow(a, c);
var r5 = Math.pow(b, c);
var r6 = Math.pow(E.a, a);
var r7 = Math.pow(E.a, b);
var r8 = Math.pow(E.a, E.b);
var r9 = Math.pow(E.a, 1);
var r10 = Math.pow(a, E.b);
var r11 = Math.pow(b, E.b);
var r12 = Math.pow(1, E.b);
@@ -0,0 +1,98 @@
=== tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorWithEnum.ts ===
// operands of an enum type are treated as having the primitive type Number.
enum E {
>E : Symbol(E, Decl(exponentiationOperatorWithEnum.ts, 0, 0))
a,
>a : Symbol(E.a, Decl(exponentiationOperatorWithEnum.ts, 2, 8))
b
>b : Symbol(E.b, Decl(exponentiationOperatorWithEnum.ts, 3, 6))
}
var a: any;
>a : Symbol(a, Decl(exponentiationOperatorWithEnum.ts, 7, 3))
var b: number;
>b : Symbol(b, Decl(exponentiationOperatorWithEnum.ts, 8, 3))
var c: E;
>c : Symbol(c, Decl(exponentiationOperatorWithEnum.ts, 9, 3))
>E : Symbol(E, Decl(exponentiationOperatorWithEnum.ts, 0, 0))
// operator **
var r1 = c ** a;
>r1 : Symbol(r1, Decl(exponentiationOperatorWithEnum.ts, 12, 3))
>c : Symbol(c, Decl(exponentiationOperatorWithEnum.ts, 9, 3))
>a : Symbol(a, Decl(exponentiationOperatorWithEnum.ts, 7, 3))
var r2 = c ** b;
>r2 : Symbol(r2, Decl(exponentiationOperatorWithEnum.ts, 13, 3))
>c : Symbol(c, Decl(exponentiationOperatorWithEnum.ts, 9, 3))
>b : Symbol(b, Decl(exponentiationOperatorWithEnum.ts, 8, 3))
var r3 = c ** c;
>r3 : Symbol(r3, Decl(exponentiationOperatorWithEnum.ts, 14, 3))
>c : Symbol(c, Decl(exponentiationOperatorWithEnum.ts, 9, 3))
>c : Symbol(c, Decl(exponentiationOperatorWithEnum.ts, 9, 3))
var r4 = a ** c;
>r4 : Symbol(r4, Decl(exponentiationOperatorWithEnum.ts, 15, 3))
>a : Symbol(a, Decl(exponentiationOperatorWithEnum.ts, 7, 3))
>c : Symbol(c, Decl(exponentiationOperatorWithEnum.ts, 9, 3))
var r5 = b ** c;
>r5 : Symbol(r5, Decl(exponentiationOperatorWithEnum.ts, 16, 3))
>b : Symbol(b, Decl(exponentiationOperatorWithEnum.ts, 8, 3))
>c : Symbol(c, Decl(exponentiationOperatorWithEnum.ts, 9, 3))
var r6 = E.a ** a;
>r6 : Symbol(r6, Decl(exponentiationOperatorWithEnum.ts, 17, 3))
>E.a : Symbol(E.a, Decl(exponentiationOperatorWithEnum.ts, 2, 8))
>E : Symbol(E, Decl(exponentiationOperatorWithEnum.ts, 0, 0))
>a : Symbol(E.a, Decl(exponentiationOperatorWithEnum.ts, 2, 8))
>a : Symbol(a, Decl(exponentiationOperatorWithEnum.ts, 7, 3))
var r7 = E.a ** b;
>r7 : Symbol(r7, Decl(exponentiationOperatorWithEnum.ts, 18, 3))
>E.a : Symbol(E.a, Decl(exponentiationOperatorWithEnum.ts, 2, 8))
>E : Symbol(E, Decl(exponentiationOperatorWithEnum.ts, 0, 0))
>a : Symbol(E.a, Decl(exponentiationOperatorWithEnum.ts, 2, 8))
>b : Symbol(b, Decl(exponentiationOperatorWithEnum.ts, 8, 3))
var r8 = E.a ** E.b;
>r8 : Symbol(r8, Decl(exponentiationOperatorWithEnum.ts, 19, 3))
>E.a : Symbol(E.a, Decl(exponentiationOperatorWithEnum.ts, 2, 8))
>E : Symbol(E, Decl(exponentiationOperatorWithEnum.ts, 0, 0))
>a : Symbol(E.a, Decl(exponentiationOperatorWithEnum.ts, 2, 8))
>E.b : Symbol(E.b, Decl(exponentiationOperatorWithEnum.ts, 3, 6))
>E : Symbol(E, Decl(exponentiationOperatorWithEnum.ts, 0, 0))
>b : Symbol(E.b, Decl(exponentiationOperatorWithEnum.ts, 3, 6))
var r9 = E.a ** 1;
>r9 : Symbol(r9, Decl(exponentiationOperatorWithEnum.ts, 20, 3))
>E.a : Symbol(E.a, Decl(exponentiationOperatorWithEnum.ts, 2, 8))
>E : Symbol(E, Decl(exponentiationOperatorWithEnum.ts, 0, 0))
>a : Symbol(E.a, Decl(exponentiationOperatorWithEnum.ts, 2, 8))
var r10 = a ** E.b;
>r10 : Symbol(r10, Decl(exponentiationOperatorWithEnum.ts, 21, 3))
>a : Symbol(a, Decl(exponentiationOperatorWithEnum.ts, 7, 3))
>E.b : Symbol(E.b, Decl(exponentiationOperatorWithEnum.ts, 3, 6))
>E : Symbol(E, Decl(exponentiationOperatorWithEnum.ts, 0, 0))
>b : Symbol(E.b, Decl(exponentiationOperatorWithEnum.ts, 3, 6))
var r11 = b ** E.b;
>r11 : Symbol(r11, Decl(exponentiationOperatorWithEnum.ts, 22, 3))
>b : Symbol(b, Decl(exponentiationOperatorWithEnum.ts, 8, 3))
>E.b : Symbol(E.b, Decl(exponentiationOperatorWithEnum.ts, 3, 6))
>E : Symbol(E, Decl(exponentiationOperatorWithEnum.ts, 0, 0))
>b : Symbol(E.b, Decl(exponentiationOperatorWithEnum.ts, 3, 6))
var r12 = 1 ** E.b;
>r12 : Symbol(r12, Decl(exponentiationOperatorWithEnum.ts, 23, 3))
>E.b : Symbol(E.b, Decl(exponentiationOperatorWithEnum.ts, 3, 6))
>E : Symbol(E, Decl(exponentiationOperatorWithEnum.ts, 0, 0))
>b : Symbol(E.b, Decl(exponentiationOperatorWithEnum.ts, 3, 6))
@@ -0,0 +1,112 @@
=== tests/cases/conformance/es7/exponentiationOperator/exponentiationOperatorWithEnum.ts ===
// operands of an enum type are treated as having the primitive type Number.
enum E {
>E : E
a,
>a : E
b
>b : E
}
var a: any;
>a : any
var b: number;
>b : number
var c: E;
>c : E
>E : E
// operator **
var r1 = c ** a;
>r1 : number
>c ** a : number
>c : E
>a : any
var r2 = c ** b;
>r2 : number
>c ** b : number
>c : E
>b : number
var r3 = c ** c;
>r3 : number
>c ** c : number
>c : E
>c : E
var r4 = a ** c;
>r4 : number
>a ** c : number
>a : any
>c : E
var r5 = b ** c;
>r5 : number
>b ** c : number
>b : number
>c : E
var r6 = E.a ** a;
>r6 : number
>E.a ** a : number
>E.a : E
>E : typeof E
>a : E
>a : any
var r7 = E.a ** b;
>r7 : number
>E.a ** b : number
>E.a : E
>E : typeof E
>a : E
>b : number
var r8 = E.a ** E.b;
>r8 : number
>E.a ** E.b : number
>E.a : E
>E : typeof E
>a : E
>E.b : E
>E : typeof E
>b : E
var r9 = E.a ** 1;
>r9 : number
>E.a ** 1 : number
>E.a : E
>E : typeof E
>a : E
>1 : number
var r10 = a ** E.b;
>r10 : number
>a ** E.b : number
>a : any
>E.b : E
>E : typeof E
>b : E
var r11 = b ** E.b;
>r11 : number
>b ** E.b : number
>b : number
>E.b : E
>E : typeof E
>b : E
var r12 = 1 ** E.b;
>r12 : number
>1 ** E.b : number
>1 : number
>E.b : E
>E : typeof E
>b : E

Some files were not shown because too many files have changed in this diff Show More