From: fred Date: Sun, 24 Mar 2002 19:40:32 +0000 (+0000) Subject: lilypond-0.0.62 X-Git-Tag: release/1.5.59~4884 X-Git-Url: https://git.donarmstrong.com/?a=commitdiff_plain;h=98f300fc4ec09394451199e0220dfef7a930c2f5;p=lilypond.git lilypond-0.0.62 --- diff --git a/flower/include/varray.hh b/flower/include/varray.hh index b9b1a24b6b..4f67d3aac4 100644 --- a/flower/include/varray.hh +++ b/flower/include/varray.hh @@ -156,6 +156,14 @@ public: thearray[i] = thearray[i-1]; thearray[j] = k; } + /** + remove i-th element, and return it. + */ + T get(int i) { + T t = elem(i); + del (i); + return t; + } void del(int i) { assert(i >=0&& i < size_); arrcpy(thearray+i, thearray+i+1, size_-i-1);