News for hackers. Stuff that matters.
Re:A learning platform to teach the Ada and SPARK programmin... by acomjean on Wednesday July 25, 2018 @04:45PM (#17612660)
I programmed a radar system with Ada, I guess that counts a defense system. The language grew on me. I miss parts of it, but it suffers from the chicken egg problem. Not enough people using it to make useful libraries from it so it doesn't get a lot of new users.

Also the lack of a really good compiler that was free held ada back, but that shouldn't be a problem anymore. (https://en.wikipedia.org/wiki/GNAT)

The other knock on ada was it was slow. All the runtime checks eat up cpu resources which made it slower than the competition.

The language and package system are solid though. I was switching between C and Ada for a while and I found programming in Ada to be be a better experience.

Re:A learning platform to teach the Ada and SPARK programmin... by jnbiche on Wednesday July 25, 2018 @06:43PM (#17613591)
> All the runtime checks eat up cpu resources which made it slower than the competition.

You can turn off all the runtime checks. When you do, Ada is competitive with Rust and even C.

But user jonathanstrange's criticisms above of Ada and Adacore hit the nail on the head, in my opinion. Ada's a great language but unless Adacore revisits the licensing, it's doomed. Now, even the defense industry has for the most part abandoned Ada, despite it being perfectly suited for the industry.

Re:A learning platform to teach the Ada and SPARK programmin... by jononor on Thursday July 26, 2018 @05:23AM (#17616125)
What do they use instead of Ada, in the defense industry?
Re:A learning platform to teach the Ada and SPARK programmin... by mcguire on Thursday July 26, 2018 @11:25AM (#17618170)
I believe C, C++, and Java depending on which niche you look at, according to the job ads I've seen.

Actually, I haven't seen and Ada ads sin a long time.

Re:A learning platform to teach the Ada and SPARK programmin... by acomjean on Thursday July 26, 2018 @10:43AM (#17617860)
we were heading to C, C++ when I left over a decade ago.
Re:A learning platform to teach the Ada and SPARK programmin... by pecg on Wednesday July 25, 2018 @06:14PM (#17613414)
> The other knock on ada was it was slow.

I'm curious, is the compilation time that takes too much, or is it the execution time? I'm really interested in learning the language, but I don't want to end-up with programs that generate slower native code, compared to that of C. What's your experience with it?

Re:A learning platform to teach the Ada and SPARK programmin... by PeCaN on Wednesday July 25, 2018 @06:34PM (#17613545)
It's not any slower than C. In some cases the compiler can actually generate better code because of stricter rules on pointer aliasing. You can also do more with only stack allocation in Ada, which is a huge win.

It does generate some extra code for things like range checks and checking invariants, i.e. things you can skip in C to write buggy code.

Re:A learning platform to teach the Ada and SPARK programmin... by Fabien_C on Thursday July 26, 2018 @05:04AM (#17616069)
There's a little benchmark project here: https://github.com/frol/completely-unscientific-benchmarks

The Ada implementation is the second fastest behind C++.