Копирование памяти со смещением в Delphi

Я хочу скопировать блок памяти со смещением, это возможно?

Вот код, который у меня есть на данный момент:

const
  SOURCE: array [0..5] of Byte = ($47, $49, $46, $38, $39, $61);
var
  Destination: Pointer;
begin
  // This is a full copy
  Move(SOURCE, Destination^, SizeOf(SOURCE));

  // If i want to copy from the third byte, is it possible?
  // I imagine the code should be, but it cannot be compiled.
  Move(Slice(SOURCE^, {Offset=}2)^, Destination^, SizeOf(SOURCE) - 2);
end;
6
задан nguthrie 3 March 2014 в 18:50
поделиться