.emacs-my
changeset 1010 6b1ecdc690c1
parent 1003 8c1abe90331a
parent 1009 c6e2c636296f
child 1011 0cf901dc1c1f
equal deleted inserted replaced
1003:8c1abe90331a 1010:6b1ecdc690c1
  2327 (if (>= emacs-major-version 23)
  2327 (if (>= emacs-major-version 23)
  2328     (add-to-list 'auto-mode-alist '("\\.js$" . js-mode))
  2328     (add-to-list 'auto-mode-alist '("\\.js$" . js-mode))
  2329   (add-to-list 'auto-mode-alist '("\\.js$" . javascript-generic-mode))
  2329   (add-to-list 'auto-mode-alist '("\\.js$" . javascript-generic-mode))
  2330   )
  2330   )
  2331 
  2331 
       
  2332 (eval-after-load 'js-mode
       
  2333   '(progn
       
  2334      (modify-syntax-entry ?$ "w" js-mode-syntax-table)
       
  2335      ))
       
  2336 
  2332 ;; BUG: all single char comments do not stop highlighting on end of line but
  2337 ;; BUG: all single char comments do not stop highlighting on end of line but
  2333 ;; go to end of buffer. To fix use code:
  2338 ;; go to end of buffer. To fix use code:
  2334 ;; (setq auto-mode-alist (rassq-delete-all 'js-mode auto-mode-alist))
  2339 ;; (setq auto-mode-alist (rassq-delete-all 'js-mode auto-mode-alist))
  2335 ;; (add-to-list 'auto-mode-alist '("\\.js$" . c++-mode))
  2340 ;; (add-to-list 'auto-mode-alist '("\\.js$" . c++-mode))
  2336 
  2341