if (how == IN_ASSIGN) {
inAssing = true;
exprType value = node.value;
String rep = NodeUtils.getRepresentationString(value);
SourceToken methodTok = null;
if (rep != null) {
methodTok = repToTokenWithArgs.get(rep);
//The use case is the following: we have a method and an assign to it:
//def method(a, b):
// ...
//other = method
//
//and later on, we want the arguments for 'other' to be the same arguments for 'method'.
}
for (int i = 0; i < node.targets.length; i++) {
if (node.targets[i] instanceof Attribute) {
visitAttribute((Attribute) node.targets[i]);
} else if (node.targets[i] instanceof Name && inFuncDef == false) {
String id = ((Name) node.targets[i]).id;
if (id != null) {
SourceToken added = addToken(node.targets[i]);
if (methodTok != null) {
added.updateAliasToken(methodTok);
}
}
} else if (node.targets[i] instanceof Tuple && inFuncDef == false) {
//that's for finding the definition: a,b,c = range(3) inside a class definition