Skip to content

Commit

Permalink
Complete rest arguments
Browse files Browse the repository at this point in the history
  • Loading branch information
dgutov committed Jun 12, 2017
1 parent 1576ecc commit 18be639
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
4 changes: 2 additions & 2 deletions ert/completion-tests.el
Expand Up @@ -64,10 +64,10 @@ tee = 4 + qux
(ert-deftest complete-local-variables-includes-method-arguments ()
(insert "
class A
def foo(a1, a2: b2, a3:)
def foo(a1, a2: b2, a3:, *rest)
xyz = 5
")
(should (equal '("xyz" "a3" "a2" "a1")
(should (equal '("xyz" "rest" "a3" "a2" "a1")
(robe-complete--local-variables "foo"))))

(ert-deftest complete-local-variables-includes-block-arguments ()
Expand Down
1 change: 1 addition & 0 deletions robe.el
Expand Up @@ -841,6 +841,7 @@ Only works with Rails, see e.g. `rinari-console'."
(arg-regexp (rx
(or point ?\( ?,)
(* (in " \t\n"))
(* ?*)
(group
(+ (or (syntax ?w) (syntax ?_))))))
(var-regexp (rx
Expand Down

0 comments on commit 18be639

Please sign in to comment.