I am not a Ruby developer. However, I believe that the reason is Proportional Transparency.
Most Clojure's idiomatic functions are pure functions that obey referential transparency. As a result, I personally find it much easier to test functions that are independent autonomous units, and they somewhat provide the goal of unit tests. Clojure being a highly destructed language, prefers most features to be stateless. It makes a clear distinction between code in which side effects occur, and states are maintained using various other alternatives such as var , refs , agents , atoms , etc., Keeping most of your code clean, side effect and link transparent .
I feel that any code structured around link-transparent and stateless functions will automatically benefit from REPL, whether in Ruby or any other programming language.
Although the CLI provided by another language will be equally useful for most practical purposes, the concept of Read, Eval, Print and Loop not the same in LISP as in any other language. Any non-homoiconic language non-homoiconic not have a READ phase, and it would just read a text representation or string, however in LISP, the READ phase can actually parse any form of s-expression that you throw at it. For more details see below 2 answers:
Is LISP the only language with REPL?
How is the LISP read-eval-print loop different from Python?
Abhiroop sarkar
source share