Software As She’s Developed

Mahemoff’s Podcast/Blog – Web, Programming, Usability from the Author of ‘Ajax Design Patterns’ (AjaxPatterns.org)

Software As She’s Developed header image 4

Entries Tagged as 'Syntax'

Operator Overloading Considered Insanely Useful

August 3rd, 2007 · 1 Comment · HumansAndTech, SoftwareDev

I am amazed that for all the talk about future Java features, there is hardly any mention of operator overloading. Certainly syntactic sugar is high on the priority list, with the Java world starting to realise the benefits of powerful literals and closures. (Good thing too. Steve Yegge: “Java’s biggest failing, I’ve decided, is its [...]

[Read more →]

Tags: ···

But Why?

October 7th, 2006 · 3 Comments · SoftwareDev

I often want to use an operator called “but”, the complete equivalent to “and”. It would let me say:

if guest.wants_to_see(report) but report.is_premium_content raise PremiumContentException end

As opposed to:

if guest.wants_to_see(report) and report.is_premium_content raise PremiumContentException end

The first example is easier to comprehend because it’s closer to the business rule and the way we think [...]

[Read more →]

Tags: ·····