diff --git a/README.md b/README.md index b18304d8f1..77974c97ec 100644 --- a/README.md +++ b/README.md @@ -34,7 +34,7 @@ However, many things aren't implemented yet. That means that while being technic ![Sky shader](docs/assets/sky.jpg) -```rust +```rust,no_run use glam::{Vec3, Vec4, vec2, vec3}; #[spirv(fragment)] diff --git a/crates/spirv-builder/README.md b/crates/spirv-builder/README.md index 5a3fe73074..ffca313fd1 100644 --- a/crates/spirv-builder/README.md +++ b/crates/spirv-builder/README.md @@ -10,7 +10,7 @@ It takes care of pulling in the `SPIR-V` backend for Rust, `rustc_codegen_spirv` ## Example -```rust +```rust,no_run use spirv_builder::{MetadataPrintout, SpirvBuilder}; fn main() -> Result<(), Box> { @@ -23,7 +23,7 @@ fn main() -> Result<(), Box> { This example will build a shader crate called `my_shaders`. You typically insert this code in your crate's `build.rs` that requires the shader binary. The path to the shader module's binary will be set in the `my_shaders.spv` environment variable, which you can include in your project using something along the lines of: -```rust +```rust,ignore const SHADER: &[u8] = include_bytes!(env!("my_shaders.spv")); ``` diff --git a/crates/spirv-std/README.md b/crates/spirv-std/README.md index 7cba186be4..7e1fd5ff49 100644 --- a/crates/spirv-std/README.md +++ b/crates/spirv-std/README.md @@ -10,7 +10,7 @@ This crate gives a `rust-gpu` shader access to the required `#![spirv(..)]` attr Here is a small excerpt to see what a shader would look like. See [source][source] for full details of the shader that generates above image. -```rust,no_run +```rust,ignore use spirv_std::spirv; use glam::{Vec3, Vec4, vec2, vec3};