
Potion Lang - big_chungus
http://perl11.org/potion/
======
thelazydogsback
[FWIW, dev work on this was started 7 yrs ago and ended 4 years ago.] I like
many features of this language -- although the feature I _don 't_ like is
traits/mixins (one of the lang's central tenants), which seems like a bad idea
in the general case -- it makes implementation inheritance even more abusable,
rather than preferring delegation.

    
    
      "hello" print
    

in addition to

    
    
      someObj.ToString()
    

in Java-esque languages are just horrible, IMHO. An arbitrary object should
have absolutely no business knowing how to render itself, nor should a string
know how to do I/O on itself, as these operations depend on the context of
their usage.

Rather, for example, if you want to stick with message-sends:

    
    
      console [print "foo"] 

would delegate the printing of "foo" to the console object. (here the brackets
reify the message -- not sure about the syntax in Potion.

I can't tell you how many time in my code or in others', a .ToString() was
expected to do one thing (pretty-print, for example) when instead it used some
default method, such as the base method that prints " <a Foo>" or something.
These things even end up in production output.

~~~
dmix
> I can't tell you how many time in my code or in others', a .ToString() was
> expected to do one thing (pretty-print, for example)

I'd expect this to turn the object into a String.

~~~
ludamad
That's almost comically underspecified. One big concern that comes to mind, is
the string a complete view of the object (and thus suitable for serialization)
or not? Or is it more succinct and suitable for a print statement?

~~~
dmix
Yes, I get the Java stuff, I was being sarcastic because it totally missed the
context it was built with, in favour of some generalist mainstream adoption
critique which misses the point.

Have you seen the homepage?

The Potion Pledge "everything is an object" bit was a good hint.

------
beefhash
Their TLS certificate expired over a year ago. This doesn't exactly seem to
inspire my confidence in the project's ongoing development.

~~~
petre
I think Rieni Urban abandoned working on this project over cperl.

[https://github.com/perl11/cperl](https://github.com/perl11/cperl)

~~~
rurban
Not really abandoned. It's just not the main priority anymore. And perl6
decided to do something else, to go forward with a very shortsided and wrong
approach (again).

There are two major blocks here,

1) the parser surviving a GC. There was one help from outside, but without
real code. It almost got fixed by myself recently. macros depend on this, and
improving the compiler and adding a matcher on macros.

2) threads support for the GC. hard problem. would need to switch to boehmgc,
as fellow Tiny(Ruby,Python) folks did with this codebase. But they got not
much farther. Only wren did. I liked his approach.

The TLS cert if unfortunately out of my hands. Someone else is maintaining the
domain.

------
peteretep
Trying to understand what this represents -- looks like it's an implementation
by rurban of that Ruby dude's Potion language?

~~~
peteretep
[https://groups.google.com/forum/#!topic/potion-
lang/TRDuHMxz...](https://groups.google.com/forum/#!topic/potion-
lang/TRDuHMxzR9Y)

rurban writes:

I plan to use potion, the VM and compiler for a perl fork, codename p2. perl5
and perl6, in spirit of parrot, just 40x faster, and better than the ongoing
perl on JVM plans. See
[https://github.com/perl11/potion/blob/p2/README.p2](https://github.com/perl11/potion/blob/p2/README.p2)

So naturally I'm going to enhance potion also. New are libpotion.so, improved
make times, seperated config and dist/install targets via config.inc,
dist.mak. I didn't like that every make probed and shelled too much. Now it
only does when needed.

I fixed load readline (the wrong path), and changed the LOADER_PATH to (lib,
PREFIX/lib/potion, .) . at first is a security risc. added support native
extensions: darwin .dylib vs .bundle. With load .pnb is favored over .pn. I
also added libdisasm support for nicer jit debugging, and improved the parser
interface for multiple language support.

I'll add in the next months dlcall (FFI), exception handling, arbitrary
precision math and a lot of libraries to support perl5 and nqp, the perl6
bootstrapper.

I'll probably come up with a fast intermediate language to write those
libraries, and I'm not sure if it will be potion (the language) or a small
fast subset of perl.

