News for hackers. Stuff that matters.
Re:The lambdaway project, a small and coherent language dedi... by junke on Wednesday August 17, 2016 @01:03PM (#12306246)
What did you do to the parentheses? they are all curly.

I find the explanation at [0] a little more detailed and informative (8th European Lisp Symposium 2015). Worth checking out if you are interested.

[0] http://epsilonwiki.free.fr/alphawiki_2/?view=lambdatalk_slid...

Re:The lambdaway project, a small and coherent language dedi... by martyalain on Sunday August 21, 2016 @04:27AM (#12329995)
« What did you do to the parentheses? they are all curly. »

Because we are in a wiki context where text is 95% of the content. I want to be able to write (Hello World) without triggering any evaluation, trying to apply Hello to World. Usually, other languages (except HTML) evaluate every words in code except quoted sentences - called strings - like this "Hello World". Lambdatalk inverts this process: everything is unevaluated out of curly braces. For instance this expression 1+2 is equal to {+ 1 2} should be written in Javascript like this: "1+2 is equal to " + (1+2). I think that it's the main point of lambdatalk, this inverted process. You could have a look to these links: "curl | latex | LML | PDF | skribe | SXML" in the page http://epsilonwiki.free.fr/lambdaway/?view=curl.

Re:The lambdaway project, a small and coherent language dedi... by martyalain on Wednesday August 17, 2016 @01:15PM (#12306359)
It's not so easy to introduce a language! I thank you for giving the link to this more complete presentation, but some people could prefer a more progressive approach. You can follow it from the start page http://epsilonwiki.free.fr/lambdaway/ : quick, overview, lambdatalk_1, lambdatalk_2, etc.. I would be happy to get your opinion back.
Re:The lambdaway project, a small and coherent language dedi... by junke on Wednesday August 17, 2016 @05:16PM (#12308547)
The first thing which comes to my mind is how the Javascript interpreter works, using a regex to replace the deepest s-expressions by their evaluations (both scary and brilliant)[0]

I found the console[1] and started using it. I was trying to expand a list of things into LI elements; at some point I wrote this:

    {def lis| {lambda {:x} {li :x}}}
The bar represents the cursor just before I hit backspace. After I hit backspace, I entered an infinite recursive evaluation which eventually stopped with stack overflow. Maybe evaluating the code after each keypress is not ideal. Or maybe you could add a timeout, a custom depth limit or something else ;-)

Also, being accustomized to syntax coloring, completion, indentation, warnings, etc., I find the environment particularly dry, especially when you consider your target audience. On the one hand, beginners who want to learn will be able to explore and find their way through trial and errors anyway, but on the other hand, a little bit of feedback can help when they are blocked. For example, when forms are badly formed the output is "ooops": this is better than nothing, obviously, but still a little terse. I looked at the teaching[2] section and this is a good introduction, and I am not telling you to be more like Scratch either, but there might some way to bring a little bit more interactive help.

Overall, this is a nice project and it brings a lot of different things together (maths, svg, javascript). I could be useful as a richer Markdown and I find it more readable than the typical Wiki syntax.

[0] http://epsilonwiki.free.fr/alphawiki_2/meca/JS.js [1] http://epsilonwiki.free.fr/lambdaway/meca/ [2] http://epsilonwiki.free.fr/lambdaway/?view=teaching

Re:The lambdaway project, a small and coherent language dedi... by martyalain on Wednesday August 17, 2016 @05:31PM (#12308644)
Thank you for your interest in this project and your relevant remarks.

About {def lis| {lambda {:x} {li :x}}}, I wrote this expression in http://epsilonwiki.free.fr/lambdaway/?view=sandbox and I didn't see any infinite loop. Click on the top-left "+" in the frameview and then on edit to inspect the code.

OK, the error messages are terse, there is no syntax colorization in the textarea. There is a timeout for each keypress but it has to be improved.

It's a work in progres, I'm alone and I need help.

Re:The lambdaway project, a small and coherent language dedi... by junke on Wednesday August 17, 2016 @06:09PM (#12308865)
I can't reproduce it anymore. I had a bulleted list near the function definition and somehow as soon as I pressed backspace it went unresponsive until the browser's window crashed. I'll keep trying, but there must have been something else happening.

I understand this is hard work. I hope you find time and maybe someone to help you develop this project.

Re:The lambdaway project, a small and coherent language dedi... by brudgers on Wednesday August 17, 2016 @10:17AM (#12304844)
The {lambda way} project is a workshop built as a thin overlay on top of any modern web browser, and devoted to writing, composing and coding on the web, where the markup, styling and scripting are unified in a single language, {lambda talk}.

Github: https://github.com/amarty66/lambdaway

Home: http://epsilonwiki.free.fr/lambdaway/

Re:The lambdaway project, a small and coherent language dedi... by martyalain on Wednesday August 17, 2016 @11:10AM (#12305271)
Thanks :)
Re:The lambdaway project, a small and coherent language dedi... by JadeNB on Wednesday August 17, 2016 @01:44PM (#12306598)
I can't seem to find any language guide or specification, so it's not clear to me whether names (other than those made canonical already by HTML and Lisp) are meant to be in English or French. If the former, then 'serie' should be 'series' (or 'range' or otherwise).

EDIT: For example, the image http://epsilonwiki.free.fr/alphawiki_2/data/lambdatalk_splas... from the talk linked at https://news.ycombinator.com/item?id=12306246 appears to have both 'title' and 'titre'.

Re:The lambdaway project, a small and coherent language dedi... by martyalain on Wednesday August 17, 2016 @03:48PM (#12307786)
- title="Mustangs at Las Colinas" is a standard HTML attribute of the img markup.

- in the expression {{titre}lambda-talk}, titre (which is title in french, sorry) is the name of a constant defined further in the page or in an external page acting as a library.

Re:The lambdaway project, a small and coherent language dedi... by JadeNB on Wednesday August 17, 2016 @04:46PM (#12308333)
Sure, I understand that 'titre' is 'title' in French—and there's no need to apologise for that! My question was rather whether the keywords (or built-in functions, or whatever one would call things like 'tr' that the user is not meant to define him- or herself) in the language are meant to be in English or French. If the former, and if 'serie' is a keyword rather than a function—again, I couldn't find a language reference or specification—then it should probably be 'series'.
Re:The lambdaway project, a small and coherent language dedi... by martyalain on Wednesday August 17, 2016 @05:05PM (#12308467)
The first reference for lambdatalk was here : http://epsilonwiki.free.fr/alphawiki_2/?view=syntax_referenc...

A new one is under construction here : http://epsilonwiki.free.fr/lambdaway/?view=lambdaway, but it's in french until now. Sorry.

The function "serie" comes with "map" and "reduce". You could have a look to an application of "serie" in http://epsilonwiki.free.fr/lambdaway/?view=euler

And OK, I should have named it "series" or "range". I promise I will replace "serie" by "range" to be coherent with my choice of english names for builtin keywords and functions. Nobody's perfect.

Re:The lambdaway project, a small and coherent language dedi... by JadeNB on Wednesday August 17, 2016 @09:41PM (#12309887)
> And OK, I should have named it "series" or "range". I promise I will replace "serie" by "range" to be coherent with my choice of english names for builtin keywords and functions. Nobody's perfect.

I would have posted this before, but "You are posting too fast." Sigh.

It sounds like I gave offence. I meant my criticism to be constructive, and I apologise if it came across as an attack. (For what it's worth, it's only because the language looks interesting that I bother trying to make constructive suggestions!)

By the way, while we're talking syntax, why {} instead of ()?

Re:The lambdaway project, a small and coherent language dedi... by martyalain on Thursday August 18, 2016 @12:58AM (#12310491)
why {} instead of ()? Because we are in a wiki context where text is 95% of the content. I want to be able to write (Hello World) without triggering any evaluation, trying to apply Hello to World. Usually, other languages (except HTML) evaluate every words in code except quoted sentences - called strings - like this "Hello World". Lambdatalk inverts this process: everything is unevaluated out of curly braces. For instance this expression 1+2 is equal to {+ 1 2} should be written in Javascript like this: "1+2 is equal to " + (1+2). I think that it's the main point of lambdatalk, this inverted process. You could have a look to these links: "curl | latex | LML | PDF | skribe | SXML" in the page http://epsilonwiki.free.fr/lambdaway/?view=curl.
Re:The lambdaway project, a small and coherent language dedi... by abecedarius on Wednesday August 17, 2016 @11:39AM (#12305492)
Sounds like a similar idea to https://en.wikipedia.org/wiki/Curl_(programming_language) -- can you compare them?
Re:The lambdaway project, a small and coherent language dedi... by martyalain on Wednesday August 17, 2016 @11:48AM (#12305561)
Re:The lambdaway project, a small and coherent language dedi... by nickpsecurity on Wednesday August 17, 2016 @12:14PM (#12305758)
They take a similar amount of code to do stuff but Curl is easier to read.
Re:The lambdaway project, a small and coherent language dedi... by martyalain on Wednesday August 17, 2016 @12:38PM (#12305964)
It's a respectable point of view. Mine is that lambdatalk follows closely the HTML/CSS/Lisp syntaxes and allows to share the creation of rich and interactive documents between authors, web designers and coders.

And also, don't forget that to use Curl products or execute Curl applications over the internet, it’s necessary to acquire and agree to a Curl license. The lambdaway project is free and easy to install, http://epsilonwiki.free.fr/lambdaway/?view=download.

Re:The lambdaway project, a small and coherent language dedi... by nickpsecurity on Wednesday August 17, 2016 @12:50PM (#12306101)
"And also, don't forget that to use Curl products or execute Curl applications over the internet, it’s necessary to acquire and agree to a Curl license."

I haven't forgotten. I was excited to see a full-stack solution get invented that about anyone could use. Then they wanted to lock it up commercially. That killed all hope of it spreading. (sighs)

These days I'm more into pushing Opa given it brings ML-style robustness to the full-stack concept. Was good to see your project, though, as I'm all for experimentation in this space. :)

http://opalang.org/

Re:The lambdaway project, a small and coherent language dedi... by throwawaytire on Wednesday August 17, 2016 @06:39PM (#12309016)
It's nice to see an abstraction over Javascript and ajax. I'm working on an asp.net MVC site at the moment and can't stand the untidyness of dealing with the jumping between abstractions all the time.

As an aside, Elm looks a nice way to write web client code. I hope Elm will one day compile to a fast language for the server (e.g. C, OCaml or WebAssembly). There's no reason Elm shouldn't be as fast as OCaml and I think for server-based work it should be within 2x C speed.

Re:The lambdaway project, a small and coherent language dedi... by martyalain on Wednesday August 17, 2016 @01:01PM (#12306218)
Thanks for the link to Opa. Looks very interesting. About the readability of the code, what do you think of lambdatalk for kids : http://epsilonwiki.free.fr/lambdaway/?view=teaching
Re:The lambdaway project, a small and coherent language dedi... by nickpsecurity on Wednesday August 17, 2016 @01:46PM (#12306613)
Seems interesting. I'll look at it again later.
Re:The lambdaway project, a small and coherent language dedi... by doublec on Wednesday August 17, 2016 @06:30PM (#12308981)
How does Opa compare to Urweb? Both seem to have an ML-style influence http://www.impredicative.com/ur/
Re:The lambdaway project, a small and coherent language dedi... by qwertyuiop924 on Wednesday August 17, 2016 @04:27PM (#12308177)
This is cool, but I wish for a more schemey language. Like if the serverside was written in Chicken, using CSS and HTML-like code inside that, and the clientside was written in Spock.

Unfortunately, Spock doesn't seem to be ready for prime time. It works, but it can stress your JS implementation in odd ways.

Re:The lambdaway project, a small and coherent language dedi... by martyalain on Wednesday August 17, 2016 @05:20PM (#12308566)
My host internet provider is www.free.fr, it doesn't cost anything (except the basic access to internet) and it runs nothing but PHP and mySQL. No way to install Chicken or any other language like Scheme, Python. Have a look to http://epsilonwiki.free.fr/lambdaway/?view=download and see how installing lambdatank+lambdatalk is straightforward.
Re:The lambdaway project, a small and coherent language dedi... by qwertyuiop924 on Wednesday August 17, 2016 @05:40PM (#12308702)
Well, that's a problem that I can't help with.
Re:The lambdaway project, a small and coherent language dedi... by danso on Wednesday August 17, 2016 @01:13PM (#12306342)
Not a huge fan of a language/framework in which the first demonstration purportedly shows how to summon up a photo of a movie starlet in a single word. Not just the implied objectification (which is its own debate, but not worth getting into here), but the dishonesty in implying that the language contributes one meaningful iota in the conjuration of that image. Reminds me of those unsolicited redesigns of Facebook in which the design looks so beautiful, but only because the photos (and the people in them) are beautiful. Doesn't mean that the design is at all practical or functional.
Re:The lambdaway project, a small and coherent language dedi... by martyalain on Wednesday August 17, 2016 @01:19PM (#12306404)
Ok, I was not able to share what I believed to be seen as a joke. Sorry :( Maybe you would prefer this more serious introduction : http://epsilonwiki.free.fr/lambdaway/?view=calc2talk
Re:The lambdaway project, a small and coherent language dedi... by danso on Wednesday August 17, 2016 @01:52PM (#12306676)
Was it meant to be a joke? My problem is that it's just plain misleading. This is the first line after the boilerplate introduction:

> It begins with simple things, for instance you could simply write

          {ava}
> and get a picture of the gorgious Ava Gardner

It made me think that this was some kind of framework with a feature akin to invoking `/giphy [some word]` in Slack. Only after scrolling all the way down do we find that it's just basically a variable that holds the same amount of code it would take to show that image through HTML and CSS, without any information on why it would be beneficial to follow a practice of writing inline styles (as opposed to the standard practice of using CSS selectors and external sheets).

Re:The lambdaway project, a small and coherent language dedi... by martyalain on Wednesday August 17, 2016 @03:42PM (#12307736)
« a practice of writing inline styles (as opposed to the standard practice of using CSS selectors and external sheets) »

The constant "ava" can be stored in another page of the wiki, a library which can be called via a {require mylibrary}. Please be nice enough to believe that I'm aware of the standard practice... This "quick" introduction can't explain everything. Neither CSS standard practices, nor first class functions, currying, tail-recursion, macros, and so on. Please take time to go further in this work before saying « it's just plain misleading ». Thank you.

Re:The lambdaway project, a small and coherent language dedi... by danso on Wednesday August 17, 2016 @06:18PM (#12308920)
Sorry, I didn't mean to attack your intelligence or technical competency. Anyone who proposes a new open-source web language/framework has an exceeding amount in both, in my opinion. My complaint is that the gratuitous (and large, when I'm viewing the page on mobile) visuals obfuscate the details.

The premise of the intro is that it is just "simple things" (and the conclusion, "Keep it Small and Simple"). "Simple", to me, would be how invoking "ava" embeds an image of an Ava into the page, a priori. But that is not at all the case and I have to scroll past 3 large headshots of actresses to get to the point. And even then, the utility is unclear.

I don't expect a "quick" introduction to explain everything. But if the article has the time to throw in random photos to gaze upon, then I'm going to be disappointed when I get to the end to see few details explained.

Re:The lambdaway project, a small and coherent language dedi... by voaie on Wednesday August 17, 2016 @04:46PM (#12308327)
This is the second time I see this project, and I've already seen some other similar projects, but readability is still a problem.

Anyway, the source code is tiny and educational. :)

Re:The lambdaway project, a small and coherent language dedi... by nilved on Wednesday August 17, 2016 @11:34AM (#12305447)
Is that fucking papyrus
Re:The lambdaway project, a small and coherent language dedi... by drostie on Wednesday August 17, 2016 @01:08PM (#12306295)
I'm pretty sure that was intentional. Choices like that can sometimes keep a certain sort of person out of a budding community, and even though they are a localized pocket of worldsuck, may decrease worldsuck globally.
Re:The lambdaway project, a small and coherent language dedi... by martyalain on Wednesday August 17, 2016 @05:34PM (#12308660)
Yes it was! The font "papyrus" is only used in this page. Because Ava Gardner loved it :)
Re:The lambdaway project, a small and coherent language dedi... by martyalain on Wednesday August 17, 2016 @11:53AM (#12305600)
And I guess that it removes any interest in this work!
Re:The lambdaway project, a small and coherent language dedi... by tantalor on Wednesday August 17, 2016 @01:03PM (#12306245)
No, my interest was removed when I saw s-expressions.
Re:The lambdaway project, a small and coherent language dedi... by martyalain on Wednesday August 17, 2016 @03:50PM (#12307802)
Reminds me of John McCarthy's lament at the W3C's choice of SGML as the basis for HTML: "An environment where the markup, styling and scripting is all s-expression based would be nice." »