Znalazłem przyczynę.
Gdy próbuję zadeklarować funkcję z listą w części "__published" przy kompilacji wywala błąd:
Error in module Unit1: Incorrect method declaration in classTForm1
Jeżeli w części public lub private jest OK.
Listing:
#ifndef Unit1H
#define Unit1H
//---------------------------------------------------------------------------
#include <System.Classes.hpp>
#include <Vcl.Controls.hpp>
#include <Vcl.StdCtrls.hpp>
#include <Vcl.Forms.hpp>
#include <list>
//----------------------------------------------------------------------------------------------------------------------
using namespace std;
class TForm1 : public TForm
{
__published: // IDE-managed Components
TButton *Button1;
TMemo *m1;
void __fastcall ShowList(list <int> pl); // gdy tu deklaruje jest błąd
void __fastcall Button1Click(TObject *Sender);
private: // User declarations
public: // User declarations
__fastcall TForm1(TComponent* Owner);
//void __fastcall ShowList(list <int> pl); // gdy tu deklaruje jest OK
list <int> l;
};
//---------------------------------------------------------------------------
extern PACKAGE TForm1 *Form1;
//---------------------------------------------------------------------------
#endif