Re: pointer to a struct
From: Mattias Sjögren (mattias.dont.want.spam_at_mvps.org)
Date: 07/23/04
- Next message: a: "save text file (stream) as html"
- Previous message: C Addison Ritchie: "RE: Why not const ref params in C#?"
- In reply to: -gtu99: "Re: pointer to a struct"
- Next in thread: -gtu99: "Re: pointer to a struct"
- Reply: -gtu99: "Re: pointer to a struct"
- Messages sorted by: [ date ] [ thread ]
Date: Fri, 23 Jul 2004 23:57:58 +0200
Since the array in the ADAPTER_STATUS is so short, one workaround is
to simply split it up in six separate byte members. That should enable
using pointers to it.
Of course this is a bit lame, and in C# v2 the new fixed array feature
provides a better solution for this, letting you write
unsafe struct ADATPER_STATUS {
public fixed byte adapter_address[6];
...
Mattias
-- Mattias Sjögren [MVP] mattias @ mvps.org http://www.msjogren.net/dotnet/ | http://www.dotnetinterop.com Please reply only to the newsgroup.
- Next message: a: "save text file (stream) as html"
- Previous message: C Addison Ritchie: "RE: Why not const ref params in C#?"
- In reply to: -gtu99: "Re: pointer to a struct"
- Next in thread: -gtu99: "Re: pointer to a struct"
- Reply: -gtu99: "Re: pointer to a struct"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|