Einzelnen Beitrag anzeigen

Benutzerbild von KodeZwerg
KodeZwerg

Registriert seit: 1. Feb 2018
3.685 Beiträge
 
Delphi 11 Alexandria
 
#5

AW: c++ header konvertieren extern const struct

  Alt 9. Okt 2018, 18:14
Code:
typedef struct {
   int a;
   int b;
} Clientconfiguration;

const Clientconfiguration DefaultConfiguration = { 55,56 };
Falls gefragt war wie man das nach Delphi bringt, ich würde es so machen:
Delphi-Quellcode:
type
  Clientconfiguration = record
   a, b: Integer;
  end;
const
 DefaultConfiguration: Clientconfiguration = (a: 55; b:56);
Gruß vom KodeZwerg
  Mit Zitat antworten Zitat