From: Kazuhiro NISHIYAMA Date: 2003-02-23T02:46:46+09:00 Subject: [ruby-dev:19646] Re: compare between String and Exception 西山和広です。 In <1045773281.614432.25616.nullmailer@picachu.netlab.jp> On Fri, 21 Feb 2003 05:34:47 +0900 matz@ruby-lang.org (Yukihiro Matsumoto) wrote: > a <=> b > > は > > * aがstringで > * bがstringでないなら > * to_strを定義していなければnil > * <=>が定義されていなければnil > * でなければ 0-(b<=>a) 単なる疑問なのですが、 -(b<=>a) (<=>の結果の-@(単項マイナス)) ではなく 0-(b<=>a) なのはなぜなのでしょうか? -- |ZnZ(ゼット エヌ ゼット) |西山和広(Kazuhiro NISHIYAMA)