logoalt Hacker News

jandrewrogerslast Sunday at 6:35 PM8 repliesview on HN

For those interested, the F-35 (née Joint Strike Fighter) C++ coding standards can be found here, all 142 pages of it:

https://www.stroustrup.com/JSF-AV-rules.pdf


Replies

tgvlast Sunday at 7:26 PM

From quickly glancing over a couple of pages, that looks sensible. Which makes me curious to see some exceptions to the "shall" rules. With a project of this size, that should give some idea about the usefulness of such standards.

Animatslast Sunday at 11:53 PM

As is common in hard real time code, there is no dynamic allocation during operation:

    allocation/deallocation from/to the free store (heap) 
    shall not occur after initialization.
This works fine when the problem is roughly constant, as it was in, say, 2005. But what do things look like in modern AI-guided drones?
show 5 replies
shepherdjerredlast Sunday at 7:55 PM

I wonder if they use static analysis to enforce these rules, or if developers are expected to just know all of this

show 2 replies
genewitchlast Sunday at 8:57 PM

In general, are these good recommendations for building software for embedded or lower-spec devices? I don't know how to do preprocessor macros anyhow, for instance - so as i am reading this i am like "yeah, i agree..." until the no stdio.h!

show 2 replies
extraduder_irelast Sunday at 7:38 PM

The first time I came across this document, someone was using it as an example how the c++ you write for an Arduino Uno is still c++ despite missing so many features.

raffael_delast Sunday at 7:51 PM

Interesting font choice for the code snippets. I wonder if that's been chosen on a whim or if there is a reason for not going with mono space.

show 1 reply
mslalast Sunday at 7:46 PM

Interesting they're using C++ as opposed to Ada.

show 2 replies
OhNoNotAgain_99last Sunday at 7:31 PM

[dead]