Hacker News new | ask | show | jobs
by sea6ear 3934 days ago
This blew my mind the first time some one showed me, and is one of the reasons I currently prefer C to other mainstream compiled languages.

Edit: I suppose it is possible to get some version of a repl with C++ (Cling?), Java (Beanshell, Java 9?), C# (Mono, but not currently .Net?). But each of those seems generally a bit harder to get access to than simply calling gdb on a binary with debugging symbols enabled.

2 comments

C# has REPL in the immediate window when the debugger is running; so it's kind of like using GDB as a REPL for C. Although it is somewhat limited in what you can do.
That's actually really good to know about.

Visual Studio's a little bit heavyweight, but if you're programming C#, there's a good chance that's what you're using anyway.

beanshell is quite painful. I like using the repl of a jvm language to explore classes and methods. Like slime+clojure or groovysh or jruby.