[Semi-OT] I don't want to leave this language!

Jonathan M Davis via Digitalmars-d-learn digitalmars-d-learn at puremagic.com
Wed Dec 7 13:52:22 PST 2016


On Wednesday, December 07, 2016 15:17:21 Picaud Vincent via Digitalmars-d-
learn wrote:
> However I think that to popularize/attract people to use D, it is
> very important, to have a mechanism/feature that allows you to be
> close to the "zero overhead" situation.

You can do that without throwing away all of druntime and Phobos. You just
don't use the stuff with the overhead that you can't afford - e.g. if you
can't afford the GC, then don't use it. @nogc guarantees that for you. And
if you can't afford exceptions, then nothrow does that for you. IMHO, if you
ditch druntime and Phobos over GC concerns, you're throwing the baby out
with the bath water. Without druntime, you don't even get assertions or unit
tests or static constructors or array bounds checking or... I just can't
agree that throwing out druntime makes sense even in most really
performance-critical environments. Certain features would need to be
avoided, but it doesn't require throwing everything out.

That being said, if someone wants to make their life harder by insisting on
using D without even druntime, then that's their choice. I think that it's
an unnecessarily extreme approach even for really performance-centric code,
but they're free to do what they want.

- Jonathan M Davis



More information about the Digitalmars-d-learn mailing list