We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Coordinate2D::withHeight
1 parent 7a36531 commit a8284afCopy full SHA for a8284af
1 file changed
include/mcpp/util.h
@@ -142,7 +142,7 @@ struct Coordinate2D {
142
* @param coord The Coordinate2D object.
143
* @param y The y value.
144
*/
145
- constexpr Coordinate withHeight(int y);
+ constexpr Coordinate withHeight(int y) const;
146
147
/**
148
* @brief Adds two Coordinate2D objects.
@@ -201,7 +201,7 @@ struct Coordinate2D {
201
int z;
202
};
203
204
-constexpr Coordinate Coordinate2D::withHeight(int y) {
+constexpr Coordinate Coordinate2D::withHeight(int y) const {
205
return Coordinate(this->x, y, this->z);
206
}
207
0 commit comments