Prev: Anybody mind to translate this Felleisen quote from German to English
Next: Macros and anonymous functions
From: Ron Garret on 2 Mar 2010 14:49 On Mar 2, 11:17Â am, Raffael Cavallaro <raffaelcavall...(a)pas.espam.s.il.vous.plait.mac.com> wrote: > On 2010-03-02 11:29:37 -0500, Ron Garret said: > > > If you see a > > Chinese character or a sign language gesture that you don't know, > > there's no way to look it up. > > Well I can't speak to ASL, but this isn't true of chinese - there are > chinese dictionaries - you look characters up by their constituent > radicals. > <http://en.wikipedia.org/wiki/Radical_(Chinese_character)> > -- > Raffael Cavallaro Fine. Could you please tell me what: ã means? (And looking up the unicode code point is cheating.) How about: ï® "That is not Chinese" you object. Yes, that would be precisely the point. It is not that Chinese is completely random. It has rules, just like Perl does. The point is that unless you already know what those rules are you are utterly at sea. This is not the case if you know any latin language and you want to figure out what, say, CON- FROBSHNITZEL means. rg
From: Tamas K Papp on 2 Mar 2010 14:55 On Tue, 02 Mar 2010 18:43:19 +0000, Tim Bradshaw wrote: > On 2010-03-02 17:11:22 +0000, Tamas K Papp said: > >> A somewhat tangential question: lately I am gravitating towards >> SPOTTED-DOG? instead of SPOTTED-DOG-P. Is that "bad style" in CL? >> Looks so much nicer, and appears more intuitive to me. > > > Disgusting scheme heathen, please report for burning. Just to throw another victim to the wolves, I have to confess that I was influenced by reading the source of Gary King's metabang-bind. Eg $ grep '\-p ' *lisp bind.lisp:(defun dotted-pair-p (putative-pair) bind.lisp: ((dotted-pair-p thing) binding-forms.lisp: :use-values-p t) binding-forms.lisp: :use-values-p nil) binding-forms.lisp: :use-values-p nil) binding-forms.lisp: :use-values-p nil) binding-forms.lisp: :use-values-p nil) macros.lisp: description (use-values-p t)) &body body) macros.lisp: (declare (ignorable remove-nils-p description)) $ grep \? *lisp bind.lisp: ;; lexical or special? binding-forms.lisp:(defun handle-plist (variables values form-keywords?) binding-forms.lisp: (when form-keywords? binding-forms.lisp: ,(if form-keywords? macros.lisp: (let* ((multiple-names? (consp name/s)) macros.lisp: (force-keyword? (or multiple-names? macros.lisp: (cond (multiple-names? macros.lisp: (when force-keyword? macros.lisp: (setf name/s (if multiple-names? macros.lisp: ,@(when multiple-names? macros.lisp: (,@(unless multiple-names? macros.lisp: (if force-keyword? Then I realized that ? is more visible (I admit that's subjective), 1 char shorter, and easier to type than -p. There is little hope for me now. Tamas
From: Ron Garret on 2 Mar 2010 15:05 In article <hmjm5r$rgl$1(a)news.eternal-september.org>, Tim Bradshaw <tfb(a)tfeb.org> wrote: > On 2010-03-02 16:52:14 +0000, Ron Garret said: > >> this). > > > > I have already conceded that Common Lisp sucks. But even Common Lisp is > > less sucky than other languages in this regard because it is always > > possible to use READ-FROM-STRING, GET-MACRO-CHARACTER, and MACROEXPAND > > to get an explanation of what is going on in terms of something that you > > can type into a search engine or do a meta-point on. (Except format > > strings of course. Format strings are irredeemably sucky.) > > So, well, I type the letter q into the perldoc search plugin for > Firefox (or equivalently into the perldoc search box, and I get this > page: http://perldoc.perl.org/functions/q.html, as the only hit. How > hard can it be? Pretty hard if you don't know about perldoc. > > You have completely missed the point. Obviously once you *know* Perl > > all these issues evaporate. The issue is what happens when you > > encounter a new construct that you don't already know. > > ... and you can't drive the documentation. Yeah, I guess that can be a > problem. Not being able to drive it is different from being unaware of its existence. a and x remain just as mysterious as ever even with this newfound enlightenment BTW. Not that that matters. rg
From: Ron Garret on 2 Mar 2010 15:08 In article <hmjnps$8s4$1(a)news.eternal-september.org>, Raffael Cavallaro <raffaelcavallaro(a)pas.espam.s.il.vous.plait.mac.com> wrote: > On 2010-03-02 14:04:33 -0500, Raffael Cavallaro said: > > > ./ (i.e., meta-/) > > hmm, don't know how that came out that way: > > ?/ (i.e., meta-/) Wow, that's a well-kept secret. Thanks! rg
From: Rob Warnock on 2 Mar 2010 20:37
Ron Garret <rNOSPAMon(a)flownet.com> wrote: +--------------- | Tamas K Papp <tkpapp(a)gmail.com> wrote: | > A somewhat tangential question: lately I am gravitating towards | > SPOTTED-DOG? instead of SPOTTED-DOG-P. Is that "bad style" in CL? Looks | > so much nicer, and appears more intuitive to me. | | <ironic> | It's considered bad style because that's how they do it in Scheme, and | anything that they do in Scheme must be bad. | </ironic> | | Seriously though, the problem is not so much with the question mark per | se as the inconsistency. Yes, the -P convention is weird, but at least | it's (mostly) consistent. If you start throwing question marks into the | mix then anyone who uses your code has to remember that *these* | predicates use question marks but *those* still use -P. Whether | enjoying the improved aesthetics of question marks is worth the extra | cognitive burden they impose in the context of CL's established | conventions depends on your quality metric. +--------------- Plus, devotees of the pattern-matching sub-sect of CL already tend to use "?" as a *prefix* marker for pattern variables, e.g.: (match (some value form...) ((foo bar ?x baz) (do-something-with ?x)) ((foo ?x bar ?y) (do-something-else-with ?x ?y)) ...) ;-} -Rob ----- Rob Warnock <rpw3(a)rpw3.org> 627 26th Avenue <URL:http://rpw3.org/> San Mateo, CA 94403 (650)572-2607 |