Hacker News new | past | comments | ask | show | jobs | submit login

D & Nim (especially Nim) are very appealing from a language perspective, but the lack an IDE undermines the advantages they bring.

I personally won't consider using a language for a meaningful project unless it has a decent debugger, and reasonable refactoring; ie. at least find references & rename.

Beef is building on an IDE, which is a refreshing take, but it's still too early.




You're spot on that D is lacking a batteries-included IDE, but there are some good options available.

D in emacs works very well, but you'll have to put some work into it. Spacemacs (https://www.spacemacs.org/) makes the work a little easier, here's my .spacemacs file if anyone is interested https://gitlab.com/snippets/1942930

Using that .spacemacs file you should be able to launch a fully prepped for D! The only other dependencies are a D compiler and DCD (https://github.com/dlang-community/DCD) built and in your PATH. I'd be happy to answer any questions if something doesn't work.

Other IDEs with a languageserver implementation can make use of DLS https://github.com/d-language-server/dls. VSCode and sublime are two I've had good success with.. but I always end up back with emacs ;)

As for a debugger, you can debug any D program with GDB/LLDB (depending on if you compile with dmd/lcd). Then you can use any graphical debugger that uses gdb. Nemiver is my favorite, then there's a few web based ones that are nice: https://www.gdbgui.com/


D works fantastic with VS Code. See here:

https://wiki.dlang.org/Editors

Also had really good luck doing D with Spacemacs, but Spacemacs is a hit or miss to setup for me. Other times I just use Sublime Text for the syntax highlighting.


Nim also works very well in vscode. Inline compiler errors as you edit, and so on.


I can't remember what I used for Nim, I think I either used Nano or vim just because I've only tested it once or twice. I havent used it heavily yet, though I do have an interest in Nim, since I do enjoy Python programming.


My own pet peeve about D is the lack of local documentation. If I install my system's compiler packages¹ I receive basically no documentation at all. That is a huge difference to the experience with nim/rustc/go/$others which all provide a nice fat $lang-doc package in their Suggests field, and all of those contain full standard library docs/tutorials/etc.

1. gdc or ldc on Debian. The experience /may/ be different with the dmd repositories, but being external they're of less interest to me.


D comes with an interesting utility called `dman`. Run it from the command line and as an argument give it a D topic and it'll open a browser on the topic.

    dman dman
will, of course, open the browser on a page about dman.


Which, as I noted, is still a very different experience from go/nim/rust in Debian. It wasn't a pet peeve about no documentation, it is about how I can interact with it compared to to other languages.


It is provided by dmd as part of the download.

You can also get soft copies (i.e. mobi, pdf) and the docs as part of the d-apt repository for debian.

Depending on the nature of distribution it is probably just in a different package (or the package maintainer needs yelling at).

https://d-apt.sourceforge.io


> It is provided by dmd as part of the download.

Which leads me to wonder why we don't have dmd{,-doc} in Debian now, given it has been ~3 years since the compiler was open sourced. I can't even find an ITP in a quick search :/


D command line tools have a `-man` switch which will open the browser on the manual for the tool, such as:

    dmd -man


I'd recommend using Dash (on Os X) or Zeal (Linux and Windows) if you want to have an easily browseable local version of the docs.


I'm not an IDE user, but I know that certain D programmers use Visual Studio (with VisualD) and seem happy. Did you try that option?


Visual Studio with Visual D is a top notch D experience.


Nim works very well with Emacs and Visual Studio Code at the very least, also Vim (from reports by others) - including debug support. What are you missing?


Debugging and (semantic) renaming. As said, this is the minimum requirements I pose on any language for production use. Nim in VS Code lacks both.

There's some limited debugging support at the generated C code, but this is not sufficient for me.


it should work on nim source level as well: if there are any problems ,that's a bug,so please report it. (disclaimer: me & my partner also work on a bit more advanced commercial debugger environment which also targets nim, so I guess there are many kinds of efforts)


Glad to hear there's commercial interest for Nim!


it's still not in beta: i mostly wanted to focus on the "people are thinking about it" part :)


VisualD is pretty damn good, visual code has a few D plugins that are ok to excellent when they work (which is most of the time)

There is also a D specific IDE which I can't remember the name of which is probably best if you just want something that works (it's pretty lightweight)


What C IDE do you use?


FWIW, I did some embedded development in C (STM32) using Eclipse, and I was astonished by how nice the whole environment was.




Join us for AI Startup School this June 16-17 in San Francisco!

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: