在Clojure REPL中使用CounterClockwise和Eclipse进行评估 [英] Evaluation in Clojure REPL with CounterClockwise and Eclipse
问题描述
我通常使用Emacs,但被启发再次尝试CCW + Eclipse。我有一个Clojure测试项目与源文件src / user.clj具有以下内容:
I normally use Emacs but was inspired to try CCW + Eclipse again. I have a Clojure test project with a source file src/user.clj with the following contents:
(ns user)
(println "hi")
我有一个REPL, - > Show View-> Other-> Clojure Views-> REPL。
I have a REPL which I started with Window->Show View->Other->Clojure Views->REPL.
当我选择println表达式('printlnhi)'命令输入,表达式本身在REPL窗口中被回显,但没有输出。类似于'(take 10(range))'。
When I select the println expression (all of '(println "hi")') and hit Command-enter, the expression itself gets echoed in the REPL window, but no output occurs. Similar with expressions like '(take 10 (range))'.
如果我直接在REPL中输入表达式, b
$ b
If I type the expression in the REPL directly, and hit Enter, I get
=> (take 10 (range))
但似乎没有任何额外的输出。
but there doesn't seem to be any additional output of the evaluation.
感谢任何想法。我查看了文档,但没有明显跳出我。
Thanks for any ideas. I looked over the docs but nothing obvious jumped out at me.
推荐答案
您需要连接到REPL以获得响应
You need to be connected to a REPL to get a response.
有两种选择:
- 连接到现有的REPL
-
- 将您的项目作为Clojure应用程序运行并自动连接到它的REPL。
现有REPL,可以使用窗口 - >连接到REPL。
To connect to an existing REPL, you can use Window -> Connect to REPL.
要运行项目,右键单击项目;运行方式 - > Clojure应用程序。如果这不是一个选项,右键 - >配置 - >作为Clojure应用程序
To run your project, Right click your project; Run As -> Clojure Application. If that's not an option, Right Click -> Configure -> As Clojure Application
这篇关于在Clojure REPL中使用CounterClockwise和Eclipse进行评估的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!