diff options
| author | Dmitry Antipov | 2014-06-26 11:13:13 +0400 |
|---|---|---|
| committer | Dmitry Antipov | 2014-06-26 11:13:13 +0400 |
| commit | 6e5a5743ddab1142018f20000081184f0bd9dc94 (patch) | |
| tree | a82b4e6a393d26d06d1023147ee13d5ef928dbf8 | |
| parent | 51a3c85711017b70579c08a3342effca9fd7a77b (diff) | |
| download | emacs-6e5a5743ddab1142018f20000081184f0bd9dc94.tar.gz emacs-6e5a5743ddab1142018f20000081184f0bd9dc94.zip | |
* src/fns.c (Fcompare_strings): Use FETCH_STRING_CHAR_AS_MULTIBYTE_ADVANCE.
* lisp/calc/calc-alg.el (math-beforep):
* lisp/progmodes/cc-guess.el (c-guess-view-reorder-offsets-alist-in-style):
Simplify because string-lessp can accept symbols as args.
| -rw-r--r-- | lisp/ChangeLog | 6 | ||||
| -rw-r--r-- | lisp/calc/calc-alg.el | 4 | ||||
| -rw-r--r-- | lisp/progmodes/cc-guess.el | 3 | ||||
| -rw-r--r-- | src/ChangeLog | 4 | ||||
| -rw-r--r-- | src/fns.c | 17 |
5 files changed, 15 insertions, 19 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 850edf64c28..8ff7e5247e6 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -1,3 +1,9 @@ | |||
| 1 | 2014-06-26 Dmitry Antipov <dmantipov@yandex.ru> | ||
| 2 | |||
| 3 | * calc/calc-alg.el (math-beforep): | ||
| 4 | * progmodes/cc-guess.el (c-guess-view-reorder-offsets-alist-in-style): | ||
| 5 | Simplify because string-lessp can accept symbols as args. | ||
| 6 | |||
| 1 | 2014-06-26 Daiki Ueno <ueno@gnu.org> | 7 | 2014-06-26 Daiki Ueno <ueno@gnu.org> |
| 2 | 8 | ||
| 3 | * emacs-lisp/package.el (package--check-signature): If | 9 | * emacs-lisp/package.el (package--check-signature): If |
diff --git a/lisp/calc/calc-alg.el b/lisp/calc/calc-alg.el index 4bd37a4982d..c26b007bb96 100644 --- a/lisp/calc/calc-alg.el +++ b/lisp/calc/calc-alg.el | |||
| @@ -293,7 +293,7 @@ | |||
| 293 | (Math-objectp a)) | 293 | (Math-objectp a)) |
| 294 | ((eq (car a) 'var) | 294 | ((eq (car a) 'var) |
| 295 | (if (eq (car b) 'var) | 295 | (if (eq (car b) 'var) |
| 296 | (string-lessp (symbol-name (nth 1 a)) (symbol-name (nth 1 b))) | 296 | (string-lessp (nth 1 a) (nth 1 b)) |
| 297 | (not (Math-numberp b)))) | 297 | (not (Math-numberp b)))) |
| 298 | ((eq (car b) 'var) (Math-numberp a)) | 298 | ((eq (car b) 'var) (Math-numberp a)) |
| 299 | ((eq (car a) (car b)) | 299 | ((eq (car a) (car b)) |
| @@ -302,7 +302,7 @@ | |||
| 302 | (and b | 302 | (and b |
| 303 | (or (null a) | 303 | (or (null a) |
| 304 | (math-beforep (car a) (car b))))) | 304 | (math-beforep (car a) (car b))))) |
| 305 | (t (string-lessp (symbol-name (car a)) (symbol-name (car b)))))) | 305 | (t (string-lessp (car a) (car b))))) |
| 306 | 306 | ||
| 307 | 307 | ||
| 308 | (defsubst math-simplify-extended (a) | 308 | (defsubst math-simplify-extended (a) |
diff --git a/lisp/progmodes/cc-guess.el b/lisp/progmodes/cc-guess.el index abde007cd04..5424e8d4a61 100644 --- a/lisp/progmodes/cc-guess.el +++ b/lisp/progmodes/cc-guess.el | |||
| @@ -504,8 +504,7 @@ is called with one argument, the guessed style." | |||
| 504 | (cond | 504 | (cond |
| 505 | ((or (and a-guessed? b-guessed?) | 505 | ((or (and a-guessed? b-guessed?) |
| 506 | (not (or a-guessed? b-guessed?))) | 506 | (not (or a-guessed? b-guessed?))) |
| 507 | (string-lessp (symbol-name (car a)) | 507 | (string-lessp (car a) (car b))) |
| 508 | (symbol-name (car b)))) | ||
| 509 | (a-guessed? t) | 508 | (a-guessed? t) |
| 510 | (b-guessed? nil))))))) | 509 | (b-guessed? nil))))))) |
| 511 | style) | 510 | style) |
diff --git a/src/ChangeLog b/src/ChangeLog index 8b0149bc5f4..da46ead2b93 100644 --- a/src/ChangeLog +++ b/src/ChangeLog | |||
| @@ -1,3 +1,7 @@ | |||
| 1 | 2014-06-26 Dmitry Antipov <dmantipov@yandex.ru> | ||
| 2 | |||
| 3 | * fns.c (Fcompare_strings): Use FETCH_STRING_CHAR_AS_MULTIBYTE_ADVANCE. | ||
| 4 | |||
| 1 | 2014-06-25 Dmitry Antipov <dmantipov@yandex.ru> | 5 | 2014-06-25 Dmitry Antipov <dmantipov@yandex.ru> |
| 2 | 6 | ||
| 3 | Consistently use validate_subarray to verify substring. | 7 | Consistently use validate_subarray to verify substring. |
| @@ -268,21 +268,8 @@ If string STR1 is greater, the value is a positive number N; | |||
| 268 | characters, not just the bytes. */ | 268 | characters, not just the bytes. */ |
| 269 | int c1, c2; | 269 | int c1, c2; |
| 270 | 270 | ||
| 271 | if (STRING_MULTIBYTE (str1)) | 271 | FETCH_STRING_CHAR_AS_MULTIBYTE_ADVANCE (c1, str1, i1, i1_byte); |
| 272 | FETCH_STRING_CHAR_ADVANCE_NO_CHECK (c1, str1, i1, i1_byte); | 272 | FETCH_STRING_CHAR_AS_MULTIBYTE_ADVANCE (c2, str2, i2, i2_byte); |
| 273 | else | ||
| 274 | { | ||
| 275 | c1 = SREF (str1, i1++); | ||
| 276 | MAKE_CHAR_MULTIBYTE (c1); | ||
| 277 | } | ||
| 278 | |||
| 279 | if (STRING_MULTIBYTE (str2)) | ||
| 280 | FETCH_STRING_CHAR_ADVANCE_NO_CHECK (c2, str2, i2, i2_byte); | ||
| 281 | else | ||
| 282 | { | ||
| 283 | c2 = SREF (str2, i2++); | ||
| 284 | MAKE_CHAR_MULTIBYTE (c2); | ||
| 285 | } | ||
| 286 | 273 | ||
| 287 | if (c1 == c2) | 274 | if (c1 == c2) |
| 288 | continue; | 275 | continue; |