mirror of
https://github.com/zenorogue/hyperrogue.git
synced 2024-12-18 23:10:26 +00:00
walker::peek() is now const
This commit is contained in:
parent
536c1c21ea
commit
5e87f08f54
@ -269,7 +269,7 @@ template<class T> struct walker {
|
||||
template<class U> walker operator + (U t) const { walker<T> w = *this; w += t; return w; }
|
||||
template<class U> walker operator - (U t) const { walker<T> w = *this; w += (-t); return w; }
|
||||
/** \brief what T are we facing, without creating it */
|
||||
T*& peek() { return at->move(spin); }
|
||||
T*& peek() const { return at->move(spin); }
|
||||
/** \brief what T are we facing, with creating it */
|
||||
T* cpeek() { return at->cmove(spin); }
|
||||
/** \brief would we create a new T if we stepped forwards? */
|
||||
|
Loading…
Reference in New Issue
Block a user