Skip to content
Browse files

Removed JetTupleExpression.

  • Loading branch information...
1 parent d9b6a5c commit 0b3437861067c50ccc64155f00672f2a7eac6f64 Evgeny Gerashchenko committed Mar 19, 2013
View
8 compiler/frontend/src/org/jetbrains/jet/lang/cfg/JetControlFlowProcessor.java
@@ -744,14 +744,6 @@ public void visitPropertyAccessor(JetPropertyAccessor accessor) {
}
@Override
- public void visitTupleExpression(JetTupleExpression expression) {
- for (JetExpression entry : expression.getEntries()) {
- generateInstructions(entry, false);
- }
- builder.read(expression);
- }
-
- @Override
public void visitBinaryWithTypeRHSExpression(JetBinaryExpressionWithTypeRHS expression) {
IElementType operationType = expression.getOperationSign().getReferencedNameElementType();
if (operationType == JetTokens.COLON || operationType == JetTokens.AS_KEYWORD || operationType == JetTokens.AS_SAFE) {
View
47 compiler/frontend/src/org/jetbrains/jet/lang/psi/JetTupleExpression.java
@@ -1,47 +0,0 @@
-/*
- * Copyright 2010-2013 JetBrains s.r.o.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.jetbrains.jet.lang.psi;
-
-import com.intellij.lang.ASTNode;
-import com.intellij.psi.util.PsiTreeUtil;
-import org.jetbrains.annotations.NotNull;
-
-import java.util.List;
-
-@Deprecated // Tuples are to be removed in Kotlin M4
-public class JetTupleExpression extends JetExpressionImpl {
-
- @Deprecated // Tuples are to be removed in Kotlin M4
- public JetTupleExpression(@NotNull ASTNode node) {
- super(node);
- }
-
- @Override
- public void accept(@NotNull JetVisitorVoid visitor) {
- visitor.visitTupleExpression(this);
- }
-
- @Override
- public <R, D> R accept(@NotNull JetVisitor<R, D> visitor, D data) {
- return visitor.visitTupleExpression(this, data);
- }
-
- @Deprecated // Tuples are to be removed in Kotlin M4
- public List<JetExpression> getEntries() {
- return PsiTreeUtil.getChildrenOfTypeAsList(this, JetExpression.class);
- }
-}
View
5 compiler/frontend/src/org/jetbrains/jet/lang/psi/JetVisitor.java
@@ -161,11 +161,6 @@ public R visitReferenceExpression(JetReferenceExpression expression, D data) {
return visitExpression(expression, data);
}
- @Deprecated // Tuples are to be removed in Kotlin M4
- public R visitTupleExpression(JetTupleExpression expression, D data) {
- return visitExpression(expression, data);
- }
-
public R visitPrefixExpression(JetPrefixExpression expression, D data) {
return visitUnaryExpression(expression, data);
}
View
5 compiler/frontend/src/org/jetbrains/jet/lang/psi/JetVisitorVoid.java
@@ -151,11 +151,6 @@ public void visitReferenceExpression(JetReferenceExpression expression) {
visitExpression(expression);
}
- @Deprecated // Tuples are to be removed in Kotlin M4
- public void visitTupleExpression(JetTupleExpression expression) {
- visitExpression(expression);
- }
-
public void visitPrefixExpression(JetPrefixExpression expression) {
visitUnaryExpression(expression);
}
View
6 ...r/frontend/src/org/jetbrains/jet/lang/types/expressions/BasicExpressionTypingVisitor.java
@@ -362,12 +362,6 @@ private static boolean hasErasedTypeArguments(
return false;
}
- @Override
- public JetTypeInfo visitTupleExpression(JetTupleExpression expression, ExpressionTypingContext context) {
- // TODO: remove this method completely when tuples are droppped
- throw new IllegalStateException("Tuples are not supported: " + expression.getText());
- }
-
@NotNull
private List<JetType> checkArgumentTypes(@NotNull List<JetType> argumentTypes, @NotNull List<JetExpression> arguments, @NotNull List<TypeProjection> expectedArgumentTypes, @NotNull ExpressionTypingContext context) {
if (arguments.size() == 0 || argumentTypes.size() != arguments.size() || expectedArgumentTypes.size() != arguments.size()) {

0 comments on commit 0b34378

Please sign in to comment.
Something went wrong with that request. Please try again.