[LLVMdev] struct and class under VC7.1

Paolo Invernizzi arathorn at fastwebnet.it
Thu Sep 23 06:59:42 PDT 2004


Hi all,

Finally I managed to find out a strange problem under Visual C

During the link of the HowToUseJIT program, I was always missing some 
symbols... and I was going crazy testing out different options...

At the end, unmangling the differences in what linker was searching and 
what was present in the libraries, I found that the problem is
that we have something like this...

Value.h
struct Value {
	bla bla bla
}

and around in the other files:
SlotCalculator.h
SchedGraph.h
<big snip>

class Value;

The linker complains about the different parameters types, and raise an 
unresolved external symbol.

I can resolve the iussue
a) turning the original struct Value { ... } in class Value { public: 
.... }
b) turning all the class Value; into struct Value;

The same is for TargetJITInfo, Type, IntrinsicLowering and others...

Suggestions?

---
Paolo Invernizzi




More information about the llvm-dev mailing list