msgpack unresolved question

Masahiro Nakagawa repeatedly at gmail.com
Sat Nov 3 19:52:04 PDT 2012


Hi Dan,

Sorry for the delay.
Your mail is referred to as spam in Gmail...

I also got same error in compare_json.d,
and I agree with Jesse.

"pragma(msg, typeof(via.map.length));" returns 'ulong' during 
compilation.
But the linker error occurred in the runtime.

Now, I have no idea to resolve it in library.
Give me some time to think it over.


Thanks,
Masahiro

On Thursday, 25 October 2012 at 18:50:55 UTC, Dan wrote:
> On Thursday, 25 October 2012 at 17:59:40 UTC, Jesse Phillips 
> wrote:
>>
>> It is a linker error. You need to compile the msgpack.d file 
>> and tell the linker where to find it. The simplest way is to 
>> just throw the file on the command line.
>>
>> dmd compare_json.d msgpack.d
>>
>
> Thanks. I tried your suggestion but had no luck (same link 
> error). It could be my command is still wrong. Or maybe it is 
> something related to associative arrays? The reason I suggest 
> this is there is another example in the directory (custom.d) 
> which uses functionality in msgpack and builds and runs fine 
> without my specifying msgpack.d on the command line.
>
> Thanks
> Dan
>
> dmd  /.../msgpack-d/example/compare_json.d  
> /.../msgpack-d/src/msgpack.d
>
> compare_json.o: In function 
> `_D7msgpack5Value83__T9toMsgpackTS7msgpack50__T6PackerTS3std5array16__T8AppenderTAhZ8AppenderZ6PackerZ9toMsgpackMxFNeKS7msgpack50__T6PackerTS3std5array16__T8AppenderTAhZ8AppenderZ6PackerZv':
> /.../msgpack-d/src/msgpack.d:(.text._D7msgpack5Value83__T9toMsgpackTS7msgpack50__T6PackerTS3std5array16__T8AppenderTAhZ8AppenderZ6PackerZ9toMsgpackMxFNeKS7msgpack50__T6PackerTS3std5array16__T8AppenderTAhZ8AppenderZ6PackerZv+0x1aa): 
> undefined reference to 
> `_D6object55__T16AssociativeArrayTS7msgpack5ValueTxS7msgpack5ValueZ16AssociativeArray6lengthMFNdZm'
> collect2: ld returned 1 exit status
> --- errorlevel 1




More information about the Digitalmars-d-learn mailing list