Version française
Home     About     Download     Resources     Contact us    

This site is updated infrequently. For up-to-date information, please visit the new OCaml website at

Browse thread
[Caml-list] CamlIdl possible issue
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: 2004-08-16 (19:46)
From: Shishir Ramam <sramam@g...>
Subject: [Caml-list] CamlIdl possible issue
I am trying to use CamlIdl (Ocaml 3.07+2 win32) and have this case in which 
I understand what is happening, not sure why it  has been implemented thus. 

For the following structure, when SOME_VAR is *not* defined, 
struct my_test {
	int x;
#ifdef SOME_VAR
	int y;

CamlIdl converts this to 
let my_test = int

This is because a structure with one element is getting special attention in 

Knowing very little about the MIDL specification, I attempted to run this 
against a MIDL compiler for the following result -
struct  my_test
    int x;

It seems that the special casing of the single element is not the best of
things for my application, since any reference to the element x will have to be
modified in the Ocaml program depending on whether SOME_VAR is defined or not. 

IMHO this seems like a bug. Was wondering if there is some other explanation 
for this.

Thanks in advance for any help.

To unsubscribe, mail Archives:
Bug reports: FAQ:
Beginner's list: