
- #Borland delphi for windows 10 manual#
- #Borland delphi for windows 10 code#
- #Borland delphi for windows 10 windows#
The current compiler implementation eliminates the need for using packed records this way, in most cases. Unused data fields were introduced to "pad things out" and make the needed data fields line up as needed.
#Borland delphi for windows 10 windows#
In previous versions of Delphi, packed records were used to ensure proper data alignment when calling external libraries and notably certain external Windows API functions that require record or struct parameters. Msg: UINT wParam: WPARAM lParam: LPARAM Result: LRESULT) All TWM.-records for the windows message handlers must use the correct Windows types for the fields:.Wrong: Message.Result := Integer(Self).Correct: Message.Result := LRESULT(Self).Correct: SetWindowLongPtr(hWnd, GWLP_WNDPROC, Wrong: SetWindowLong(hWnd, GWL_WNDPROC, Pointers that are assigned to the TMessage.Result field should use a type-cast to LRESULT instead of Integer/Longint.

Pointers that are passed to SetWindowLongPtr should be type-casted to LONG_PTR and not to Integer/Longint.
#Borland delphi for windows 10 code#
See Using Conditional Defines for Cross-Platform Code in "Using Inline Assembly Code." If you want to compile the same code for different architectures, use conditional defines.
#Borland delphi for windows 10 manual#
You may also want to consult the processor manual for new instructions. Consider the architecture specifics, such as the size of pointers and aligning.

If your application contains inline assembly (ASM) code, you need to examine the ASM code and make the following changes:

On the 32-bit Windows platform, a pointer is 4 bytes.The size of all pointers has changed, as follows:.You should review pointer operations in your code base.
