<buffer[0..5]为integer;
<buffer[6..10]为char;
6个字节怎么能为integer呢?如果是4字节或许可以用记录类型:
type
TMyBuffer = record
int1, int2: smallint;
chars: array[0..5] of char;
end;
或者
TMyBuffer = record
intbuf: longint;
chars: array[0..5] of char;
end;
var buffer: TMyBuffer;