Autor Beitrag
opfer.der.genauigkeit
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 754
Erhaltene Danke: 1



BeitragVerfasst: Do 31.01.08 13:54 
Hi,

ich habe es noch nie in Delphi gesehen und glaube auch nicht daran, dass es eine solche Syntax gibt.
In C gibt es die Moeglichkeit Bit Fields in structs zu setzen.
Kleines Beispiel:

ausblenden C#-Quelltext
1:
2:
3:
4:
5:
6:
7:
8:
struct packed_struct {
     unsigned int f1:1;
     unsigned int f2:1;
     unsigned int f3:1;
     unsigned int f4:1;
     unsigned int type:4;
     unsigned int funny_int:9;
} pack;


Meine Frage also:
Gibt es das in Delphi auch? :D

_________________
Stellen Sie sich bitte Zirkusmusik vor.
BenBE
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 8721
Erhaltene Danke: 191

Win95, Win98SE, Win2K, WinXP
D1S, D3S, D4S, D5E, D6E, D7E, D9PE, D10E, D12P, DXEP, L0.9\FPC2.0
BeitragVerfasst: Do 31.01.08 15:30 
Nein, musst Du über Bitmasken ralisieren.

_________________
Anyone who is capable of being elected president should on no account be allowed to do the job.
Ich code EdgeMonkey - In dubio pro Setting.
opfer.der.genauigkeit Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 754
Erhaltene Danke: 1



BeitragVerfasst: Do 31.01.08 16:59 
Wie erwartet. Trotzdem danke.

_________________
Stellen Sie sich bitte Zirkusmusik vor.