* Robert Widhopf-Fenk (2006-12-15 21:59 +0100) said:
^^^^^^^^^^^^^^^^^^^
> On Friday, December 15, 2006 at 19:43:23, Leo wrote:
>> * Robert Widhopf-Fenk (2006-12-15 20:06 +0100) said:
>> ^^^^^^^^^^^^^^^^^^^
>> [...]
>
>> >> > > I have been using BBDB for a few years. I am wondering if
>> >> > > there is a new release coming up.
>> >
>> > It is 6.5 years since the last release and since then there
>> > have been a reasonable number of bugfixes and improvements.
>> >
>> > So let us release 2.35 and switch to 2.36 in CVS ;-)
>>
>> That's good news to all users of bbdb.
>>
>> Can I suggest the following:
>> - clean up compiling warnings in Emacs 22
>
> Patches are appreciated for this, but 22 is not stable and
> thus do not expect anything for it ;-)
GNU Emacs 22 is currently under pretest stage. Very stable. As a
matter of fact I am running Emacs 23 and it is quite stable also.
I check that Emacs 21 and Xemacs 21 both have string-to-number. So I
change string-to-int to string-to-number to get rid of tens of
warnings.
cvs diff: Diffing .
Index: bbdb-com.el
===================================================================
RCS file: /cvsroot/bbdb/bbdb/lisp/bbdb-com.el,v
retrieving revision 1.177
diff -u -r1.177 bbdb-com.el
--- bbdb-com.el 15 Dec 2006 20:38:30 -0000 1.177
+++ bbdb-com.el 15 Dec 2006 21:27:01 -0000
@@ -2933,7 +2933,7 @@
(condition-case nil
(play-sound (list 'sound
:file (aref bbdb-sound-files
- (string-to-int num))
+ (string-to-number num))
:volume (or volume bbdb-sound-volume)))
(error nil)))
(if (and bbdb-sound-player
Index: bbdb-migrate.el
===================================================================
RCS file: /cvsroot/bbdb/bbdb/lisp/bbdb-migrate.el,v
retrieving revision 1.21
diff -u -r1.21 bbdb-migrate.el
--- bbdb-migrate.el 11 Aug 2005 03:22:31 -0000 1.21
+++ bbdb-migrate.el 15 Dec 2006 21:27:01 -0000
@@ -216,7 +216,7 @@
(zip (cond ((string-match "^[ \t\n]*$" string) 0)
;; Matches 1 to 6 digits.
((string-match "^[ \t\n]*[0-9][0-9]?[0-9]?[0-9]?[0-9]?[0-9]?[ \t\n]*$" string)
- (string-to-int string))
+ (string-to-number string))
;; Matches 5 digits and 3 or 4 digits.
((string-match "^[ \t\n]*\\([0-9][0-9][0-9][0-9][0-9]\\)[ \t\n]*-?[ \t\n]*\\([0-9][0-9][0-9][0-9]?\\)[ \t\n]*$" string)
(list (bbdb-subint string 1) (bbdb-subint string 2)))
@@ -270,9 +270,9 @@
["0" "0" "0" "0" nil])
(cond ((string-match
"^\\([0-9]\\{4\\}\\)[-/]\\([ 0-9]?[0-9]\\)[-/]\\([ 0-9]?[0-9]\\)" date)
- (setq parsed (vector (string-to-int (match-string 1 date))
- (string-to-int (match-string 2 date))
- (string-to-int (match-string 3 date))))
+ (setq parsed (vector (string-to-number (match-string 1 date))
+ (string-to-number (match-string 2 date))
+ (string-to-number (match-string 3 date))))
;; This should be fairly loud for GNU Emacs users
(bbdb-warn "BBDB is treating %s field value %s as %s %d %d"
(car field) (cdr field)
@@ -282,9 +282,9 @@
(aref parsed 2) (aref parsed 0)))
((string-match
"^\\([ 0-9]?[0-9]\\)[-/]\\([ 0-9]?[0-9]\\)[-/]\\([0-9]\\{4\\}\\)" date)
- (setq parsed (vector (string-to-int (match-string 3 date))
- (string-to-int (match-string 1 date))
- (string-to-int (match-string 2 date))))
+ (setq parsed (vector (string-to-number (match-string 3 date))
+ (string-to-number (match-string 1 date))
+ (string-to-number (match-string 2 date))))
;; This should be fairly loud for GNU Emacs users
(bbdb-warn "BBDB is treating %s field value %s as %s %d %d"
(car field) (cdr field)
@@ -296,11 +296,11 @@
;; I like numbers
(and (stringp (aref parsed 0))
- (aset parsed 0 (string-to-int (aref parsed 0))))
+ (aset parsed 0 (string-to-number (aref parsed 0))))
(and (stringp (aref parsed 1))
- (aset parsed 1 (string-to-int (aref parsed 1))))
+ (aset parsed 1 (string-to-number (aref parsed 1))))
(and (stringp (aref parsed 2))
- (aset parsed 2 (string-to-int (aref parsed 2))))
+ (aset parsed 2 (string-to-number (aref parsed 2))))
;; Sanity check
(cond ((and (< 0 (aref parsed 0))
Index: bbdb.el
===================================================================
RCS file: /cvsroot/bbdb/bbdb/lisp/bbdb.el,v
retrieving revision 1.230
diff -u -r1.230 bbdb.el
--- bbdb.el 9 Oct 2006 22:57:28 -0000 1.230
+++ bbdb.el 15 Dec 2006 21:27:01 -0000
@@ -1070,7 +1070,7 @@
(list 'bbdb-record-sortkey record2)))
(defmacro bbdb-subint (string match-number)
- (list 'string-to-int
+ (list 'string-to-number
(list 'substring string
(list 'match-beginning match-number)
(list 'match-end match-number))))
@@ -1223,9 +1223,9 @@
present). Returns a string containing the date in the new format."
(let ((parts (bbdb-split date "-")))
(format-time-string (or format bbdb-time-display-format)
- (encode-time 0 0 0 (string-to-int (caddr parts))
- (string-to-int (cadr parts))
- (string-to-int (car parts))))))
+ (encode-time 0 0 0 (string-to-number (caddr parts))
+ (string-to-number (cadr parts))
+ (string-to-number (car parts))))))
(defalias 'bbdb-format-record-timestamp 'bbdb-time-convert)
(defalias 'bbdb-format-record-creation-date 'bbdb-time-convert)
>
>> - Add last name completion support (as discussed in another
>> thread)
>
> It eventually land in CVS after some testing.
Haven't seen the change.
>
>> - (Optional) Offer to save record when sending emails to a
>> recipient not yet in the database.
>
> The function `bbdb-force-record-create' is your friend!
>
> For VM you might have the following in your ~/.vm ...
>
> (add-hook 'vm-reply-hook 'bbdb-force-record-create)
I will have a look at this function.
--
Leo <sdl.web AT gmail.com> (GPG Key: 9283AA3F)
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
bbdb-info@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bbdb-info
BBDB Home Page: http://bbdb.sourceforge.net/