Fix precedence on isIndex blocks.

This commit is contained in:
Neil Fraser
2016-06-09 18:04:14 -07:00
parent dcc7de52a5
commit ef417d7a60
7 changed files with 13 additions and 14 deletions

View File

@@ -100,7 +100,7 @@ Blockly.Python['text_indexOf'] = function(block) {
var argument1 = Blockly.Python.valueToCode(block, 'VALUE',
Blockly.Python.ORDER_MEMBER) || '\'\'';
var code = argument1 + '.' + operator + '(' + argument0 + ') + 1';
return [code, Blockly.Python.ORDER_MEMBER];
return [code, Blockly.Python.ORDER_ADDITIVE];
};
Blockly.Python['text_charAt'] = function(block) {