To me, it was hard to write code in Ada. Lots of niceties from other languages were unavailable in Ada, by design. For example there were no variable argument lists.
It grew on me though, and several years later I worked on a commercial project that used Ada. I was surprised because I expected adopting Ada to be like adopting the adopting the tax code.
Then I realized one thing - although Ada is harder to write, it is nice to have an existing Ada project. And people who have done Ada a while learn to think in Ada and it's not as hard to be expressive.
It's also possible to be pretty accurate in Ada. You can know exactly what the largest or smallest integer is. Moreover you can define integers of a specific range, like -11 to 219.
Nowadays all of that has matured and I think ada is a viable commercial language, and interesting things like spark have happened.
Too bad in the intervening years other languages haven't changed much.
For example, C could have added modules. I guess nobody cares about C.
Yeah, just check the list of features for C2X, WG14 isn't that keen in innovating that much, nor in fixing C's flaws.
Ada does things slightly differently. It manages to separate out the various parts of OOP into different language constructs, and this makes it possible to pick and choose what you need, and not get everything including the kitchen sink when you try to use one thing (like inheritance.)
So no, I never had any big deal with inheritance in any language, and in what concerns Ada its tag based dispatch is also quite interesting as idea.
Your generated code is free:
So yeah, you can go that route and I have done so, poor man's modules, as it helped to keep me sane with C, but it requires discipline.
That pretty much defines software engineering.
For as long as I have been coding, I’ve watched people and corporations chase the will’o the wisp of the “undisciplined coder,” where we can hire naive, barely-educated children, straight out of school, and mold them into our personal “coding automatons,” or even better, let people who are experts in other domains, create software, without having to deal with “annoying” engineers.
So...how’s that working out?
Even when we have AI creating software (and we will), the AI will still need disciplined requirements, which, I suspect, will look a lot like...code.
The outcome of Azure Sphere having chosen C as their main SDK language is proving itself without surprises,
https://techcommunity.microsoft.com/t5/internet-of-things/az...
Not to mention that no matter how disciplined you are, you will make mistakes, and having the compiler catch those for you is valuable.
It also means that the discipline applied by the programmer can be focused on areas that can't be checked or enforced by a compiler.
Fantastically if the goal is to set up recurring revenue to maintain the produced systems.
> Even when we have AI creating software (and we will), the AI will still need disciplined requirements, which, I suspect, will look a lot like...code.
https://github.com/webyrd/quines is an interesting example of writing code to create code based on a specification. Perhaps not the AI code generator of some people's dreams, but it exists today.
For example, when I was writing ObjC and PHP, I got used to using Whitesmiths indenting. Once I started writing Swift, it was more appropriate to use KNF style.
It took a couple of months of having to remember to not use the old indenting style, but I haven’t given indenting any thought in years.
”We are what we repeatedly do. Excellence, then, is not act; but a habit.” -Attributed to Aristotle
So well that it was a large part of the reason I accepted an offer (today in fact) somewhere else, life is too short for that mess.
You could even have this type safety on the linker level as far as C is concerned. You just need an object file format that exports C types for symbols. This is not done on any of the (few) systems I know, and probably for practical reasons.
Some other languages give you this link time safety, but I assume at the cost of less interoperable object files.
Isn’t this similar to package private in Java or internal in C#?
So client A sees mylib-public-A, client B sees mylib-public-B, but both link to the same mylib so to speak.
And since it is available in Ada, it is rivalled today.
More to the point, Ada allows for multiple interface packages, an idea also copied by Modula-3, where the same package can be exposed in different ways to multiple clients.
For example, the same package can have a public interface for in-house consume that is wider than the official public interface for third parties.