Changeset - r28485:781fef3b0a48
[Not reviewed]
master
0 1 0
Peter Nelson - 3 months ago 2024-01-15 22:49:25
peter1138@openttd.org
Codechange: Make geometry methods constexpr.
1 file changed with 2 insertions and 2 deletions:
0 comments (0 inline, 0 general)
src/core/geometry_type.hpp
Show inline comments
 
@@ -57,13 +57,13 @@ struct RectPadding {
 
	 * Get total horizontal padding of RectPadding.
 
	 * @return total horizontal padding.
 
	 */
 
	inline uint Horizontal() const { return this->left + this->right; }
 
	constexpr uint Horizontal() const { return this->left + this->right; }
 

	
 
	/**
 
	 * Get total vertical padding of RectPadding.
 
	 * @return total vertical padding.
 
	 */
 
	inline uint Vertical() const { return this->top + this->bottom; }
 
	constexpr uint Vertical() const { return this->top + this->bottom; }
 
};
 

	
 
inline const RectPadding RectPadding::zero{};
0 comments (0 inline, 0 general)