From: Mathieu Bouchard Date: 2002-01-01T18:30:27+09:00 Subject: [ruby-talk:29940] Re: Ruby/Python: Software Engineering On Tue, 1 Jan 2002, Quentin Crain wrote: >That perspective doesn't exist, because there are many of them. AFAIK, >methodologies like XP and PragProg (which are the most popular among Ruby >users) carefully avoid dictating coding or cosmetics and instead >concentrate on the whole authorship process. > I am not sure how to reconcile with: > Code must be formatted to agreed coding standards. > [ http://www.extremeprogramming.org/rules/standards.html ] > We all code to the exact same standards. > [ http://www.xprogramming.com/Practices/PracCodingStandards.html ] > Develop and adopt formal style standards. > [ http://c2.com/cgi/wiki?FormalStandards ] Those three documents agree on one thing: it's a good thing to have an official style and follow it. Note that none of those concentrate on particular style elements; instead they concentrate on making communication smoother (authorship process), for which coding style is one of the means (and the details are not specified by the methodology). > >You are relatively safe with either Ruby or Python. The biggest offenders > >may be C (buffer overflows, too many typecasting) and shell-scripts > >(quoting hell). Perl is safe compared to those, but still lacks exception > >handling, which makes it overhead to write correct code. > But what about methodologies? How does Ruby help (or hinder) me there? Methodologies you think about probably encourage program correctness, which is the example I used above. If I take another example... In Ruby, the cost of writing objects/classes is the same as writing just procedures, so the language encourages reuse. In a language where you have to sprinkle OO code with "self", there's an incentive to use plain procedures (and global resources) instead. Do you want another such example? You see, I can't give you a complete picture quickly, because I have not researched on the topic prior to this discussion. > > > A language is more than its syntax--it ought to fit into a > > > methodology, encourage adherence, > >A language is there to allow, not to restrict. > Any and all languages do both. Yes, because the goal is to allow, which has a side-effect of restricting other things. But there shouldn't be a goal of restricting. There shouldn't be language elements that are there only to restrict. > And by being "pure"-OO does that not restrict "pure OO" happens to be the idea of structured programming pushed to its maximum. It happens to include former (lesser) incarnations of structured programming. > to a particular paradigm? Of course, choosing a p*** restricts you to a p***... that's what the word means. Consider yourself lucky not to have to write all your code as dataflow diagrams. "pure OO" is a surprisingly gentle p***... but you have used the p-word. prepare to be desintegrated. =) ________________________________________________________________ Mathieu Bouchard http://hostname.2y.net/~matju