News for hackers. Stuff that matters.
Re:A REPL Story by davexunit on Wednesday December 02, 2015 @03:14PM (#10665491)
Yet another person discovering the beauty of the REPL. On my own time, I write all of my software in Guile Scheme using Emacs + Geiser[0] as a development environment and it's wonderful. I wish my work environment could be half as nice as that.

[0] http://geiser.nongnu.org/geiser_1.html#Introduction

Re:A REPL Story by magicbuzz on Wednesday December 02, 2015 @03:28PM (#10665567)
Swift has a REPL. On an OS X command line, simply type 'swift'.
Re:A REPL Story by lispm on Wednesday December 02, 2015 @02:10PM (#10665094)
Imagine if they detect that Lisp and Smalltalk have Inspectors for data... -> more blog posts about the wonders of 'REPL', Clojure and Functional Programming.

> clojure.core defines the vars print-length and print-level

I wonder where all this is coming from? ;-)

Lisp programmers practice interactive 'bottom up programming' for decades now.

See for example Erik Sandewall's article 'Programming in an Interactive Environment: the "Lisp" Experience' from 1978:

https://www.ida.liu.se/ext/caisor/archive/1978/001/caisor-19...

Re:A REPL Story by j-pb on Wednesday December 02, 2015 @03:12PM (#10665475)
Clojure is a lisp.
Re:A REPL Story by davexunit on Wednesday December 02, 2015 @03:16PM (#10665501)
I think what lispm is getting at is that there a large number of Clojure programmers that do not realize that Clojure's features and the workflows it enables have been around for decades.
Re:A REPL Story by j-pb on Wednesday December 02, 2015 @03:56PM (#10665739)
Fair enough, I guess the article is aimed mostly at newbies to clojure though, which mostly come from a non-lisp background.
Re:A REPL Story by lispm on Wednesday December 02, 2015 @04:03PM (#10665786)
That style of interactive exploratory programming is supported by a gazillion of languages and implementations. There is nothing Clojure specific about it.

From the early Lisp to most other forms of Lisp-derived languages (like Logo, Dylan, ...), over APL, Mathematica, up to Apple's Swift...

Re:A REPL Story by j-pb on Wednesday December 02, 2015 @04:07PM (#10665810)
Neither is the article nor I arguing that in any way. It is a case study of developing a clojure program in the repl, done to inspire newcomers, not a scientific article claiming clojure invented the repl.
Re:A REPL Story by lispm on Wednesday December 02, 2015 @05:08PM (#10666221)
It explicitly mentions clojure, functional programming and a repl to enable this.

None of that is necessary. One can nicely use Smalltalk (recent version: Pharo), its object-oriented programming and its interactive IDE for that.

Re:A REPL Story by j-pb on Wednesday December 02, 2015 @05:29PM (#10666331)
Just because it mentions it doesn't means it claims it's necessary.

The author states

" If you're new to Clojure, or functional programming, or languages that have a REPL, I hope this encourages you to crack open a REPL and start to think about your own story. It's a means to whatever end you have in mind. "

and even points to a super general google search.

https://www.google.de/search?client=safari&rls=en&q=repl+dri...

Did you actually read the thing, or just open it close it and decide to hat it because it not CL?

Re:A REPL Story by lispm on Wednesday December 02, 2015 @06:57PM (#10666793)
> Did you actually read the thing, or just open it close it and decide to hat it because it not CL?

The author could benefit from some of the better REPLs of Common Lisp - which for example nicely integrate various tools (inspectors, debuggers, error handling, object-oriented programming, ...) to better support interactive/exploratory programming.

Re:A REPL Story by lispm on Wednesday December 02, 2015 @03:56PM (#10665746)
Can it run Lisp code?
Re:A REPL Story by j-pb on Wednesday December 02, 2015 @04:03PM (#10665791)
Which lisp?
Re:A REPL Story by junke on Wednesday December 02, 2015 @04:27PM (#10665963)
The one that was painfully standardized to avoid this kind of question?

"The Lisp family of languages" vs "Lisp" is an old discussion: see http://lisp-univ-etc.blogspot.fr/2013/01/common-lisp-is-just... for a summary.

Re:A REPL Story by j-pb on Wednesday December 02, 2015 @04:32PM (#10665995)
Ah so scheme then. Fair enough, scheme is probably the most worthy of the title. It's both true to McCarthys mathmatical spirit, and he himself stated that Steele is probably the closest thing to a benevolent dictator in the lisp world.
Re:A REPL Story by lispm on Wednesday December 02, 2015 @04:56PM (#10666143)
Steele hasn't edited the Scheme standard since two or three decades.

Ever wondered why Scheme is called Scheme and not LexicalLisp?

It's a new language, with it's own dialects, standards, libraries, implementations, communities, ...

Lately Steele worked on languages like Java and Fortress. Nothing with Lisp...

Re:A REPL Story by j-pb on Wednesday December 02, 2015 @05:32PM (#10666352)
Yeah why would he. We don't revise lambda calculus every year.
Re:A REPL Story by lispm on Wednesday December 02, 2015 @06:52PM (#10666764)
Yet, Scheme has seen many standard revisions. Without Steele editing it.

The Scheme standard has been edited by others, not Steele. Since three decades. From R2RS in 1985 up to R7RS in 2013.

Re:A REPL Story by lispm on Wednesday December 02, 2015 @04:56PM (#10666148)
McCarthy's Lisp.

http://www.softwarepreservation.org/projects/LISP/lisp15_fam...

Its core lives in every Lisp.

Re:A REPL Story by j-pb on Wednesday December 02, 2015 @05:31PM (#10666348)
Fair enough, but then no lisp in use today is lisp.
Re:A REPL Story by lispm on Wednesday December 02, 2015 @06:08PM (#10666570)
Its core lives in Lisp dialects like Emacs Lisp just fine.

Try GNU Emacs and the REPL:

    M-x ielm

    *** Welcome to IELM ***  Type (describe-mode) for help.
    ELISP> (append '(this is a Lisp) '(REPL))
    (this is a Lisp REPL)

    ELISP> (cons 'This (append '(is a) (list 'Lisp 'REPL)))
    (This is a Lisp REPL)
This code is from McCarthy's Lisp 1.5 Programmer's manual, from 1962, running in Common Lisp:

    CL-USER 6 >  (defun my-length (l)
                   (prog (u v)
                     (setq v 0)
                     (setq u l)
                     a
                     (cond ((null u) (return v)))
                     (setq u (cdr u))
                     (setq v (+ v 1))
                     (go a)))
    MY-LENGTH

    CL-USER 7 > (my-length '(1 2 3 4 5))
    5
That's why it's called a 'Lisp' -> it runs Lisp code.
Re:A REPL Story by jolux on Wednesday December 02, 2015 @01:58PM (#10664999)
Please tell me RET is a backronym for return like you'd hit when you've finished a line in a REPL ;)
Re:A REPL Story by sputnik27 on Wednesday December 02, 2015 @02:17PM (#10665143)
Gosh, the color of the sidebar really hurts.. Am I the only one?
Re:A REPL Story by nanny on Wednesday December 02, 2015 @02:22PM (#10665176)
Nope, it's awful. I use this chrome extension called "reader mode": https://chrome.google.com/webstore/detail/read-mode/nagcaaho...