Merge from trunk.
[bpt/emacs.git] / lisp / language / thai-word.el
index 3162b50..5cb13e0 100644 (file)
@@ -1,6 +1,6 @@
 ;;; thai-word.el -- find Thai word boundaries
 
-;; Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
+;; Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011
 ;;   National Institute of Advanced Industrial Science and Technology (AIST)
 ;;   Registration Number H14PRO021
 
@@ -8,20 +8,20 @@
 
 ;; Keywords: thai, word break, emacs
 
-;; This program is free software; you can redistribute it and/or modify
+;; This file is part of GNU Emacs.
+
+;; GNU Emacs is free software: you can redistribute it and/or modify
 ;; it under the terms of the GNU General Public License as published by
-;; the Free Software Foundation; either version 2, or (at your option)
-;; any later version.
+;; the Free Software Foundation, either version 3 of the License, or
+;; (at your option) any later version.
 
-;; This program is distributed in the hope that it will be useful,
+;; GNU Emacs is distributed in the hope that it will be useful,
 ;; but WITHOUT ANY WARRANTY; without even the implied warranty of
 ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 ;; GNU General Public License for more details.
 
 ;; 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, 51 Franklin Street, Fifth Floor,
-;; Boston, MA 02110-1301, USA.
+;; along with GNU Emacs.  If not, see <http://www.gnu.org/licenses/>.
 
 ;; The used Thai word list has been taken from IBM's ICU4J project
 ;; (file `thai6.ucs', version 1.4, converted to TIS encoding, with
@@ -65,6 +65,8 @@
 ;;   written authorization of the copyright holder.
 
 
+;;; Commentary:
+
 ;; This file implements an algorithm to find Thai word breaks using a
 ;; dictionary.  It is based on the C program `cttex' written by
 ;; Vuthichai Ampornaramveth <vuthi@nii.ac.jp>.
@@ -10746,8 +10748,7 @@ the current word list."
        (coding-system-for-read 'thai-tis620)
        (table (if append thai-word-table (list 'thai-words))))
     (unwind-protect
-       (save-excursion
-         (set-buffer buf)
+       (with-current-buffer buf
          (insert-file-contents file)
          (goto-char (point-min))
          (while (re-search-forward "\\ct+" nil t)
@@ -11076,4 +11077,3 @@ With argument, do this that many times."
 
 ;; end of thai-word.el
 
-;; arch-tag: 29927f02-e177-4224-a270-7e67210b038a