Archive for December, 2009

Java Gripes

 | December 8, 2009 7:51 am

I, for my sins, am now programming in Java. By now I have a lot of experience programming with a pretty large number of programming languages. Java, C++, C, Basic, Visual Basic, SQL, Python, Perl, php, Matlab, etc.

While I have to admit to having a prejudice against Java as YAPL (Yet Another Proprietary Language), I knew that in all likelihood I’d be working in it for some time, and I did my best to reserve judgement and find what is good in the language.

By now though, I think I’ve gotten good enough in Java to have an informed opinion. While Java has its strengths, and it could certainly be worse (it could be visual basic for example), I’m generally unhappy with it. I think the big problem I have with Java is it marketed to be used in application domains where it simply isn’t right choice. I suspect that for medium sized projects, free projects, projects which require a heavy network integration or should run as an applet, it’s probably a good language. For certain problems I would even believe that it’s the best choice.

But for large, complex projects, in particular projects in which you want to sell a binary and not sell a source code, forget it, Java’s a nightmare. But I don’t want to get into an encyclopaedic discourse of the ills of Java. I actually just want to use this forum to vent my frustrations with the language, and keep a kind of running diary as problems cross my mind. I suspect it will be useful when I need to explain to someone why I don’t care for a language. Normally when I get involved in such conversations my frustration is to palpable for me to explain my concerns lucidly: I’m to busy trying to get my head above the frust.

For today, let me just gripe about how Java has too many advocates. I suspect that this ill, along with most of Java’s ills, stem from the fact that java is owned by a corporation which expends a lot of money and energy trying to brand the language, generate a community, and in general get people feeling all tribal about being a Java programmer. Consider this blurb on the back of “Killer Game Programming in Java” which has on it’s back cover blurb “As a result [of poor documentation] Java has become a second-class citizen to C, C++, and assebly language when it comes to hardcore game programming. This book changes all that…”

Ugh. That’s just typical of the Java world. The book jacket isn’t trying to sell a book, it’s selling Java to a problem domain. The fact is Java isn’t the right choice for a “hardcore” game. My understanding of the term “hardcore gaming” is pretty much, by definition, to be “resource intensive”. That means efficiency and complexity (both algorithmic and code-complexity) are an issue, and that’s where Java just isn’t a good choice. Not only that, but games tend to be commercial undertakings, which means selling binaries and license management etc, which means obfuscation, which means you can’t break your code down properly into modular units and libraries. Generally if it’s really computationally intensive, you want to manage your own memory…

Now, I have to use Java for a 3D application. I have no choice. So I’m happy to have the book and I’m sure it will be useful to me. I’m also sure that there are a number of applications for which Java’s 3d apps are a good choice (smart phones, web apps, free software projects), but trying to convince the reader that the only thing keeping Java from being as good a platform as C++ and assembly is the documentation, well that’s just disingenuous shilling. The Java community is like the P.T. Barnum of programming communities.

Share on Facebook

Atheism and the holidays

 | December 2, 2009 4:50 am

Well, Switzerland just passed an anti-minaret initiative, which forbids the construction of new minarets in Switzerland.  It was a very dissappointing result.  Preliminary polls indicated that only 36 percent of Swiss favored such a law, which leads  me to believe that the racist, fear-mongering, irrational and emotion-based ad campaign was successful.  Members of the EU made public statements to the effect that ‘some issues shouldn’t be up to the people”, in other words, Switzerland suffers from an excess of Democracy.

Well, sometimes Democracy leads to poor results, but so does every other form of government.  Who decides what gets to go to the people?  Would Switzerland be better off with a top-down psuedo-democracy like the United States, where the corporations reign so supreme we’re struggling to impose some oversight on health insurance providers?  Nuts…

Now me, I’m almost okay with the minaret ban.  The only real problem is, it’s discriminatory.  The SVP claim that there is a need to  ban minarets because they symbolise political power of a religion.  I actually agree with that completely.  However, to be fair, we need a ban on all new religious towers.  Band the goddamn church towers I say.  I can’t tell you how many people I know who get awoken by goddamn church bells every weekend.

Bettina was so upset she started talking about moving to the states.  Well, if we ever fix our health care system, that might be something I would consider.  Certainly I don’t think such a ban would stand up in America, but that’s largely because we have such an undemocratic system of government, where the laws scarcely reflect the will of the people.    On the other hand, religious tolerance is a deeply engrained ideal in America, so perhaps a similar vote would turn out differently there.  I’m not entirely sure.

America does idolize religious tolerance and freedom.  You have the freedom to believe whatever you like, as long as you choose to believe some irrational bullshit based on some book written by a lunatic or a charlatan at least a hundred years ago.  It’s perfectly acceptable to believe that god screwed some virgin 2000 years ago, that the earth is only 4000 years old, that jesus actually lived in the states at some point and that the indians are the lost 13’th tribe of Israel.  But god forbid you believe in reproducibility and the evidence of your senses.  God forbid you believe in rational thought.  If you conclude that the idea of a cosmic father figure is kind of silly, well, apparently you’re as bad as Hitler in America’s eyes.

Think I’m exagerating?  Maybe.  The NYT has a nice article about secular humanists, who are conducting a billboard campaign.

“We don’t intend to rain on anyone’s parade, but secular people celebrate the holidays, too, and we’re just trying to reach out to our people,” said Roy Speckhardt, the executive director of the American Humanist Association. “To the degree that we are reaching out to the godly, it’s just to say that you can be good without god. So their atheist neighbor down the street shouldn’t be vilified as though he is immoral.”

There have been some interesting responses:

The head of the Catholic League linked secular humanists to figures like Hitler and the serial killer Jeffrey Dahmer. The publisher of “Santa Claus Is Coming to Town” complained about the signs. In Cincinnati, a billboard that said “Don’t believe in God? You’re Not Alone” had to be moved after the owner of the billboard property said he had received threats. In Moscow, Idaho, a sign that said “Good without God. Millions of humanists are” was vandalized twice in three weeks.

Man, so secular humanists are like Hitler and Jeffrey Dahmer. I found the following bit particularly humorous:

“It is the ultimate Grinch to suggest there is no God during a holiday where millions of people around the world celebrate the birth of Jesus Christ,” said Mathew D. Staver, founder and chairman of the Liberty Counsel, a conservative religious law firm, and dean of Liberty University School of Law in Lynchburg, Va. “It is insensitive and mean.”

I just want to mock the guy for using the word “Grinch” in such a dumb way, and to further mock him for working for the “Liberty University”, and being chairman of the “Liberty Council”. How very newspeak.

You know, as an atheist I’m constantly subjected to religious propaganda, in advertisements, in television shows and movies, at people’s weddings… recently I was at a wedding where the priest recited that verse that goes “and the lord god gave us dominion over the earth and all the animals and all the fish and the sea… be fruitful an multiply…”. Is there a more harmful belief in this day and age, than to think that we should dominate the planet, that we need more children? What we need is a little more respect for our fellow living creatures, rather than more dogma saying we’re somehow special and it’s okay for us to do whatever we like to the little fishies, as they are ours to do with as we see fit.

On the other hand, I’m encouraged that the percentage of Americans identifying themselves as having no religion has more than doubled since 1990. I think we can thank the religious right for giving religion such a bad name, and encouraging people to start thinking for themselves.

Share on Facebook