这在C ++ AType(Ptr)[index]中意味着什么 [英] What does this mean in C++ AType(Ptr)[index]

查看:68
本文介绍了这在C ++ AType(Ptr)[index]中意味着什么的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想知道在C ++之前是否有人知道Pascal,也许你可以帮助我

out。我正在将一些pascal代码转换为C ++,我似乎无法理解AType(Ptr)[索引]试图完成的事情。任何帮助将

表示赞赏。谢谢。


类型

AType =数组[0 .. $ FF]的字节;


var Ptr :指针;


移动(AType(Ptr)[index],dest_word,2);

I wonder if anyone here knew Pascal before C++, perhaps you could help me
out. I''m converting some pascal code into C++, and I can''t seem to
understand what AType(Ptr)[index] is trying to accomplish. Any helps would
be appreciated. Thanks.

type
AType = array[0..$FF] of byte;

var Ptr : Pointer;

Move(AType(Ptr)[index], dest_word, 2);

推荐答案

FF]的字节;


var Ptr:指针;


移动(AType(Ptr)[index],dest_word ,2);

FF] of byte;

var Ptr : Pointer;

Move(AType(Ptr)[index], dest_word, 2);


SGi写道:
我想知道在C ++之前是否有人知道Pascal,也许你可以帮助我
out。我正在将一些pascal代码转换为C ++,我似乎无法理解AType(Ptr)[索引]正试图实现的目标。任何帮助都会受到赞赏。谢谢。

类型
AType =字节的数组[0 ..
I wonder if anyone here knew Pascal before C++, perhaps you could help me
out. I''m converting some pascal code into C++, and I can''t seem to
understand what AType(Ptr)[index] is trying to accomplish. Any helps would
be appreciated. Thanks.

type
AType = array[0..


FF];

var Ptr:Pointer ;移动(AType(Ptr)[index],dest_word,2);
FF] of byte;

var Ptr : Pointer;

Move(AType(Ptr)[index], dest_word, 2);




这是一个Pascal(或者也许是Delphi)的问题应该在

更合适的论坛中询问。请参阅此常见问题解答,了解这里的主题以及

您可以发布的一些可能的论坛:

http://www.parashift.com/c++-faq-lit...t。 html#faq-5.9


干杯! --M



This is a Pascal (or perhaps Delphi) question and should be asked in a
more appropriate forum. See this FAQ for what is on-topic here and for
some possible forums you can post in:

http://www.parashift.com/c++-faq-lit...t.html#faq-5.9

Cheers! --M


这篇关于这在C ++ AType(Ptr)[index]中意味着什么的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆