Lastly, if I recompile using Borland compiler:
C:\tmp\bugtest>bcc -c bug.cpp
Borland C++ 5.0 Copyright (c) 1987, 1996 Borland International
bug.cpp:
Error bug.cpp 11: Undefined symbol 'm_cC' in function somepublicfunction()
Warning bug.cpp 13: Function should return a value in function somepublicfunction()
*** 1 errors in Compile ***
Borland did pick up the error!  So this is not only the assembly syntax compatibilities.
 
Walter <walter@digitalmars.com> wrote in message news:aisitv$29es$1@digitaldaemon.com...
Lookup rules in inline asm are a little different. All struct members are included in the search, regardless of protection attributes, scoping, etc. This sounds a little wierd, but is intentional. It's fallout from trying to emulate MASM syntax, and MASM has little concept of structs, scoping, etc. Secondly, all struct members resolve to simply an integer representing the offset of that member from the start of the struct. This is so that it can be used as an offset to whatever 'this' value is in the index register:
 
    mov EAX, foo[ECX]
 
I hope this clears up the confusion.
 
-Walter