• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

bitshifter / glam-rs / 345 / 8
94%
main: 97%

Build:
Build:
LAST BUILD BRANCH: affine3
DEFAULT BRANCH: main
Ran 16 Apr 2020 12:15PM UTC
Files 26
Run time 4s
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

16 Apr 2020 11:50AM UTC coverage: 78.868% (+5.4%) from 73.494%
CARGO_FEATURES="mint rand serde packed-vec3 debug-glam-assert transform-types"

push

travis-ci

web-flow
Migrated from using cfg-if to setting mutually exclusive cfg values via build.rs (#55)

I was having a few issues with cfg-if like rustfmt didn't seem to like it and neither did tarpaulin.

Separate to that it seemed like checking target features and features in rust code was getting complicated with more targets and features. So instead I'm doing the more complex logic in rust code to generate mutually exclusive rust-cfg's that can be checked in Rust code. This is independent of whether or not cfg-if it being used.

For example:

```
    pub fn length(self) -> f32 {
        #[cfg(vec3sse2)]
        unsafe {
            _mm_cvtss_f32(_mm_sqrt_ss(self.dot_as_m128(self)))
        }

        #[cfg(vec3f32)]
        {
            self.dot(self).sqrt()
        }
    }
```

`cfg-if` using `else if` and `else` blocks but we don't have that with plain on `#[cfg(name)]`, instead I'm creating mutually exclusive cfgs which can both exist in the same function because they'll never both be compiled.

2885 of 3658 relevant lines covered (78.87%)

1.28 hits per line

Source Files on job 345.8 (CARGO_FEATURES="mint rand serde packed-vec3 debug-glam-assert transform-types")
  • Tree
  • List 0
  • Changed 9
  • Source Changed 9
  • Coverage Changed 8
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Build 301
  • Travis Job 345.8
  • 4c8a2dad on github
  • Prev Job for CARGO_FEATURES="mint rand serde packed-vec3 debug-glam-assert transform-types" on master (#339.8)
  • Next Job for CARGO_FEATURES="mint rand serde packed-vec3 debug-glam-assert transform-types" on master (#356.8)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc