Live data from Hacker News

How an Engineering Company Chose to Migrate to D

dlang.org

51–60 of 170 posts

Re: How an Engineering Company Chose to Migrate to D

#51
post #21
post #11

Earlier quoted context omitted.

Developers can learn new languages though if a company lets them. (Edited to be less glib. bad habit)

A friend (C# dev) just refused a job from a company in the Netherlands, for a D dev position. I don't know if it's the same company. It's not that they're not capable, but some will not want to risk several years of their career to learn it.

I can understand this. If I had to pick a marketable/future employment language today, I would pick C# over D (I have used both).

Re: How an Engineering Company Chose to Migrate to D

#52

> Nowadays, whenever D is publicly evaluated, the younger languages Go and Rust are often brought up as alternatives. Here, we need not go into an in-depth comparison of these languages because both Rust and Go lack one feature that we rely on heavily: nested functions with access to variables in their enclosing scope. Maybe I've misunderstood, but aren't Rust's closures [1] exactly what the author is describing? Spe…

The interaction between borrow-checking and closures restricts what else you can do while you have a closure in scope that closes over some variables, so (like many rust features) they aren't a drop-in replacement for their counterpart in other langs.

Re: How an Engineering Company Chose to Migrate to D

#53
post #50
post #40

Earlier quoted context omitted.

>While the article states that other languages were evaluated, it seems as though the project was motivated entirely by the author and the evaluation was just paying lip service to what was basically a foregone conclusion. Now you understand how all of these "How we chose this language" writeups work.

Yeah, almost all the time its the inclination of an individual towards a new language that becomes the driving factor of migration rather than the actual shortcoming of current language.

Except that "the inclination of an individual towards a new language" is because of "the actual shortcoming of current language."

Re: How an Engineering Company Chose to Migrate to D

#54

While the article states that other languages were evaluated, it seems as though the project was motivated entirely by the author and the evaluation was just paying lip service to what was basically a foregone conclusion. Don't get me wrong, I like D from the small amount of playing I've done with it -- and maybe it is the best tool for their purposes -- but this doesn't strike me as an impartial evaluation. The need…

The biggest problem is they have engineers who have turned their hands to programming, one would expect, without the formal training and so have latched onto various antipatterns without knowing any better because Pascal allowed them to get away with it - painting themselves into a corner. He mentioned an awful lot of code that would have to be refactored, and it could be that they are just too far down the rabbit ho…

Very strange in a hardcore technical programming context, I would have thought they would have used Fortran which is still being actively developed.

I have never seen a reasoned argument why C++ vs Fortran is better for technical programming.

Re: How an Engineering Company Chose to Migrate to D

#55

This article seems to ignore two of the most important reasons to choose one language over another. Specifically: 1)Expressiveness in the given problem domain. Some languages are really great in particular niches. 2)Availability of devs. The ability to hire and retain a really great team makes or breaks projects, and while a smart, motivated dev can learn any language, it's definitely a factor in their choice to work…

3) Tooling, ecosystem, and library availablity. Picking language X over Y is unwise if it means spending a bunch of time writing the libraries you need, even if it's ultimately more expressive.

This, turns out, is ultimately the most important thing amongst most important things. I've invested quite a lot of effort and time in D, back when D1 was around and D2 was a newsgroup post. D1 was everything I wanted out of better C, while d2 looked like it ought to be a better c++. Two years into heavy D programming, d2 vs d1+tango vs phobos aside, most of my time was spent in hunting for things or re-inventing things for weeks which I could've got in minutes with more popular language. Now that I'm older and hopefully wiser, I just go for my standard c toolbelt or, more often, python and be done with whatever I wanted to do without 'the hunt' (often for unmaintened things or things out of my knowledge scope - so I can't even re-implement).

With all that said... Lisp' siren call is still out there, and experience tells me it will be the same. (As it was once before)

Re: How an Engineering Company Chose to Migrate to D

#56
post #50

Earlier quoted context omitted.

Yeah, almost all the time its the inclination of an individual towards a new language that becomes the driving factor of migration rather than the actual shortcoming of current language.

Except that "the inclination of an individual towards a new language" is because of "the actual shortcoming of current language."

[deleted]

Re: How an Engineering Company Chose to Migrate to D

#57

This article seems to ignore two of the most important reasons to choose one language over another. Specifically: 1)Expressiveness in the given problem domain. Some languages are really great in particular niches. 2)Availability of devs. The ability to hire and retain a really great team makes or breaks projects, and while a smart, motivated dev can learn any language, it's definitely a factor in their choice to work…

3) Tooling, ecosystem, and library availablity. Picking language X over Y is unwise if it means spending a bunch of time writing the libraries you need, even if it's ultimately more expressive.

Exactly that's why for CFD Fortran still has so many advantages.

Re: How an Engineering Company Chose to Migrate to D

#58

This article seems to ignore two of the most important reasons to choose one language over another. Specifically: 1)Expressiveness in the given problem domain. Some languages are really great in particular niches. 2)Availability of devs. The ability to hire and retain a really great team makes or breaks projects, and while a smart, motivated dev can learn any language, it's definitely a factor in their choice to work…

0) Tool satisfaction

> motivated dev can learn any language

The key word is "motivated". That's why I'm an expert user of C++98 and D but I can't learn Go, Python, C++11, etc.

> able to get really passionate devotees of the language

That.

Re: How an Engineering Company Chose to Migrate to D

#59

This article seems to ignore two of the most important reasons to choose one language over another. Specifically: 1)Expressiveness in the given problem domain. Some languages are really great in particular niches. 2)Availability of devs. The ability to hire and retain a really great team makes or breaks projects, and while a smart, motivated dev can learn any language, it's definitely a factor in their choice to work…

3) Tooling, ecosystem, and library availablity. Picking language X over Y is unwise if it means spending a bunch of time writing the libraries you need, even if it's ultimately more expressive.

This is definitely key - one startup I worked for was messing around with live voice capture and processing, voice recognition, etc.. by and large the libraries we had access to that could help do tiny manipulations, cutting, processing of the waveform data was primarily C. We wrote most of our code in C++ because we could directly call C functions and use header files directly.

This was 15 years ago, but I honestly don't know what language I would use today. It's funny but sometimes binary data handling isn't a particular language's strong suit simply because they don't have the primitives to handle it, or if they do, the APIs to handle them are awkward or unnecessarily verbose. It's kinda neat that in C/C++ you can take a 1MB byte buffer and pass it to a function starting at 30% in. In other languages its like you have to pass in the whole thing and another parameter to tell it where to start. I get that's why C/C++ is in the situation it's in (security - but that's why I don't use C/C++ to handle web requests), but sometimes tasks need that.

Re: How an Engineering Company Chose to Migrate to D

#60
post #5

Maybe I am too timid, but the closing word saying that once the transpiler is ready they could switch overnight seems a bit optimistic. I feel that splitting as much as possible the project into chunks/components and then replacing them one by one sounds more realistic (with the appropriate test harness). Maybe that is the plan but it is not touched in the post. And then maybe an issue that is not that bad, but you a…

There is precedent for this, even within D. The DMD compiler was originally written in C, and someone went to the effort to write a C to D transpiler, worked on it until it was flawless, then ran it overnight and did the transition all at once: https://github.com/dlang/dmd/pull/4923

I think the Go compiler did something similar.

It certainly requires iteration of continuously attempting the translation until it works, and fixing bugs either in the transpiler or in the original codebase. But once everything seems to be in order, you can do the transition all at once.

Post reply on HN