CVS update by viteno xemacs/lisp ...
xemacs-cvs at xemacs.org
xemacs-cvs at xemacs.org
Mon Sep 3 09:16:48 EDT 2007
User: viteno
Date: 07/09/03 15:16:48
Modified: xemacs/lisp ChangeLog byte-optimize.el package-get.el
Log:
Steve Youngs' commit 'bot
Revision Changes Path
1.836 +16 -0 XEmacs/xemacs/lisp/ChangeLog
Index: ChangeLog
===================================================================
RCS file: /pack/xemacscvs/XEmacs/xemacs/lisp/ChangeLog,v
retrieving revision 1.835
retrieving revision 1.836
diff -u -p -r1.835 -r1.836
--- ChangeLog 2007/08/31 08:34:25 1.835
+++ ChangeLog 2007/09/03 13:16:39 1.836
@@ -1,3 +1,19 @@
+2007-09-02 Steve Youngs <steve at sxemacs.org>
+
+ * byte-optimize.el (byte-optimize-featurep): New. Optimise
+ feature 'sxemacs to nil and 'xemacs to t. This is along the same
+ lines as GNU/Emacs where they optimise both 'xemacs and 'sxemacs
+ to nil. It has the added advantage of suppressing byte-compiler
+ warnings in most cases.
+
+ * package-get.el (package-get-pgp-available-p): Removed.
+ (package-get-require-signed-base-updates): Ditto.
+ (package-entries-are-signed): Ditto.
+ (package-get-pgp-signed-begin-line): Ditto.
+ (package-get-pgp-signature-begin-line): Ditto.
+ (package-get-pgp-signature-end-line): Ditto.
+ (package-get-update-base-from-buffer): Remove the PGP nonsense.
+
2007-08-29 Didier Verna <didier at xemacs.org>
* files.el (files-fetch-hook-value): Preserve locality of hooks by
1.11 +9 -0 XEmacs/xemacs/lisp/byte-optimize.el
Index: byte-optimize.el
===================================================================
RCS file: /pack/xemacscvs/XEmacs/xemacs/lisp/byte-optimize.el,v
retrieving revision 1.10
retrieving revision 1.11
diff -u -p -r1.10 -r1.11
--- byte-optimize.el 2003/02/14 11:50:36 1.10
+++ byte-optimize.el 2007/09/03 13:16:43 1.11
@@ -1168,6 +1168,15 @@
(if constant
(eval form)
form)))
+
+(put 'featurep 'byte-optimizer 'byte-optimize-featurep)
+(defun byte-optimize-featurep (form)
+ (let ((str (prin1-to-string (cdr-safe form)))
+ (regex #r"\s-+s?xemacs\(\s-\|)\)"))
+ (if (string-match regex str)
+ (byte-optimize-predicate form)
+ form)))
+
;;; enumerating those functions which need not be called if the returned
;;; value is not used. That is, something like
1.83 +2 -84 XEmacs/xemacs/lisp/package-get.el
Index: package-get.el
===================================================================
RCS file: /pack/xemacscvs/XEmacs/xemacs/lisp/package-get.el,v
retrieving revision 1.82
retrieving revision 1.83
diff -u -p -r1.82 -r1.83
--- package-get.el 2007/08/20 22:29:32 1.82
+++ package-get.el 2007/09/03 13:16:44 1.83
@@ -395,50 +395,6 @@ Otherwise respect the `force-current' ar
:type 'boolean
:group 'package-get)
-(defun package-get-pgp-available-p ()
- "Checks the availability of Mailcrypt and PGP executable.
-
-Returns t if both are found, nil otherwise. As a side effect, set
-`mc-default-scheme' dependent on the PGP executable found."
- (let (result)
- (when (featurep 'mailcrypt-autoloads)
- (autoload 'mc-setversion "mc-setversion"))
- (when-fboundp 'mc-setversion
- (cond ((locate-file "gpg" exec-path
- '("" ".btm" ".bat" ".cmd" ".exe" ".com")
- 'executable)
- (mc-setversion "gpg")
- (setq result t))
- ((locate-file "pgpe" exec-path
- '("" ".btm" ".bat" ".cmd" ".exe" ".com")
- 'executable)
- (mc-setversion "5.0")
- (setq result t))
- ((locate-file "pgp" exec-path
- '("" ".btm" ".bat" ".cmd" ".exe" ".com")
- 'executable)
- (mc-setversion "2.6")
- (setq result t))))
- (if result
- result
- nil)))
-
-(defcustom package-get-require-signed-base-updates (package-get-pgp-available-p)
- "*If non-nil, try to verify the package index database via PGP.
-
-If nil, no PGP verification is done. If the package index database
-entries are not PGP signed and this variable is non-nil, require user
-confirmation to continue with the package-get procedure.
-
-The default for this variable is the return value of
-`package-get-pgp-available-p', non-nil if both the \"Mailcrypt\"
-package and a suitable PGP executable are available, nil otherwise."
-:type 'boolean
-:group 'package-get)
-
-(defvar package-entries-are-signed nil
- "Non-nil when the package index file has been PGP signed.")
-
(defvar package-get-continue-update-base nil
"Non-nil update the index even if it hasn't been signed.")
@@ -466,13 +422,6 @@ and remote access is likely in the near
"Package-get database not loaded")
(setq package-get-was-current force-current)))
-(defconst package-get-pgp-signed-begin-line "^-----BEGIN PGP SIGNED MESSAGE-----"
- "Text for start of PGP signed messages.")
-(defconst package-get-pgp-signature-begin-line "^-----BEGIN PGP SIGNATURE-----"
- "Text for beginning of PGP signature.")
-(defconst package-get-pgp-signature-end-line "^-----END PGP SIGNATURE-----"
- "Text for end of PGP signature.")
-
;;;###autoload
(defun package-get-update-base-entry (entry)
"Update an entry in `package-get-base'."
@@ -600,39 +549,8 @@ used interactively, for example from a m
(goto-char (point-min))
(setq content-beg (point))
(setq content-end (save-excursion (goto-char (point-max)) (point)))
- (when (re-search-forward package-get-pgp-signed-begin-line nil t)
- (setq content-beg (match-end 0)))
- (when (re-search-forward package-get-pgp-signature-begin-line nil t)
- (setq content-end (match-beginning 0))
- (setq package-entries-are-signed t))
- (re-search-forward package-get-pgp-signature-end-line nil t)
- (setq package-get-continue-update-base t)
- ;; This is a little overkill because the default value of
- ;; `package-get-require-signed-base-updates' is the return of
- ;; `package-get-pgp-available-p', but we have to allow for
- ;; someone explicitly setting
- ;; `package-get-require-signed-base-updates' to t. --SY
- (when (and package-get-require-signed-base-updates
- (package-get-pgp-available-p))
- (if package-entries-are-signed
- (let (good-sig)
- (setq package-get-continue-update-base nil)
- (autoload 'mc-verify "mc-toplev")
- (when (declare-fboundp (mc-verify))
- (setq good-sig t))
- (if good-sig
- (setq package-get-continue-update-base t)
- (error 'process-error
- "GnuPG error. Package database not updated")))
- (if (yes-or-no-p
- "Package Index is not PGP signed. Continue anyway? ")
- (setq package-get-continue-update-base t)
- (setq package-get-continue-update-base nil)
- (warn "Package database not updated"))))
- ;; ToDo: We should call package-get-maybe-save-index on the region
- (when package-get-continue-update-base
- (package-get-update-base-entries content-beg content-end)
- (message "Updated package database")))))
+ (package-get-update-base-entries content-beg content-end)
+ (message "Updated package database"))))
(defun package-get-update-base-entries (start end)
"Update the package-get database with the entries found between
More information about the XEmacs-CVS
mailing list