mirror of
				https://github.com/RGBCube/serenity
				synced 2025-10-31 11:12:45 +00:00 
			
		
		
		
	LibJS: Add Value::is_integer()
This commit is contained in:
		
							parent
							
								
									88738aefa3
								
							
						
					
					
						commit
						8137f40b73
					
				
					 2 changed files with 2 additions and 2 deletions
				
			
		|  | @ -60,6 +60,7 @@ public: | |||
|     bool is_infinity() const { return is_number() && __builtin_isinf(as_double()); } | ||||
|     bool is_positive_zero() const { return is_number() && 1.0 / as_double() == __builtin_huge_val(); } | ||||
|     bool is_negative_zero() const { return is_number() && 1.0 / as_double() == -__builtin_huge_val(); } | ||||
|     bool is_integer() const { return is_finite_number() && (i32)as_double() == as_double(); } | ||||
|     bool is_finite_number() const | ||||
|     { | ||||
|         if (!is_number()) | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Linus Groh
						Linus Groh