Displaying 3 results from an estimated 3 matches for "str_format".
Did you mean:
set_format
2003 Nov 21
2
[LLVMdev] GetElementPtrInst Again!
...When I set up the call, I get the following from that pesky :) verifier:
Call parameter type does not match function signature!
getelementptr [3 x sbyte]* %_str_format_, long 0 ; <[3 x sbyte]*>:0 [#uses=1]
typesbyte* sbyte *
So, in LLVM are arrays and pointers not equivalent as in "C"?
What do I have to do to turn my little str_format array into a pointer?
I tried the FunctionType with an argument of [3 x sbyte] but that led to
m...
2003 Nov 21
0
[LLVMdev] GetElementPtrInst Again!
...taking a pointer to SByteTy with var
> args and returning SIntTy:
Sounds good.
> When I set up the call, I get the following from that pesky :) verifier:
Ah, but it's so helpful! :)
> Call parameter type does not match function signature!
> getelementptr [3 x sbyte]* %_str_format_, long 0 ; <[3 x sbyte]*>:0 [#uses=1]
> typesbyte* sbyte *
>
> So, in LLVM are arrays and pointers not equivalent as in "C"?
Absolutely not.
> What do I have to do to turn my little str_format array into a pointer?
Try making a: getelementptr [3 x sbyte...
2003 Nov 21
1
[LLVMdev] GetElementPtrInst Again!
...it's so helpful! :)
It is actually. It is ensuring that my compiler is correct which is one
of the hardest things to do!
> > So, in LLVM are arrays and pointers not equivalent as in "C"?
>
> Absolutely not.
Aha!
>
> > What do I have to do to turn my little str_format array into a pointer?
>
> Try making a: getelementptr [3 x sbyte]* %_str_format_, long 0, long 0
>
> This means:
> [3 x sbyte]* %_str_format_, ; Start from _str_format_
> long 0, ; Get the first [3 x sbyte] array pointed to
> long 0...