nervosnetwork / molecule

Another serialization system: minimalist and canonicalization.
MIT License
36 stars 23 forks source link

C code can not compile in g++ #29

Closed TheWaWaR closed 4 years ago

TheWaWaR commented 4 years ago

A quick fix: https://github.com/TheWaWaR/ckb-c-stdlib/commit/007ad9dc7262db9f94dbfb1ee856ebc820f06faf

This logic should be fixed in code generator.

yangby-cryptape commented 4 years ago

There are two problems:

  1. All include should be put before call those two macros to avoid nested. I use a old c++ template but forgot it since I have written a long time. But I accept your solution (@TheWaWaR) since it's right, too.
  2. It's a warning, and I update the implementation to make g++ be happy.

I have finished the fix but waiting for merging #30.