
The Avail Programming Language - jamesbritt
http://availlang.org/
======
rlander
This looks like REBOL, a fascinating and impressive language that encourages
the creation of DSLs (they call them dialects). It's a half-megabyte, zero-
install, cross-platform executable that can run on Linux, Android, HaikuOS,
Windows, Mac. From the homepage:

 _Most software systems have become needlessly complex. We rebel against that
complexity, fighting it with the most powerful tool available, language
itself._

Take a look at
[http://www.rebol.com/oneliners.html](http://www.rebol.com/oneliners.html) for
some very impressive one-liners like the one below (downloads and prints a web
page source):

    
    
      print read http://www.rebol.com

------
munro
At first glance it looks like a fun esoteric language, like Shakespeare [1].
Looking deeper, this language is more amazing then it leads on to be.

But for a little story time: I've started my first major project in Haskell
while sick the past week, and it had me asking lots of questions:

Why do I have to add so many parentheses to get it to compile? Why can't I
just pass monads into my functions? Why is every function not polymorphic? Why
do I get so many pattern matching errors even with -Wall? :( The last one
stings the most, believing my program would never crash. But every function
being polymorphic really got me thinking, since instancing type classes with
Monads was my first instinct. It felt so natural.

    
    
        instance (Monad m, Num a) => Num (m a) where
            (+) = liftM2 (+) -- ((return 123) + (return 321)) -- yipee!
            ...
    

I realize that type classes are global, and could have cascading problems.
Even still, this made me want to prototype a language where all functions are
polymorphic, but after looking over Avail, it seems to answer all my
questions. It feels like a Lispy haskell; static type checking, with context
sensitive polymorphism.

With this kind of polymorphism, one of my first thoughts was what the code
compiles in an unintended way due to the way I specified. The metaphor I
thought of to reason about this was: a copilot in the car tells you "Turn
right here". Are they saying to turn right at the next intersection, or that
this is the intersection that you should be turning at? This example shows
succinctly shows that it's a problem with the language being define (i.e. the
code), that "right" is overloaded to mean a direction, or immediately.

Anyways, I would love for anyone to weigh in, since I've been thinking about
this a lot recently!

[1]
[http://en.wikipedia.org/wiki/Shakespeare_(programming_langua...](http://en.wikipedia.org/wiki/Shakespeare_\(programming_language\))

~~~
ky3
> Why do I get so many pattern matching errors even with -Wall? :( The last
> one stings the most, believing my program would never crash.

I hope your programs never crash, and in the meantime could you explain what

> Why do I get so many pattern matching errors even with -Wall?

means? Perhaps you meant:

> Why do I get so many pattern matching errors _because of_ -Wall?

These are incomplete-pattern-match warnings, yes?

------
Marcus316
This is an interesting project, and I'm going to have to give a bit more time
to it in order to wrap my head around a few things.

One thing that makes this a more difficult language for me to really get
behind is the (required?) use of Unicode characters. That will take a bit of
getting used to, as I am not in the habit of using ANY Unicode for anything.

I will still give this a chance, though. I'm always open to trying new ideas
in the programming head-space.

------
ericHosick
This looks really cool!

Is there a reason why you have something like:

    
    
        newGame ::= a game of Wump the Wumpus;
    

as opposed to:

    
    
        newGame is a game of Wump the Wumpus.

~~~
klibertp
I didn't find it yet, but I'd be _very_ surprised if you couldn't just define
a new "_is_" method/function/block/parse extension/whatever the hell it is to
mean "::=". Or maybe "const_is_" if "_is_" wouldn't work.

Anyway, Avail looks very, very interesting, like it's a combination of
Smalltalk, REBOL and Coq (although it's just an uneducated impression for
now).

------
pcmonk
"Articulate programming" looks a lot like Lisp macros to me. Can anyone
explain the difference?

~~~
patrickmay
The goal appears to be the same. From the introduction:

"In the articulate programming paradigm, a programmer undertakes a project by
developing a domain-appropriate lexicon and phraseology which are leveraged
directly to implement a solution that is readily accessible to domain experts
and software experts alike. Articulate programming is nothing more, and
nothing less, than using the right language and conceptual framework for the
job."

That's very similar to the common approach in Lisp of building the language up
to reflect the problem domain.

Lisp, however, has the advantage of a minimal syntax that allows the
programmer to extend the core language transparently. I'm not sure how
possible that is in this language.

~~~
klibertp
Smalltalk, Forth and Rebol are some other languages which allow for
transparent language extension. There are others, too. Minimal syntax helps,
as does homoiconicity, but Nimrod shows that you can do much even with fairly
"mainstream" syntax.

------
riffraff
reminds me of apple script, which for those who have not seen it before looks
like

    
    
        tell application "Terminal" to get the name of current settings of the selected tab of the front window

------
thinkpad20
Fun stuff. I imagine this must be a very difficult language to write a parser
for. I think this makes a nice counterpart to the über-concise philosophies of
Haskell and similar.

------
bjackman
Looks like a lot of fun! I feel like a bit of a dick for asking this, but:
isn't it really annoying needing to enter unicode-only characters (like →, ÷,
“ and ”)?

~~~
krick
It's unusual and I guess a lot of people actually would find it annoying, but
I actually like it. The reason is there're many characters that are actually
useful or even required if you intend to do typography "right", but not
usually present on keyboard. I prefer "λ" to "lambda" (and I'm not greek), for
instance. But I hate working with some abstractions over pure text, I want to
see exactly what I typed, so I'm not big fan of all these vim plugins that
show "λ" instead of "lambda" in Haskell, etc. God, I hate even tabs, because
they look differently depending on their position in the line!

And typing unicode isn't annoying at all after you are used to it. I'm using
XCompose all the time, so typing ½ or «» or λ is completely natural to me.

~~~
Lambdanaut
I agree. Minor correction though, the plugins show "λ" instead of "\" in
Haskell.

~~~
krick
Yes, sure, my bad.

------
amirouche
I just read the main page so far, avail awesomeness. I wondering how it
relates to voxels and the arrow of time.

