MIDL changes the case of identifier in generated type library (220137)
The information in this article applies to:
- Microsoft Platform Software Development Kit (SDK) 1.0, when used with:
- Microsoft Windows NT Server 4.0
- Microsoft Windows NT Workstation 4.0
This article was previously published under Q220137 SYMPTOMS
When there are two identifiers that differ only by case, the case of the second identifier is changed to reflect the case of the first.
CAUSE
The IDL and Type library are not case sensitive by design. The Ole Automation code that is called by MIDL to generate the type library is taking the first occurrence of a name and any subsequent occurrences of the same name in the IDL, even if it is in different context, to be the same.
RESOLUTION
The following are workarounds you can use to avoid this problem:
- In the case of importing one IDL file to another, the possibility of this happening is higher. Instead of importing IDL files into another IDL, import a corresponding type library.
- Make sure that the same name is not already present in the IDL file when introducing a new identifier.
- Map the identifier generated in the type library with the Components documentation. This is really not too difficult since any identifiers that differ only by case will be in a different context that is, one a method and another a parameter, structure and so forth. This will help to avoid discrepancy in component documentation.
STATUS
This behavior is by design.
Modification Type: | Major | Last Reviewed: | 9/29/2006 |
---|
Keywords: | kbbug kbpending KB220137 |
---|
|