W3cubDocs

/Rust

Constant std::f64::INFINITY

pub const INFINITY: f64 = f64::INFINITY; // +Inff64

Infinity (∞). Use f64::INFINITY instead.

Examples

// deprecated way
let inf = std::f64::INFINITY;

// intended way
let inf = f64::INFINITY;

© 2010 The Rust Project Developers
Licensed under the Apache License, Version 2.0 or the MIT license, at your option.
https://doc.rust-lang.org/std/f64/constant.INFINITY.html