Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Rust Hello World

Preamble

This is a test project for Semantic IR software development specification, implementation, verification. The IR spec is actually basically written. The thing is, even though it is supposed to have a reference compiler that leverages AI to generate code from the spec, that compiler is not yet implemented. So this project used a normal AI code writing interface between the project.yaml and the actual spec documentation to build everything you see. Everything in this repo other than this preamble you just read is generated by AI including the rest of this README.

Why it matters will come later. Yes it is massively over-engineered for a simple hello world, but that's kinda partly the point. Who even writes tests for hello world anyway?


A minimal, portable greeting program realized as a local Rust command-line application. This repository is authored as a Semantic IR project; project.yaml is the canonical, machine-readable record of the product intent, target realization, and verification obligation.

What this project is

This is both a working Rust executable and a deliberately small reference project. Its complete product definition lives in project.yaml: the file names the system’s purpose, the command behavior, its public output contract, the guarantees it makes, the Rust target mapping, and the machine-checkable verification claim. src/main.rs is the Rust realization of that definition, rather than the only record of what the program is meant to do.

Why it matters

“Hello, world!” is intentionally simple enough that every part of the delivery can be inspected. That makes this repository a compact example of semantic-first development: intent is explicit and portable, target-specific code is planned against that intent, and the observable promise is verified end-to-end. The same approach helps larger systems preserve their contracts and verification obligations as implementations evolve or move between targets.

Behaviour

Invoking hello-world must:

  • write exactly Hello, world! followed by one line terminator to standard output;
  • write no bytes to standard error; and
  • exit with status 0.

The program accepts no inputs, has no persistence, and runs as a single-process command.

Target realisation

The reference target is a local Rust CLI supplied by the rust-cli target pack. Its planned implementation is a Cargo binary crate with its entry point at src/main.rs.

Verification

The end-to-end verification claim executes:

hello-world

and expects:

exit status:     0
standard output: Hello, world!\n
standard error:  (empty)

The implementation plan is currently provisional and uses a single vertical slice to realize and verify this behavior before initial human approval and promotion.

About

More important than it looks..

Resources

Stars

Watchers

Forks

Contributors

Languages