1,637 reputation
312
bio website
location
age 23
visits member for 2 years, 11 months
seen Apr 9 at 21:36

Mar
26
comment Will javascript be in the HTML5 standard
HTML5 is a really bad name. In the end it is more about standardizing common existing stuff from web browsers that were not in a standard yet. This ranges from the parsing algorithm for malformed HTML to Javascript APIs to things like video and so on.
Mar
26
comment if/else statements or exceptions
This argument is a common one but I find it hard to use as a good rule of thumb. IN the really tricky case its hard to decide whether something is "rare" or not.
Mar
13
comment Why are statements in many programming languages terminated by semicolons?
-1; Come on guys, have we all forgotten the hugely influential ALGOL? It had semicolons as statement separators before everything else you are mentioning. (I don't know if it took the idea from somewhere else though)
Feb
27
comment Coding Guideline : Methods shouldn't contain more than 7 statements?
I think the important rule of thumb is checking if the submethods are orthogonal. If they are independent, can be called in any order and respect the class invariant then its better to keep them separate. If the methods are tightly coupled, break class invariants and/or need to be called in a certain order then perhaps it is better to keep them together.
Feb
24
comment How can I translate ML code to F#?
@JonHarrop: Do you think the problem was only in doing the direct translation (due to the different module systems) or did you think there is something in the F# way of doing things that was getting in your way?
Feb
6
comment When stuck, how quickly should one resort to Stack Overflow?
I think this should probably habe been asked on SO's Meta.
Jan
31
comment What are the features required for Object Orientation?
I have often heard this same definition but I have to confess that, as a language nerd, I detest it. Encapsulation is not unique to OO (ADTs came first) and many OO languages do encapsulation by convention. Inheritance is a nice feature but its not essential (composition often does the same job; interface inheritance doesn't really count). I do agree with the polymorphism bit but it saddens me that it is rarelly distinguished from other forms of polymorphism (like parametric polymorphism, aka generics). Thankfully, the wikipedia list that S.Lott brings up has most of my rant covered :)
Jan
31
comment What are the features required for Object Orientation?
Abstract Data Types, data modeling and encapsulation are not unique to OO, though (as you briefly mention yourself). I would prefer to describe OO based on its more unique features (dynamic binding of method calls, polymorphism via said method calls, etc)
Jan
31
comment What are the features required for Object Orientation?
I shall not today attempt further to define the kinds of material I understand to be embraced within that shorthand description ["object-oriented programming"]; and perhaps I could never succeed in intelligibly doing so. But I know it when I see it, and the code example involved in this case is not that.
Dec
27
comment Two HTML elements with same id attribute: How bad is it really?
What about HTML5? There is a big difference between what is written in the HTML4 spec and what is accepted by browsers, etc.
Dec
27
comment Is there an IDE for python that creates the same kind of reflective environment that Smalltalk provides?
Well, the command line REPL works on LINUX at least (thats what I use anyway).
Dec
26
comment Is there an IDE for python that creates the same kind of reflective environment that Smalltalk provides?
@S.Lott: I think his definition of "looks like a Smaltalk environment" is clear enough.
Dec
26
comment Why is #include <iostream.h> bad?
Problem is, are you sure you want a book from "back in the day?"
Dec
23
comment How Much Logic in Getters
@Domenic: This is a semantic and language-dependent issue. The point that an object is fit to use and provides the appropriate invariants after, and only after, it is fully built.
Dec
23
comment How Much Logic in Getters
@TMN: In a best case scenario the class should be organized in a way such that getters don't need to run operations capable of thowing exception. Minimizing the places that can throw exceptions leads to less unexpected surprises.
Dec
22
comment What are some examples of “wartiness” making a programming language more useful?
I am disappointed noone mentioned Perl yet. It takes pragmatic warts to a whole new level.
Dec
15
comment Will I ever be able to code client-side browser code in a language of my choice?
The point is more subtle - Javascript is described in a higher level then most intermediate languages so implementations get more leg room in choosing what to do. (Of course, this is not all a sea of roses - I just wanted to point out that we are not the first to think about an IL for the web and that it is not that simple)
Dec
13
comment Why is Python recommended as an entry level programming language?
At you last point: people often mix up dinamic typing with weak typing. Python is dynamically typed (types associated to values instead of variables) but is also strongly typed (so programs crash instead of silently swallowing conversion errors)
Dec
12
comment Should I provide synonyms in an API?
What if a function is known by multiple names (like foldl vs reduce, I vs id, etc?)
Dec
12
comment What are the disadvantages of unobtrusive script patterns in web applications?
I think the term "unobstrusive Javascript" was originally more for when your page can also work fine without Javascript (due to using an old browser or having it disabled). I don't know if it still as relevant now given how most people now use Javascript compatible browsers.