diff --git a/lib/ace/mode/behaviour/cstyle.js b/lib/ace/mode/behaviour/cstyle.js index b8d84157..76e12fc3 100644 --- a/lib/ace/mode/behaviour/cstyle.js +++ b/lib/ace/mode/behaviour/cstyle.js @@ -46,7 +46,7 @@ var CstyleBehaviour = function () { var iterator = new TokenIterator(session, cursor.row, cursor.column); // Don't insert in the middle of a keyword/identifier/lexical - if (!this.$matchTokenType(iterator.getCurrentToken() || "text", ["text"])) { + if (!this.$matchTokenType(iterator.getCurrentToken() || "text", ["text", "paren.rparen"])) { // Look ahead in case we're at the end of a token iterator = new TokenIterator(session, cursor.row, cursor.column + 1); if (!this.$matchTokenType(iterator.getCurrentToken() || "text", ["text", "paren.rparen"]))