newLISP Fan Club

Forum => newLISP in the real world => Topic started by: conan on December 25, 2011, 08:15:40 AM

Title: [wishlist] things I wish for newlisp for 2012
Post by: conan on December 25, 2011, 08:15:40 AM
Since we're in this time of the year, I'll take advantage of it and make some wishes for newlisp.



First I'll wish there's a new area for wishes like this. Could it be a new forum area or a bug tracker, so we can keep track of what has been proposed and avoid discussing things that have already been discussed. Also to know the status of things under implementation.



That was a meta-wish. Now what I would like to have implemented in newlisp:



  • tab completion working not only on newlisp's primitives but also on loaded modules and new defined symbols inside REPL.

    • in debug mode I wish ENTER to issue s+ENTER so one can press just a single key to advance in step mode. A better option would be to give it auto-configuration, that is: to have a default binding of ENTER to s, but also change default on every new command, so the next ENTER keypress without command would issue last issued command (step, next or cont).


    • error messages with line numbers referring to script file. I know this has been already discussed (//http), but I think it's a necessary addition. Sometimes you have very similar lines of code, or equal, on different parts and the message is not enough to find the offending line. Recently I had to fill my code with printlns to hunt a bug. Regarding the bloating Lutz mention on linked post, I'd say we could have different modes. So in debugging mode newlisp would be bloated, but not in production mode. Not sure though if two different binaries are necessary or if it could suffice to have a command line switch.


    • parenthesis highlight inside REPL would be very nice

    • remove the need to put [cmd] tags or press ENTER to issue an auto [cmd]. If [cmd] tags are necessary for something else, then don't remove them, but make multi-line code work from the beginning. I knew about the press ENTER trick recently and I think is somewhat hidden and feels unnecessary.


    • a centralized repository endorsed by newlisp wich allows collaborative building of code snippets.
  • Title: Re: [wishlist] things I wish for newlisp for 2012
    Post by: jopython on December 26, 2011, 08:56:49 AM
    How about html templating module?
    Title: Re: [wishlist] things I wish for newlisp for 2012
    Post by: conan on December 26, 2011, 03:00:25 PM
    Quote from: "jopython"How about html templating module?


    Haven't used it yet, but Jeff Ober's web module (//http) claims to have ASP/PHP-style templates. Also I think I've seen some other stuff around with template capabilities.
    Title: New Year wishes for Newlisp
    Post by: unixtechie on December 26, 2011, 11:16:54 PM
    Well, here's my new year wish.



    I wish to crown the new libffi functionality with its application to the Zeromq messaging library (0MQ, zmq).



    The combination could open breathtaking opportunities for newlisp scripting, basically providing the core of Erlang functionality in 300k+300k+1.7M = Erlang in <2.5 MB without a need of "system installation" of 127 MB and 5000 files, and cross-platform, if newlisp glue is written with care.  Just drop 3 files into any directory.



    Combined with Mongrel2 web server (which is a thin 'gateway' to Zeromq messaging in effect) could allow creation of distributed scalable and (if 'supervising' is implemented in your scripting) reliable web appls, which are blasingly fast.



    Newlisp Zeromq messaging - if tests are successful -  could then be wrapped into Erlang OTP-like APIs.  And we'll get "newERLisp" ;))))



    I'll try to do some test scripting during these holidays (which in some countries last until Jan 10 ;))) ) and tell about the results.



    p.s. Zeromq book ("the Guide") with patterns of usage at http://www.zeromq.org

    http://zguide.zeromq.org/page:all



    p.p.s Plenty of languages, including all major scripting ones, already have their interfaces/APIs to the 0MQ messaging library.

    What is unique about Newlisp is that (with its internet server mode, net-eval, and procreation of offspring processes combined with messaging from parent to children etc.) already has the erlang-like infrastructure for launching and managing the stuff built in.

    While in other langs that would require effort, loading extra "modules" (created as fronts to other libs) etc.



    And the major advantage Newlisp offers is "0 installation" and its ability to create "pseudo-executables" by packing the script with the interpreter in one small file.



    So - is a 2MB new_erl_lisp  possible?
    Title: Re: [wishlist] things I wish for newlisp for 2012
    Post by: jopython on December 27, 2011, 05:42:54 AM
    Newlisp does not have TCO. How about  adding loop/recur(aka clojure) like feature which internally does looping/trampolines/?
    Title: TCO trampolining and stuff
    Post by: unixtechie on December 27, 2011, 06:26:29 AM
    I have not thought about it, nor tested, so the link might be kind of irrelevant, but:

    here's what looks like a solution via closures (which are possible in newlisp):

    http://www.windley.com/archives/2008/11/tail_optimized_mutual_recursion_in_clojure.shtml

    and the original is here:

    http://groups.google.com/group/clojure/tree/browse_frm/thread/6257cbc4454bcb85/7d5fd827cd549080?_done=%2Fgroup%2Fclojure%2Fbrowse_frm%2Fthread%2F6257cbc4454bcb85%2F7d5fd827cd549080%3F&
    Title: Re: [wishlist] things I wish for newlisp for 2012
    Post by: Lutz on December 27, 2011, 08:04:35 AM
    somebody did this in newLISP some time ago:



    http://www.newlisp.org/syntax.cgi?code/trampoline.txt
    Title: Re: [wishlist] things I wish for newlisp for 2012
    Post by: tumble on December 28, 2011, 08:28:18 AM
    I've been wanting a better syntax for defining default functors (blah:blah), but coincidentally Lutz has just posted one at http://newlispfanclub.alh.net/forum/viewtopic.php?f=16&t=4029 !
    Title: Re: [wishlist] things I wish for newlisp for 2012
    Post by: jopython on January 10, 2012, 03:58:39 PM
    An Expect/Pty module would be a welcome addition to the newlisp library.
    Title: Re: [wishlist] things I wish for newlisp for 2012
    Post by: g1i1ch on February 07, 2012, 02:06:39 PM
    Since my focus is games I'd love to see a sdl library, and an improved newlisp-edit.