delphi int64
来源:互联网 发布:淘宝钻石展位怎么使用 编辑:程序博客网 时间:2024/05/21 22:52
最近,Delphi推出了64位预览版本, 我做为一个忠实的Delphier, 看到这消息后,第一时间学习,并写下这个做为以后的参考资料。
相同点:
在Delphi 64位版本中,UnicodeString,AnsiString,WideString在使用上与32没有区别,只是索引变成了64位,如:S[I]中的I变成了64位。
Singed types
Delphi/32
Delphi/64
ShortInt
1 bytes
←
SmallInt
2 bytes
←
LongInt
4 bytes
←
Integer
4 bytes
←
Int64
8 bytes
←
Unsinged types
Delphi/32
Delphi/64
Byte
1 bytes
←
Word
2 bytes
←
LongWord
4 bytes
←
Cardianl
4 bytes
←
UInt64
8 bytes
←
← 符号表示大小与Delphi/32相同
不同的地方:
NativeInt,NativeUint - 64 bits
Point(all pointers) - 64 bits
Dynamic Arrays - 64-bit indexing
Floating point math – Double
Point
String
Class instance
class reference
Interface
AnsiString
WideString
UnicodeString
Procedure pointer
Dynamic array
PAnsiChar
PWideChar
PChar
上面的类型在32位都是4 bytes,在64位下是8 bytes
总体来说:
- 同样的Windows API,如:CreateWindowEx,PeekMessage,etc
- 同样的Delphi RTL:SysUtils,Classes,Generics.Collections,etc
- VCL也相同:Forms,Graphics,Controls,Menus,etc
- 错误处理上也相同:try…finally…., try….exception…..
在64位下,这些调用约定将被看做一致:register,passcal, cdecl,stdcall
Delphi/64不支持pascal与BASM(ASM)混写了,只支持纯Asm procedure。
调用过程或函数的前面四传参寄存器也发变成了:RCX, RDX, R8, R9(或XMM0-XMM3)
在处理Message消息结构体时,需要进行显示强制转换,例如:
SendMessage(hWnd,WM_SETTEXT,0,LPARAM(@MyCharArray));
Message.Result:=LRESULT(Self);
来源 http://www.cnblogs.com/neugls/archive/2011/04/05/2005736.html
- delphi int64
- int64
- delphi 对int64计算的一种处理方式
- Int64:是Delphi中最大的整数,64位有符号整数
- MAC-》int64
- defining int64
- —int64
- 心得int64
- int64 转 char*
- 转换字符串成INT64
- INT64拆分成DWROD
- Int64格式化字符串
- double to int64 conversion
- vs2012 Long int64
- as3 的 int64数据类型
- byte[] to int64
- int64位整数
- int64输出格式问题
- js获取客户端IP及地理位置
- Codeforces Round #271 (Div. 2)
- python设计模式 之 简单工厂模式
- Android NDK 开发中配置javah 生成 .h 文件
- KMP算法中next和nextval数组的求解
- delphi int64
- iOS: Autolayout和UITableViewCell的动态高度 (2) – 多样式Cell切换
- 互联网大佬们都在焦虑什么?
- phpcms如何生成地图sitemap静态页面
- 工厂模式
- IOS网络篇2之客户端离线缓存策略(NSURLProtocol)
- apache PyString_FromString: Assertion `str != ((void *)0)' failed. 错误处理
- SourceInsight设置
- Struts2.3.16.1+Hibernate4.3.4+Spring4.0.2 框架整合