Re: [twmode-users] string抽出部の改善

2009-12-28 スレッド表示 yata_github
やたがわです。

twitter.comから返ってくるXMLが壊れていることがあって、それを
そのままxml-parse-region()に渡すとその先でエラーになってしまい
悲しいです。ですので、

(1) twittering-get-response-body()のxml-parse-region()を
condition-caseで囲み、その場合は明示的にnilを返すように
しました。

(2) twittering-http-get-default-sentinel()を(1)に対応させました。

(3) twittering-http-post-default-sentinel()でcondition-caseを
使う意味は(1)でなくなったと思うので、それを削除しました。

をtopic branchにしてみました。

http://github.com/yata/twittering-mode/tree/failsafe-get-response-body

 twittering-get-response-body()ではbody部分を
 xml-parse-region()に渡すためにbuffer-string()でサイズを
 調べていましたが、search-forward-regexp()で開始部分を
 直接調べてxml-parse-region()に渡すようにしました。

--
This SF.Net email is sponsored by the Verizon Developer Community
Take advantage of Verizon's best-in-class app development support
A streamlined, 14 day to market process makes app distribution fast and easy
Join now and get one step closer to millions of Verizon customers
http://p.sf.net/sfu/verizon-dev2dev 
___
twmode-users mailing list
twmode-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/twmode-users


Re: [twmode-users] string抽出部の改善

2009-12-28 スレッド表示 yata_github
 これは知らなかったです。プログラムから呼び出すことが非推奨な関数の使用
 は、掘り返せばまだ出てきそうな気がしますね。

ちょっと違うかもしれませんが、個人的にはこれも気になります。

http://www.gnu.org/software/emacs/manual/html_node/cl/Overview.html

以下引用。

Please note: the CL functions are not standard parts of the
Emacs Lisp name space, so it is legitimate for users to define
them with other, conflicting meanings. To avoid conflicting with
those user activities, we have a policy that packages installed
in Emacs must not load CL at run time. (It is ok for them to
load CL at compile time only, with eval-when-compile, and use
the macros it provides.) If you are writing packages that you
plan to distribute and invite widespread use for, you might want
to observe the same rule.

--
This SF.Net email is sponsored by the Verizon Developer Community
Take advantage of Verizon's best-in-class app development support
A streamlined, 14 day to market process makes app distribution fast and easy
Join now and get one step closer to millions of Verizon customers
http://p.sf.net/sfu/verizon-dev2dev 
___
twmode-users mailing list
twmode-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/twmode-users


Re: [twmode-users] string抽出部の改善

2009-12-28 スレッド表示 Yuto Hayamizu

はやみずです

 Please note: the CL functions are not standard parts of the
 Emacs Lisp name space, so it is legitimate for users to define
 them with other, conflicting meanings. To avoid conflicting with
 those user activities, we have a policy that packages installed
 in Emacs must not load CL at run time. (It is ok for them to
 load CL at compile time only, with eval-when-compile, and use
 the macros it provides.) If you are writing packages that you
 plan to distribute and invite widespread use for, you might want
 to observe the same rule.

clパッケージは非推奨だとかいう話をIMAKADOさんから聞いたことがあったので
すが、このことだったんですね。この書き方だと

(require 'cl)

を

(eval-when-compile (require 'cl))

にすればよいということですね。標準添付の minibuffer.el を見てみたらこう
なっていたので間違いないでしょう。マクロ展開時のみclパッケージが使われ
るようにするべき、ということでしょう。

さくっと変更しておきます。

# ところで体調のほうは大丈夫ですか?


Yuto Hayamizu

Master's degree student at Kitsuregawa Laboratory
Department of Information and Communication Engineering
Graduate School of Information Science and Technology
University of Tokyo

From: yata_git...@y.haun.org
Subject: Re: [twmode-users] string抽出部の改善
Date: Tue, 29 Dec 2009 01:49:29 +0900 (JST)

 これは知らなかったです。プログラムから呼び出すことが非推奨な関数の使用
 は、掘り返せばまだ出てきそうな気がしますね。
 
 ちょっと違うかもしれませんが、個人的にはこれも気になります。
 
 http://www.gnu.org/software/emacs/manual/html_node/cl/Overview.html
 
 以下引用。
 
 Please note: the CL functions are not standard parts of the
 Emacs Lisp name space, so it is legitimate for users to define
 them with other, conflicting meanings. To avoid conflicting with
 those user activities, we have a policy that packages installed
 in Emacs must not load CL at run time. (It is ok for them to
 load CL at compile time only, with eval-when-compile, and use
 the macros it provides.) If you are writing packages that you
 plan to distribute and invite widespread use for, you might want
 to observe the same rule.
 
 --
 This SF.Net email is sponsored by the Verizon Developer Community
 Take advantage of Verizon's best-in-class app development support
 A streamlined, 14 day to market process makes app distribution fast and easy
 Join now and get one step closer to millions of Verizon customers
 http://p.sf.net/sfu/verizon-dev2dev 
 ___
 twmode-users mailing list
 twmode-users@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/twmode-users

--
This SF.Net email is sponsored by the Verizon Developer Community
Take advantage of Verizon's best-in-class app development support
A streamlined, 14 day to market process makes app distribution fast and easy
Join now and get one step closer to millions of Verizon customers
http://p.sf.net/sfu/verizon-dev2dev 
___
twmode-users mailing list
twmode-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/twmode-users