View Single Post
  #3 (permalink)  
Old May 30th, 2006, 05:34 AM
gmoudry gmoudry is offline
Registered User
Join Date: May 2006
Location: , , .
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts

langway suggested to map WMTInt8 to a byte,
however, I would advise against it.
Consider this code:
  typedef char WMTInt8;
  WMTInt8 myChar = 'a';

If you translate this as
  byte myChar = 'a';
It will not compile until you insert cast statements.
(error CS0029: Cannot implicitly convert type 'char' to 'byte').
IMHO, It's better to bite the bullet, forget about type safety of 'struct WMTInt8' and translate a WMIInt8 as a C# 'char'.

george : C++ to C# conversion (and translation to VB.NET)