fix constructing qualified types
This commit is contained in:
@@ -129,7 +129,7 @@ class Reader {
|
|||||||
};
|
};
|
||||||
|
|
||||||
// Because macro keys are sorted by length and peekChars(0) returns "", this will be used as the default reader macro:
|
// Because macro keys are sorted by length and peekChars(0) returns "", this will be used as the default reader macro:
|
||||||
readTable[""] = (stream:Stream, k) -> {
|
readTable[""] = (stream:Stream, k:KissState) -> {
|
||||||
var position = stream.position();
|
var position = stream.position();
|
||||||
var token = nextToken(stream, "a symbol name");
|
var token = nextToken(stream, "a symbol name");
|
||||||
// Process dot-access on alias identifiers
|
// Process dot-access on alias identifiers
|
||||||
@@ -138,11 +138,16 @@ class Reader {
|
|||||||
Symbol(token);
|
Symbol(token);
|
||||||
} else {
|
} else {
|
||||||
var tokenParts = token.split(".");
|
var tokenParts = token.split(".");
|
||||||
var fieldExp = Symbol(tokenParts.shift());
|
var fieldExpVal = tokenParts.shift();
|
||||||
while (tokenParts.length > 0) {
|
var fieldExp = Symbol(fieldExpVal);
|
||||||
fieldExp = FieldExp(tokenParts.shift(), fieldExp.withPos(position));
|
if (k.identAliases.exists(fieldExpVal)) {
|
||||||
|
while (tokenParts.length > 0) {
|
||||||
|
fieldExp = FieldExp(tokenParts.shift(), fieldExp.withPos(position));
|
||||||
|
}
|
||||||
|
fieldExp;
|
||||||
|
} else {
|
||||||
|
Symbol(token);
|
||||||
}
|
}
|
||||||
fieldExp;
|
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
Symbol(token);
|
Symbol(token);
|
||||||
|
Reference in New Issue
Block a user