this is not doing exactly what Suraj asked for, as it modifies the
order of elements in the repeated field.
assuming order of the elements does matter, you have two options:
1. use the SwapElements() idiom in a loop until the element to be
removed is the last one and than call RemoveLast().
2. get the direct buffer using the mutable_data() method, use
memmove() or something similar, to pull the following elements into
place, place the element to be removed at the end and then call
RemoveLast()
unless you're dealing with extremely large arrays, method #1 should
suffice.
eyal.