Add chained indentation to js-mode
commit502390822f9c0068898ae41285b37568bf0e4d1c
authorTom Tromey <tom@tromey.com>
Fri, 13 Jan 2017 06:15:00 +0000 (12 23:15 -0700)
committerTom Tromey <tom@tromey.com>
Fri, 13 Jan 2017 19:38:36 +0000 (13 12:38 -0700)
tree08d55c4c60eeb803935779d6541db7ef171b02bd
parentb47f97218efb8d9966e084bdfd8a86e8c47cf81d
Add chained indentation to js-mode

Bug#20896
* lisp/progmodes/js.el (js-chain-indent): New variable.
(js--skip-term-backward, js--skip-terms-backward)
(js--chained-expression-p): New functions.
(js--proper-indentation): Call js--chained-expression-p.
* test/manual/indent/js-chain.js: New file.
* test/manual/indent/js.js: Add (non-)chained indentation test.
lisp/progmodes/js.el
test/manual/indent/js-chain.js [new file with mode: 0644]
test/manual/indent/js.js