Mentions légales du service

Skip to content

Native function for fast array Deque

This PR defines native functions for fast deque operations on Aseba arrays, as discussed in #583 (closed). It contains two parts:

  1. Unit tests for the deque operations, defined in a behavior drive development style. The tests are performed by checking the VM memory after each step, using asebatest as the test runner.
  2. An implementation of the basic operations deque.get, deque.set, deque.insert, and deque.erase.

This initial implementation is correct (according to the tests), but not optimized, neither for speed nor for code size. It does not include the convenience functions deque.push_front, deque.push_back, deque.pop_front nor deque.pop_back.

The tests are defined in the tests/vm directory introduced by PR 584 and this PR is meant to be merged after that one.

Merge request reports