We need a functional language!

172 views
Skip to first unread message

shal

unread,
Jan 24, 2013, 4:50:34 AM1/24/13
to haxe...@googlegroups.com
Seems like we need a functional language, which should be to Haxe as Scala to Java.

I will explain why.
Due to problems with hands (I am near to RSI) I have to optimize my workspace. One of the optimizations is to type less.
Of course there are excellent keyboards like Kinesis or Maltron. I've got the Kinesis, but it's not enough.
There are ergonomic layouts. I have learned Colemak, one of the best layouts available. Now I use Colemak only, it really helps, but it's still not enough. RSI can only get worse, it is impossible to cure it, only to slow down the progress. The only way to stop it is to stop typing, which is impossible in my case, since I am a developer.
I love Haxe (I use Haxe since 2008 and only Haxe since 2009), but it makes me type too much.
A functional language is the best way to express thoughts shorter, isn't it?
So all Haxe developers, who suffer RSI, would love it.
All other developers, who never encountered RSI yet, are at the risk anyway, because they type all the day every day, which means it would be great for them to have an ability to express their thoughts shorter, to prevent disease.

Any thoughts about it? How hard it is, to create a functional language, which would use the same API Haxe uses and would compile the same way to the same targets Haxe compiles?

Heinz Hölzer

unread,
Jan 24, 2013, 5:04:25 AM1/24/13
to haxe...@googlegroups.com
We talked a little bit about possibilites in this thread:

https://groups.google.com/d/topic/haxedev/6KGb-x0BWtE/discussion
> --
> To post to this group haxe...@googlegroups.com
> http://groups.google.com/group/haxelang?hl=en
>
>
>

Axel Huizinga

unread,
Jan 24, 2013, 5:06:29 AM1/24/13
to haxe...@googlegroups.com

Am 24.01.2013 10:50, schrieb shal:
Seems like we need a functional language, which should be to Haxe as Scala to Java.

I will explain why.
Due to problems with hands (I am near to RSI) I have to optimize my workspace. One of the optimizations is to type less.
Of course there are excellent keyboards like Kinesis or Maltron. I've got the Kinesis, but it's not enough.
There are ergonomic layouts. I have learned Colemak, one of the best layouts available. Now I use Colemak only, it really helps, but it's still not enough. RSI can only get worse, it is impossible to cure it, only to slow down the progress.
Every disease is curable because every disease starts in the mind.
The only way to stop it is to stop typing, which is impossible in my case, since I am a developer.
I love Haxe (I use Haxe since 2008 and only Haxe since 2009), but it makes me type too much.
A functional language is the best way to express thoughts shorter, isn't it?
So all Haxe developers, who suffer RSI, would love it.
All other developers, who never encountered RSI yet, are at the risk anyway, because they type all the day every day, which means it would be great for them to have an ability to express their thoughts shorter, to prevent disease.

Any thoughts about it? How hard it is, to create a functional language, which would use the same API Haxe uses and would compile the same way to the same targets Haxe compiles?

E-Mail ist virenfrei.
Von AVG überprüft - www.avg.de
Version: 2013.0.2890 / Virendatenbank: 2638/6026 - Ausgabedatum: 11.01.2013
Die Virendatenbank sind veraltet.


Baluta Cristian

unread,
Jan 24, 2013, 5:35:20 AM1/24/13
to haxe...@googlegroups.com
How ironic, you want to type less and i want to type more, for readability reasons. Is this a disease also?
Maybe the autocomplete is your problem?
--
Băluță Cristian
http://ralcr.com
http://imagin.ro

Jason O'Neil

unread,
Jan 24, 2013, 5:35:29 AM1/24/13
to haxe...@googlegroups.com
I think I've heard the sentiment often enough that if there was a coffeescript style pre-processor (that is just haxe, in the same way that coffeescript is just javascript - the code maps exactly from one to the other) - it would have a big enough following to be viable, even if it was never the "official" syntax.

I suspect one day someone will have a free weekend will sit done and start writing a pre-processor, and then we can all see for ourselves if it's any good or not :)  As it is - the familiarity of the Haxe syntax to AS3, JS and C# developers is bound to be helpful, even if you do type a little more.

And to Shal - sorry to hear about your RSI :(  I hope you can find a way to work around it.  I found some of Haxe's other features (mostly - macros and 'using') have made for some cool ways to reduce typing, like in my Detox library I can write "<h1>header</h1>".parse(), rather than try { Xml.parse("<h1>Header</h1>"); } catch (e:Dynamic) { trace(e); }. 

I've also found myself doing tricks like this a lot:

var studentIDs = students.map(function (s) return s.id);

Which does reduce on the keystrokes a lot compared to the "for" loops I used to write :)  Still not sure if it will be enough to help you out, but good luck...

Jason



Jason O'Neil

unread,
Jan 24, 2013, 5:36:16 AM1/24/13
to haxe...@googlegroups.com
+1 for autocomplete helping reduce keystrokes :)  Unless hitting "tab" too often is what causes your RSI

Juraj Kirchheim

unread,
Jan 24, 2013, 6:48:47 AM1/24/13
to haxe...@googlegroups.com
I am sorry about your disease, but I think you're looking in the wrong direction.

First of all, feature wise Haxe is pretty much what Scala is. Maybe the syntax is noisier in some places, but you can do decent functional programming in Haxe. Sure, it's not Haskell, but neither is Scala.

So what you might actually be looking for is a less noisy syntax. There have been discussions about this and I think this will be done sooner or later. Although Nicolas is opposed to an alternate syntax, I would speculate that if anyone can provide a well-designed solution, he will consider including. Also I might point out tink_lang, which is my personal effort in having to write less and (please forgive any bias) does quite a good job at that.

I believe a language should strive to reduce redundancy and noise, so that flexibility and readability rise. I wouldn't be pedantic about the number of keystrokes. From my experience, when programming you are rarely spending more than 10% time typing. Most of the typing I do as a programmer is while talking to people anyway.

Unless you're bashing out 10KLOC a day in Haxe, I really don't think another syntax will help you. And even then, all programming languages should be designed for reading, not writing. While being able to write super-condensed code might seem appealing and while you might even be able to read it yourself, many others most likely won't and that will just terribly isolate you.

And if you're writing so much code, I think you should rethink your approach. There's a great many Haxe libraries that should help you write less code. You should take time to explore the ecosystem. It doesn't take much typing and optimizing your toolchain will also optimize your workspace.

I wish you the best of luck in fighting off your disease.

Regards,
Juraj

Juraj Kirchheim

unread,
Jan 24, 2013, 6:54:30 AM1/24/13
to haxe...@googlegroups.com
On Thu, Jan 24, 2013 at 11:35 AM, Jason O'Neil <jason...@gmail.com> wrote:
I think I've heard the sentiment often enough that if there was a coffeescript style pre-processor (that is just haxe, in the same way that coffeescript is just javascript - the code maps exactly from one to the other) - it would have a big enough following to be viable, even if it was never the "official" syntax.

I agree. But I still doubt it will actually help Shal.

I suspect one day someone will have a free weekend will sit done and start writing a pre-processor, and then we can all see for ourselves if it's any good or not :)  As it is - the familiarity of the Haxe syntax to AS3, JS and C# developers is bound to be helpful, even if you do type a little more.

Unless I am wrong, CoffeeScript is in fact not a preprocessor
 
And to Shal - sorry to hear about your RSI :(  I hope you can find a way to work around it.  I found some of Haxe's other features (mostly - macros and 'using') have made for some cool ways to reduce typing, like in my Detox library I can write "<h1>header</h1>".parse(), rather than try { Xml.parse("<h1>Header</h1>"); } catch (e:Dynamic) { trace(e); }. 

I've also found myself doing tricks like this a lot:

var studentIDs = students.map(function (s) return s.id);

This works with haxe3: `var studentIDs = [for (s in students) s.id];`

Regards,
Juraj

dlots

unread,
Jan 25, 2013, 10:27:40 AM1/25/13
to haxe...@googlegroups.com

Juraj Kirchheim

unread,
Jan 25, 2013, 12:20:57 PM1/25/13
to haxe...@googlegroups.com
Your point being?

dlots

unread,
Jan 25, 2013, 12:59:41 PM1/25/13
to haxe...@googlegroups.com
I completely agree with your post. Couldn't have said it better myself.

On Friday, January 25, 2013 12:20:57 PM UTC-5, back2dos wrote:
Your point being?

Samuel Batista

unread,
Jan 25, 2013, 3:04:01 PM1/25/13
to haxe...@googlegroups.com
You might want to look into ClosureScript. It's a pretty modern take on a functional language.
Reply all
Reply to author
Forward
0 new messages