Skip to content

Commit

Permalink
Merge #1643
Browse files Browse the repository at this point in the history
1643: Check docs in CI r=kvark a=cwfitzgerald

**Connections**

Closes #1637.

**Description**

Doc links will now fail. `cargo doc` doesn't let you pass through flags, so you have to use RUSTDOCFLAGS.

**Testing**

It is.

Co-authored-by: Connor Fitzgerald <[email protected]>
  • Loading branch information
bors[bot] and cwfitzgerald authored Jul 13, 2021
2 parents 4b4e393 + d6e386d commit 226694c
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
8 changes: 8 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,7 @@ jobs:
env:
PKG_CONFIG_ALLOW_CROSS: 1 # allow android to work
RUSTFLAGS: --cfg=web_sys_unstable_apis
RUSTDOCFLAGS: -Dwarnings

steps:
- name: checkout repo
Expand Down Expand Up @@ -118,6 +119,9 @@ jobs:
run: |
cargo clippy --target ${{ matrix.target }} -p wgpu -- -D warnings
# build docs
cargo doc --target ${{ matrix.target }} -p wgpu --no-deps
- name: check native stable (fatal warnings)
if: (matrix.kind == 'compile' || matrix.kind == 'test') && matrix.channel == 'stable'
run: |
Expand All @@ -128,6 +132,10 @@ jobs:
# explicitly don't mention wgpu-hal so that --all-features don't apply to it
cargo clippy --target ${{ matrix.target }} -p wgpu -p wgpu-core -p wgpu-info -p player --examples --tests --all-features -- -D warnings
# build docs
cargo doc --target ${{ matrix.target }} --no-deps
cargo doc --target ${{ matrix.target }} -p wgpu -p wgpu-core -p wgpu-info -p player --all-features --no-deps
- name: check native nightly (non-fatal warnings)
if: (matrix.kind == 'compile' || matrix.kind == 'test') && matrix.channel != 'stable'
run: |
Expand Down
2 changes: 1 addition & 1 deletion wgpu/src/util/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ pub fn make_spirv(data: &[u8]) -> super::ShaderSource {
super::ShaderSource::SpirV(make_spirv_raw(data))
}

/// Version of [`make_spirv`] intended for use with [`Device::create_shader_module_spirv`].
/// Version of make_spirv intended for use with [`Device::create_shader_module_spirv`].
/// Returns raw slice instead of ShaderSource.
///
/// [`Device::create_shader_module_spirv`]: crate::Device::create_shader_module_spirv
Expand Down

0 comments on commit 226694c

Please sign in to comment.