Cppdecl

From Lazarus wiki
Jump to navigationJump to search

Deutsch (de) English (en)

Back to Reserved words.


The cppdecl modifier belongs to the calling conventions for internal and external subroutines.

The cppdecl modifier is used to call a function according to the C++ calling convention.

Example 1:

function subTest : string; [cppdecl];
  begin
    subTest := 'abc';
  end;

Example 2:

  ...
  function funcTest(strTestdaten : Pchar) : LongWord;  cppdecl;  external 'Test.dll';
  ...