:: Re: [Libbitcoin] Any ideas about th…
Αρχική Σελίδα
Delete this message
Reply to this message
Συντάκτης: Police Terror
Ημερομηνία:  
Προς: libbitcoin
Αντικείμενο: Re: [Libbitcoin] Any ideas about this linker error?
Oh you're right. I was looking at hd_public::operator< instead.

I made a bug report for it:

https://github.com/libbitcoin/libbitcoin/issues/440

Can I implement it as per the first answer on this StackOverflow question?

https://stackoverflow.com/questions/3882467/defining-operator-for-a-struct

Eric Voskuil:
> It's not implemented :/
>
> e
>
>> On Aug 18, 2016, at 10:07 AM, Police Terror <PoliceTerror@???> wrote:
>>
>> #include <bitcoin/bitcoin.hpp>
>>
>>  int main()
>>  {
>>      libbitcoin::wallet::hd_lineage a, b;
>>      a < b;
>>      return 0;
>>  }

>>
>> $ g++ main.cpp $(pkg-config --cflags --libs libbitcoin) -std=c++11
>> /tmp/ccd5MFwR.o: In function `main':
>> main.cpp:(.text+0x26): undefined reference to
>> `libbitcoin::wallet::hd_lineage::operator<(libbitcoin::wallet::hd_lineage
>> const&) const'
>> collect2: error: ld returned 1 exit status
>>
>> I looked at the source code and everything seems fine (operator is
>> implemented fine).
>>
>> This is only with the < operator. Both == and != work fine.
>>
>> _______________________________________________
>> Libbitcoin mailing list
>> Libbitcoin@???
>> https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/libbitcoin