+
+ (defadvice isearch-update-ring (after sd/isearch-update-ring (string &optional regexp) activate)
+ "Add search-ring to regexp-search-ring"
+ (unless regexp
+ (add-to-history 'regexp-search-ring string regexp-search-ring-max)))
+
+ ;; (defun isearch-update-ring (string &optional regexp)
+ ;; "Add STRING to the beginning of the search ring.
+ ;; REGEXP if non-nil says use the regexp search ring."
+ ;; (add-to-history
+ ;; (if regexp 'regexp-search-ring 'search-ring)
+ ;; string
+ ;; (if regexp regexp-search-ring-max search-ring-max)))