On Tue, Dec 06 2005, Uwe Brauer wrote:
(if (featurep 'xemacs)
code for xemacs
)
(when (featurep 'xemacs)
xemacs-code)
But what if I had code specifically for GNU emacs.
(unless (featurep 'xemacs)
emacs-code)
(if (featurep 'xemacs)
xemacs-code
emacs-code)
Would the following be a good idea? Taken from the .emacs skeleton
file.
(defvar running-xemacs (string-match "XEmacs\\|Lucid" emacs-version))
IMHO: No. The byte compiler of Emacs is able to ignore the (featurep
'xemacs) parts when compiling with Emacs. I don't know if XEmacs byte
compiler has the same feature.
Or are there better solutions?
Test for features (`featurep') , functions (`fboundp') or variables
(`boundp') instead of versions.
Bye, Reiner.
--
,,,
(o o)
---ooO-(_)-Ooo--- | PGP key available |
http://rsteib.home.pages.de/