The property of software or a programming language preventing classes of invalid or hazardous behavior.
Program safety is a benefit of Rust for application backends and software infrastructure. It has three aspects: type safety, memory safety, and thread safety. section 1.2.2
Rust’s compile-time type checking enforces type constraints:
The compiler infers unspecified types where possible and reports conflicts or cases it cannot resolve, helping eliminate a class of runtime errors. section 1.2.2
Memory safety is identified as a distinctive aspect of Rust, with its detailed analysis deferred. section 1.2.2
Thread safety is named as a third aspect, but its treatment is not detailed here. section 1.2.2
How Rust Servers, Services, and Apps covers it
How deep it goes
Distinguishes three safety aspects and explains compile-time type checking, while deferring detailed memory-safety analysis.
Examples
Contrasts manual memory management in C and C++ with garbage-collected languages including Java, C#, Python, Ruby, and Go.
What you can do after
Understand how compile-time type checking helps prevent a class of runtime errors.
How it connects
Connects type safety with static typing and compile-time checking, and names memory safety and thread safety.
Sutskever's ListAGI safety is the field concerned with preventing artificial general intelligence from causing unintended, harmful, or uncontrolled outcomes.
Natural Language Processing in Action, Second EditionAI safety is the field concerned with preventing artificial intelligence systems from causing harmful outcomes and maintaining reliable human control, including over long-term risks.
state machine safetyincludes · State machine safety is the property that no two processes apply different log entries at the same index to their state machines.
livenesscontrasts with · Liveness is a correctness property requiring that a system eventually makes specified progress or produces a desired event or condition.
securitycontrasts with · The protection of systems, information, resources, and operations against unauthorized access, use, disclosure, alteration, disruption, or destruction.
This explainer was generated by Manning's knowledge graph from the text of Rust Servers, Services, and Apps. The section links point to the parts of the book it draws on.