mirror of
https://github.com/servo/servo.git
synced 2025-08-05 13:40:08 +01:00
Fixed some clippy warnings in components (#32107)
* Fixed some clippy warnings in components * Updated handling of NaN values in comparison * Updated formatting using ./mach fmt
This commit is contained in:
parent
f70413baba
commit
007a72fe4d
9 changed files with 20 additions and 29 deletions
|
@ -326,7 +326,7 @@ impl WebGLTexture {
|
|||
},
|
||||
EXTTextureFilterAnisotropicConstants::TEXTURE_MAX_ANISOTROPY_EXT => {
|
||||
// NaN is not less than 1., what a time to be alive.
|
||||
if !(float_value >= 1.) {
|
||||
if float_value < 1. || !float_value.is_normal() {
|
||||
return Err(WebGLError::InvalidValue);
|
||||
}
|
||||
self.upcast::<WebGLObject>()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue