Mercurial > octave
diff liboctave/util/unwind-prot.h @ 27177:8498dccc15c7
minor style fixes
* action-container.h, functor.h, oct-binmap.h, oct-refcount.h,
sparse-sort.cc, sparse-sort.h, str-vec.h, unwind-prot.h:
Use m_ prefix for class data members and s_ prefix for static data
members. Minor style fixes.
author | John W. Eaton <jwe@octave.org> |
---|---|
date | Wed, 12 Jun 2019 11:03:06 -0500 |
parents | 00f796120a6d |
children | 2f8428b61bd6 |
line wrap: on
line diff
--- a/liboctave/util/unwind-prot.h Wed Jun 12 10:51:58 2019 -0500 +++ b/liboctave/util/unwind-prot.h Wed Jun 12 11:03:06 2019 -0500 @@ -41,7 +41,7 @@ { public: - unwind_protect (void) : lifo () { } + unwind_protect (void) : m_lifo () { } // No copying! @@ -62,8 +62,8 @@ if (! empty ()) { // No leak on exception! - std::unique_ptr<elem> ptr (lifo.top ()); - lifo.pop (); + std::unique_ptr<elem> ptr (m_lifo.top ()); + m_lifo.pop (); ptr->run (); } } @@ -72,22 +72,22 @@ { if (! empty ()) { - elem *ptr = lifo.top (); - lifo.pop (); + elem *ptr = m_lifo.top (); + m_lifo.pop (); delete ptr; } } - size_t size (void) const { return lifo.size (); } + size_t size (void) const { return m_lifo.size (); } protected: virtual void add_action (elem *new_elem) { - lifo.push (new_elem); + m_lifo.push (new_elem); } - std::stack<elem *> lifo; + std::stack<elem *> m_lifo; }; // Like unwind_protect, but this one will guard against the possibility