67
you are viewing a single comment's thread
view the rest of the comments
[-] FizzyOrange@programming.dev 27 points 2 days ago

It's not because we have tested this program extensively on every C++ compiler, but because the language rules of C++ say so.

Debatable. Saying things in a prose specification doesn't magically make them happen. Tests and reference models can though.

I also don't really agree with the SIL requirements that languages need to have rigorous specifications to be safe. Clearly it's better if they do, but would your rather fly on a rocket controlled by C code or Rust code?

IMO a specification would be really nice to have, but it main purpose is to tick a certification checkbox, which is why the only one that exists was written specifically for that purpose.

[-] copacetic@discuss.tchncs.de 13 points 2 days ago

The specification does not make anything happen but it enables you to say "the implementation is wrong". Of course, you can say that without a spec as well but what does "wrong" mean then? It just means you personally disagree with its behavior. When "wrong" means "inconsistent with the spec" everybody involved can work with more clarity and fewer assumptions. Wrong assumptions can kill people flying rockets.

[-] taladar@sh.itjust.works 5 points 2 days ago

A specification is just another form of implementation that suffers from the very same problem you describe too.

[-] copacetic@discuss.tchncs.de 2 points 2 days ago

Fair enough. In practice, we resolve it recursively with a higher level specs and at some point it is just "someone wants that". In commercial software development (where SIL is used) that is a customer who pays for it or some executive.

load more comments (5 replies)
load more comments (8 replies)
this post was submitted on 12 Nov 2024
67 points (95.9% liked)

Rust

5989 readers
51 users here now

Welcome to the Rust community! This is a place to discuss about the Rust programming language.

Wormhole

!performance@programming.dev

Credits

  • The icon is a modified version of the official rust logo (changing the colors to a gradient and black background)

founded 1 year ago
MODERATORS