Update .gitignore
[riece] / lisp / riece-mode.el
index 4a77940..4256db8 100644 (file)
@@ -1,4 +1,4 @@
-;;; riece-mode.el --- functions for manipulating channel/user modes
+;;; riece-mode.el --- functions for manipulating channel/user modes -*- lexical-binding: t -*-
 ;; Copyright (C) 1998-2003 Daiki Ueno
 
 ;; Author: Daiki Ueno <ueno@unixuser.org>
 
 ;; You should have received a copy of the GNU General Public License
 ;; along with GNU Emacs; see the file COPYING.  If not, write to the
-;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-;; Boston, MA 02111-1307, USA.
+;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+;; Boston, MA 02110-1301, USA.
 
 ;;; Code:
 
 (defun riece-parse-modes (string)
   (let ((start 0)
        result)
-    (while (and (string-match "[-+]\\([^ ]*\\) *" string start)
+    (while (and (string-match "[-+]\\([^-+ ]*\\) *" string start)
                (= (match-beginning 0) start))
-      (let ((toggle (eq (aref string 0) ?+))
+      (let ((toggle (eq (aref string start) ?+))
            (modes (string-to-list (match-string 1 string))))
        (setq start (match-end 0))
        (while modes
@@ -69,4 +69,4 @@ Arguments are appropriate to the flag and the parameter."
 
 (provide 'riece-mode)
 
-;;; riece-mode.el ends here
\ No newline at end of file
+;;; riece-mode.el ends here