https://JimFawcett.github.io/RustBasicDemos - repository documentation
Simple code demos: code structure, types, file_io, ... I am starting to look seriously at Rust, and will be writing lots of demo code to be sure that I understand. Now, these demos are just an unmanicured exploration trail. Once I know more I will trim them to be useful for others trying to climb the same path.
For now, the demos are:
- data_lifecycle
- data_types includes simple probes for each of the Rust data types.
- demo_lib and demo_test - simple demonstration of using sister library and other files in src.
- display library provides functions to display the type and value of a variable passed as an argument. Libraries can't write to the console, so library tests are deferred to a separate binary.
- display_test uses the local display crate to test writing information to the console.
- file_io reads from a file and displays results. will add file writes soon.
- function_probes - passing arguments including functions
- generic_probes - generic functions and structs
- ops_probes - just starting, will explore functions and lambdas.
- rust_modules - hello world for modules.
- string_probes - many small experiments that need trimming
-
rust_probes demos for
- variations on print! formatting
- std::Debug formatting for Rust types
- formatting floats showing use of format flags for exp notation, precision, alignment in field, ...
- copy, move, clone, Drop trait, Clone trait. Includes simple but useful module demo.
- vector_probes - a few simple demos.