Hi, I'm Tomek.

I'm a software engineer and I solve problems by (not) writing Clojure. You can find me as @_tomekw on Twitter, @tomekw on Mastodon, or @tomekw on Github. I write (mostly) about programming.

Ada programmers: Stéphane Carrez

May 7, 2019

This is series of interviews with software developers interested in Ada programming language. The goal is to promote the community members and the language itself. Do you want to take part in this? Contact me!

The previous interview, with Edward Fish, can be found here.

Today we will talk with Stéphane Carrez. You can follow him on Github or on Twitter.

Could you introduce yourself? What’s your background? What do you do?

While at school I created my own Z80 computer, because my father didn’t want to buy one. Instead, he gave me the Zilog datasheets and encouraged me to build one. I started to write the code in Assembly on a paper and I typed the hexadecimal opcodes by hand on the EPROM programmer. It was fun, difficult but I learnt a lot. My father was also a defensor of Ada (retired now), and he also gave me the opportunity to learn Ada83 with the Alsys compiler in 1986.

After being graduated from ISEP in 1990, I worked on an Ada83 program for the French army during my military service. It was challenging due to the lack of access types for functions and procedures (introduced in Ada 95). Ada generic was the solution but there were bugs on the Alsys compiler (and MS-DOS didn’t helped either).

Later I created another computer board based on 68HC11 and to use it I also did a complete port of the GNU compiler, the GNU binutils and the GNU debugger. My work was integrated in the FSF sources in 2000. The GNAT Ada compiler was working! I was able to run a small Ada program that fit in less than 256 bytes!

With the support for interface types in Ada 2005, I realized I won’t be blocked anymore by a number of limitations in Ada 83 and 95. I started to create a complete framework that would allow building web applications by using Java-like design patterns. Since 2009, I’m building the Ada Web Application framework by using my professional experience in developing Java J2EE applications. Java J2EE is slow and bloated but it defines several useful patterns that help in designing servers. I just pick some of them and implement them in Ada.

In 2016, AdaCore released a first version of the Ada Drivers Library and launched the first MakeWithAda competition. I bought an STM32F746 board, played a little with their drivers and I was soon interested in writing an embedded network IPv4 stack to analyse Ethernet packets (this was a part of my work at Bouygues Telecom). EtherScope was born and I won the competion. Since then I participate in the competition in the judging process.

What is the single feature you love the most in Ada?

There is more than one feature I really love. To cite one, I’ll mention the Ada protected types. Having worked on a lot of multi-threaded C++ applications, the Ada protected type provides the best encapsulation to protect concurrent accesses. Writing safe multi-threaded applications is difficult and I’ve seen many developers doing things wrong, including me from time to time. Ada protected type prevents a lot of mistakes.

What is the single feature you dislike the most in Ada?

Strings. Too many types to represent a string, you have to choose one between 9 possible types. And in many cases you have to pick two (String and Unbounded_String) and then fall in the nightmare of continuously converting a string type into another. Java did it better for that matter.

One string type to rule them all.

How do you see the future of Ada?

Difficult. Ada is not an attractive language to newcommers. Our world is an immediate world where people don’t want to spend time. Developers want to write fast and move on. For that matter, Python and JavaScript are more attractive. The counter part is that many developers think short term: write code quickly, see it working (less than more), deliver it or throw it away. Maintenance is out of scope.

Ada is a language for people who think long term. You have to think more about the design of your program. Because Ada defines a lot of constraints this design phase is more complex and can be longer. It does not fit well in our immediate world where you don’t want to think but see the thing run immediately. Of course the benefit is the quality of the final program. This is why the language fits well for long term and big projects.

We all know Ada 202X is around the corner. What would you like to find in the new release of Ada?

In fact Ada 202X will have many new features that look very promising: parallel loops (AI12-0119-1), Map/Reduce attributes (AI12-0262-1), Bignum packages (AI12-0208-1). To mention one evolution, the new assignment target name described in AI12-0125-3 (@) is nice to simplify constructs where you want to update a value by doing a computation on them.

Instead of:

My_Package.My_Array(I).Field := My_Package.My_Array(I).Field + 1;


My_Package.My_Array(I).Field := @ + 1; 

Now I wish Ada could integrate several features that we see in other languages to simplify the syntax such as:

Do you like what to see here?

Consider subscribing to my newsletter. Get helpful guides, articles, and projects announcements. Low traffic, no spam.

Or subscribe to my Atom feed.