603 karma · joined May 2, 2011
Vimperator's pretty good, but you people really need to check out Pentadactyl.
You shouldn't generalize people (doing it by race is called racism; doing it by country has no fancy name that I know of but it's wrong all the same), or refer to some cultures as "better" than others.
> Objects containing the same values should be equal by default.
Sounds good, but it's a tricky issue. Equality must be checked between all values of both objects. This can take long, as objects can have many values and may contain references to other objects which may in turn contain references to other objects and so on. Object references might even be cyclical. Not impossible to account for but quite tricky.
And how about get/set properties? These must be checked as well, even though many will be just "mirrors" of private or protected properties, and others might be calculations based on other properties (like the area of a circle).
> Comparing objects of different types is a compile-time error.
Accounting for inheritance, I assume.
> Once created, objects and collections must be immutable.
This sounds like a terrible idea. Wouldn't objects be to even modify their own properties?
> Objects must always be initialized to a valid state. Not doing so is a compile-time error.
> No nulls allowed.
Nulls are useful. The problem here comes from not knowing whether something may be null or not. The solution would be only allowing Nullables to be null, and enforcing anything that's not a Nullable to be initialized.
First, why do you have to call checkDestinationQueue after modifying the queue? It's awfully redundant. I assume this is due to some kind of limitation.
And second, goingUpIndicator and goingDownIndicator are kind of sketchy. Can you activate both at the same time? What effect would that have? There should be a single property, directionIndicator of an enum type with the possible values up, down, and none. I don't think you can make enums in javascript though, but I don't know the language very well. I'm just explaining this in terms that I know; there probably is a suitable javascript equivalent or replacement.
[0]: http://worrydream.com/ABriefRantOnTheFutureOfInteractionDesi...
Someone was drawing an X on the correct exit, and I started drawing a checkmark on the one next to it. When they realized, they tried to cross it out.
https://github.com/kanzure/pokecrystal/blob/master/trainers/...
It almost looks like a high-level language.
print expensive_computation(), expensive_computation()
You can do: (lambda x: print x, x)(expensive_computation())
Which would be equivalent to, with an imaginary let syntax: (let x be expensive_computation(): print x, x)[0]: http://mitpress.mit.edu/sicp/full-text/book/book-Z-H-4.html
It was posted on HN but didn't really take off, sadly: https://news.ycombinator.com/item?id=7434529
It's also not "fixing what's not broken", but improving something that could... well... be improved.