branch: elpa/dart-mode
commit 67550e51a6b8bd0a900043039e3fd15e9bc75740
Author: Nathan Weizenbaum <[email protected]>
Commit: Nathan Weizenbaum <[email protected]>

    Fix indentation for try as well.
---
 dart-mode.el | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/dart-mode.el b/dart-mode.el
index 011c480..22f5eb6 100644
--- a/dart-mode.el
+++ b/dart-mode.el
@@ -218,8 +218,9 @@ SYNTAX-GUESS is the output of `c-guess-basic-syntax'."
          ;; Both anonymous and named functions have a ")" immediately before 
the
          ;; code block.
          (= (char-before) ?\))
-         ;; "else" is the only keyword that comes immediately before a block.
-         (looking-back "\\<else\\>")
+         ;; "else" and "try" are the only keywords that come immediately before
+         ;; a block.
+         (looking-back "\\<\\(else\\|try\\)\\>")
          ;; CC is good at figuring out if we're in a class.
          (assq 'inclass syntax-guess))))))
 

Reply via email to