Fixed PUSHDATA script parsing

1. iter.by_ref() is needed to advance script iterator: Currently iter.take() makes a copy of the iterator, which causes pushed script items to be interpreted as another ops. Doing .by_ref().take() instead fixes it by using the iterator by reference to advance the position.
2. uints are little endian in scripts, so the bytes need to be summed in reverse order. Also here the iterator needs to be passed by mutable reference to advance the position correctly.