Commit e891c285 authored by Kevin Modzelewski's avatar Kevin Modzelewski

notes

parent 9146799c
......@@ -878,7 +878,8 @@ assembler::Register Rewriter::allocReg(Location dest) {
if (vars_by_location.count(reg) == 0)
return reg;
}
return allocReg(assembler::R15); // seem as fine as any
// TODO maybe should do some sort of round-robin or LRU eviction strategy?
return allocReg(assembler::R15);
} else if (dest.type == Location::Register) {
assembler::Register reg(dest.regnum);
......
......@@ -579,9 +579,6 @@ private:
AST_expr* remapGeneratorExp(AST_GeneratorExp* node) {
assert(node->generators.size());
// I don't think it's easy to determine by the user, but it looks like the first generator iterator gets
// evaluated in the parent scope / frame.
AST_expr* first = remapExpr(node->generators[0]->iter);
AST_FunctionDef* func = new AST_FunctionDef();
......
......@@ -2640,12 +2640,14 @@ extern "C" Box* getitem(Box* value, Box* slice) {
if (rtn == NULL) {
// different versions of python give different error messages for this:
if (PYTHON_VERSION_MAJOR == 2 && PYTHON_VERSION_MINOR < 7) {
raiseExcHelper(TypeError, "'%s' object is unsubscriptable", getTypeName(value)->c_str()); // 2.6.6
raiseExcHelper(TypeError, "'%s' object is unsubscriptable", getTypeName(value)->c_str()); // tested on 2.6.6
} else if (PYTHON_VERSION_MAJOR == 2 && PYTHON_VERSION_MINOR == 7 && PYTHON_VERSION_MICRO < 3) {
raiseExcHelper(TypeError, "'%s' object is not subscriptable", getTypeName(value)->c_str()); // 2.7.1
raiseExcHelper(TypeError, "'%s' object is not subscriptable",
getTypeName(value)->c_str()); // tested on 2.7.1
} else {
// Changed to this in 2.7.3:
raiseExcHelper(TypeError, "'%s' object has no attribute '__getitem__'",
getTypeName(value)->c_str()); // 2.7.3
getTypeName(value)->c_str()); // tested on 2.7.3
}
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment