From cc0eebd9d8a42f3e57d4633c4388faa6d369d2c8 Mon Sep 17 00:00:00 2001 From: Yuri Sizov Date: Mon, 2 Oct 2023 20:11:43 +0200 Subject: Validate `code` tags for class and member references This commit also adds means to manually disable warnings in `code` tags where it's a false positive with the new `skip-lint` attribute. Warnings are now enabled on CI to prevent future errors. --- doc/classes/float.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'doc/classes/float.xml') diff --git a/doc/classes/float.xml b/doc/classes/float.xml index 7d74e3d832..3ffaa60c32 100644 --- a/doc/classes/float.xml +++ b/doc/classes/float.xml @@ -5,7 +5,7 @@ The [float] built-in type is a 64-bit double-precision floating-point number, equivalent to [code]double[/code] in C++. This type has 14 reliable decimal digits of precision. The maximum value of [float] is approximately [code]1.79769e308[/code], and the minimum is approximately [code]-1.79769e308[/code]. - Many methods and properties in the engine use 32-bit single-precision floating-point numbers instead, equivalent to [code]float[/code] in C++, which have 6 reliable decimal digits of precision. For data structures such as [Vector2] and [Vector3], Godot uses 32-bit floating-point numbers by default, but it can be changed to use 64-bit doubles if Godot is compiled with the [code]precision=double[/code] option. + Many methods and properties in the engine use 32-bit single-precision floating-point numbers instead, equivalent to [code skip-lint]float[/code] in C++, which have 6 reliable decimal digits of precision. For data structures such as [Vector2] and [Vector3], Godot uses 32-bit floating-point numbers by default, but it can be changed to use 64-bit doubles if Godot is compiled with the [code]precision=double[/code] option. Math done using the [float] type is not guaranteed to be exact and will often result in small errors. You should usually use the [method @GlobalScope.is_equal_approx] and [method @GlobalScope.is_zero_approx] methods instead of [code]==[/code] to compare [float] values for equality. -- cgit v1.2.3