Forgot your password?
typodupeerror
Java Programming Ruby

Mirah Tries To Make Java Fun With Ruby Syntax 444

Posted by timothy
from the user-friendly-is-hard dept.
An anonymous reader writes "Java is performant, widely adopted and eminently portable, however, its syntax is largely inherited from C++ along with some of its esoteric unfriendliness. Mirah aims to place a friendly face on Java through the implementation of a syntax whose primary concern is developer friendliness (think Ruby/Python/Groovy), and route of least surprise. The result is a truly cogent alternative syntax delivering readability, expressiveness and some compelling new language features."
This discussion has been archived. No new comments can be posted.

Mirah Tries To Make Java Fun With Ruby Syntax

Comments Filter:
  • Uh... (Score:2, Insightful)

    by msauve (701917) on Sunday March 20, 2011 @05:43PM (#35554038)
    "Performant" is not "a truly cogent alternative syntax delivering readability, expressiveness and some compelling new language features." It's not even a word.
  • by Ichoran (106539) on Sunday March 20, 2011 @05:53PM (#35554108)

    Mirah looks to me so far like a waste of effort. It has somewhat nice syntax, granted, but if you really want to use Ruby syntax with the JVM, there already is something that does that: JRuby.

    If you just want simplified syntax, Groovy is just as simple and looks more familiar to Java programmers.

    If you want simplified syntax and powerful new programming tricks, Scala and Clojure do this far better. If you ignore the Scala libraries and half its features, you get everything that Mirah was designed to do.

    The language designers should do a better job explaining why this is worth paying attention to.

  • Obligatory... (Score:0, Insightful)

    by Anonymous Coward on Sunday March 20, 2011 @05:53PM (#35554112)

    Yo I heard you like turds so I put a turd on your turd so you can use crap while you use crap!

  • by Sabalon (1684) on Sunday March 20, 2011 @05:59PM (#35554150)

    well...what languages you started with. Looking at that, the c++ based code is perfectly readable, but I can't make heads or tails of the other. In fact, reminds me of perl and objectiveC - just start hitting all those shifted characters - they each signify something special.

    Am waiting for :
    Draw Pacman;
    Draw Ghosts;
    Ghosts chase pacman;
    Pacman follows joystick movement;

  • Because it compiles down to native Java, without any of the JRuby overhead.

  • by Dahamma (304068) on Sunday March 20, 2011 @06:35PM (#35554412)

    This I don't get. If you want "developer friendliness" and "least surprise", use a syntax with the (relatively) minimal set of keywords/tokens to accomplish your task. Ruby has basically incorporated the syntax and conventions of every major programming language of the last 30 years...

    And I guess you could call it "developer friendliness" if you want to let people freeform program in whatever style they want, with no two developers tending to use the same syntax for the same implementation - but at this point in my career (ie having worked for half a dozen companies and realizing what you write now may exist for decades), I consider a major component of "developer friendliness" as "easily comprehensible and maintainable by the next developer".

  • by Anonymous Coward on Sunday March 20, 2011 @06:59PM (#35554566)

    Hey look. It's a Java retard responding to a C/C++ retard. How uncommon.

    FYI, both of you are harmful to your respective camps.

  • by Anonymous Coward on Sunday March 20, 2011 @08:25PM (#35555072)

    If C/C++ were so developer un-friendly you would not find them under the hood of pretty much every new language that claims 'developer friendly,easier,etc etc etc ' that came out in the last 20 or so years. Take Java , .NET etc all have some sort of C under the hood.
    It's not that C/C++ is not developer friendly. It's that a lot of developers(apparently) are simply not that good to begin with. While Java , C#, JRuby etc etc etc make things 'easier' (according to some people at least) they ALSO hide a lot of things that a GOOD developer _should_ know in orderr to understand what is going on under the hood.

    I see and hear a lot of kids fresh out of University that never even used C/C++ (which frankly baffles me to this day) ask question like " What is a refference","Oh i thought the GC would take care of that"

  • by IBitOBear (410965) on Sunday March 20, 2011 @08:27PM (#35555090) Homepage Journal

    He did share them... stop trying to "solve" the problem of programmers needing to know how to program by writing languages that try to cover for dummies. We have plenty of languages that dummies can use safely. The problem has been solved.

    Computer languages are like power tools. They can be "so safe, but no safer" before they start losing function. They just _don't_ make a band saw that any 12 year old can use in complete safety. Same for joiner, circular saw, planer, or just good old knife.

    Tools are _not_ supposed to be _safe_. They are only supposed to be "no more dangerous than necessary". We make cheap plastic toy versions of tools for kids to practice with, but eventually they either go away or they have to learn to use the real thing.

    I will believe in these "for dummies" versions of language the day a contractor shows up at my house with a Fischer-Price nail gun that will actually hold up sheet rock but is safe enough to hand to my neighbor's 5 year old.

    The "clever new idea" is that people don't _deserve_ to operate in fields where they are unwilling or unable to learn the skills required. This is just as true of my profession (programming etc) is it is true that my programming acumen doesn't mean that I should be able to walk into CERN and have a go at the LHC even though I know squat about high-energy physics.

    Read the signature line (v v v v v v v v), it is a truism.

  • by walterbyrd (182728) on Sunday March 20, 2011 @10:21PM (#35555768)

    Problem is: when I look at your python code, I don't know if I'm looking at spaces, or tabs, or some combination of both. Not without a hex dump, or something. And one invisible character out of place, and god-only-knows what sort of unexpected results I get.

    Also, I probably can not cut-and-paste your code into mine, and have it work, without substantial modification.

    Then there is the serious issue of emailing code, or cutting-and-pasting from a web-site.

    Too bad that practically everybody on slashdot thinks of BASIC as GW-BASIC. Most versions of BASIC, that are less than 30 years old, actually have it right - no curly brackets, no counting spaces and tabs either.

  • by phantomfive (622387) on Monday March 21, 2011 @12:13AM (#35556260) Journal
    Really? I mean, you're missing such basic things as do you want the ghosts to catch Pacman every time, or do you want him to be able to escape? Do you want Pacman to keep moving after the joystick is returned to center, or do you want him to stop? The problem with every simplified language I've seen so far, is that you still need to be able to express what you want precisely, and that adds complexity to your language. You have to figure out what you want the computer to do in the corner cases.

    Unless you have AI behind your language, but then it's not really the same.
  • by mad.frog (525085) <[moc.knilknirc] [ta] [nevets]> on Monday March 21, 2011 @12:44AM (#35556402)

    Really? You really like writing

    Stop right there: it's not a question of writing, it's a question of reading.

    I spend *waaaaay* more time *reading existing code* than I do writing new code. Designing a language to optimize readability is IMHO far more important than trying to save a few keystrokes.

    In the example above, I find the Java syntax completely readable, though clearly not as terse as it could be. The second example I find readable as well, but not vastly more so than the Java example.

    If you're optimizing for coding time, you're doing it wrong.

  • by cronius (813431) on Monday March 21, 2011 @02:41AM (#35556878)

    I don't remember where I read it, but I read somewhere that Ruby works as a "programming skill amplifier." As in, if you're a great programmer, Ruby allows you to write beautiful code, but if you're a poor programmer, Ruby will allow you to write the most hideous thing that your processor has ever seen.

    And I agree. For better or worse, I think it's a testimony to the power that lies in the language.

  • Re:what. ever. (Score:3, Insightful)

    by Glock27 (446276) on Monday March 21, 2011 @05:13AM (#35557322)

    Apple didn't choose to use it because C++ wasn't different enough; they chose to use it because that is what the NextStep was written with back when Objective-C and C++ were both still in their infancy.

    There were better reasons than this. C++ is not well suited as a systems programming language. That's why there's still not a single major OS that uses the C++ object system at the system level. BeOS was the single failed experiment in this regard - remember the loveliness of "reserved slots"?

    Objective-C's dynamic features make it a much better foundation for systems programming. Its relative simplicity is also attractive.

This process can check if this value is zero, and if it is, it does something child-like. -- Forbes Burkowski, CS 454, University of Washington

Working...