]> git.eshelyaron.com Git - emacs.git/commitdiff
(flymake-float-time): Instead of with-no-warnings, test for xemacs.
authorRichard M. Stallman <rms@gnu.org>
Wed, 6 Jul 2005 19:03:21 +0000 (19:03 +0000)
committerRichard M. Stallman <rms@gnu.org>
Wed, 6 Jul 2005 19:03:21 +0000 (19:03 +0000)
(flymake-replace-regexp-in-string): Test fboundp of replace-in-string
to avoid warning.

lisp/ChangeLog
lisp/progmodes/flymake.el

index f598df3cd1d93d15a3d6ca07b52904c7a3326465..df7a4b270eadd4e435705d36a6b45a99a07fb8d4 100644 (file)
@@ -1,3 +1,10 @@
+2005-07-06  Richard M. Stallman  <rms@gnu.org>
+
+       * progmodes/flymake.el (flymake-float-time): Instead of
+       with-no-warnings, test for xemacs.
+       (flymake-replace-regexp-in-string): Test fboundp of replace-in-string
+       to avoid warning.
+
 2005-07-06  Juanma Barranquero  <lekktu@gmail.com>
 
        * w32-vars.el (w32-fixed-font-alist): Fix typo in `defcustom' tag.
index 0fb5411e7988fa421bdc24180e3115d78912eb3a..4c5f3ad12b9027e800bdd227e2160378fc119072 100644 (file)
 (defalias 'flymake-float-time
   (if (fboundp 'float-time)
       'float-time
-    (with-no-warnings
-      (lambda ()
-        (multiple-value-bind (s0 s1 s2) (current-time)
-          (+ (* (float (ash 1 16)) s0) (float s1) (* 0.0000001 s2)))))))
+    (if (featurep 'xemacs)
+       (lambda ()
+         (multiple-value-bind (s0 s1 s2) (current-time)
+           (+ (* (float (ash 1 16)) s0) (float s1) (* 0.0000001 s2)))))))
 
 (defsubst flymake-replace-regexp-in-string (regexp rep str)
-  (if (fboundp 'replace-regexp-in-string)
-      (replace-regexp-in-string regexp rep str)
-    (replace-in-string str regexp rep)))
+  (if (fboundp 'replace-in-string)
+      (replace-in-string str regexp rep)
+    (replace-regexp-in-string regexp rep str)))
 
 (defun flymake-split-string (str pattern)
   "Split STR into a list of substrings bounded by PATTERN.