Code Monkey home page Code Monkey logo

Comments (5)

jonasnick avatar jonasnick commented on August 11, 2024 2

Adding to the current situation is that VERIFY_CHECK is not side-effect safe when built with --enable-coverage which lead to bugs in coverage mode in the past. In fact, there are again unused variable warnings right now when compiling master with --enable-coverage. So an additional advantage of your suggestion is that VERIFY_CHECK in coverage mode isn't special anymore which would hopefully reduce maintenance of that mode.

from secp256k1.

sipa avatar sipa commented on August 11, 2024 1

Agree, I think we should make VERIFY_CHECK compile to nothing in non-VERIFY mode. It was worthwhile to aim for side-effect freeness, but the way to codebase has evolved I believe makes the benefit not worth the cost. As pointed out in #904, the benefit is effectively restricted already to the simplest cases, where arguably it doesn't matter much anyway.

I wouldn't actually rename the verify_ functions to be upper case, but instead leave them as lowercase functions, but with an uppercase macro around them (maybe one that also compiles to nothing in non-VERIFY mode, so that not even a dummy verify_ function is needed in that case). This is just for style reasons - I think it's good that a reader can guess what is a function and what is a macro just on the name.

from secp256k1.

real-or-random avatar real-or-random commented on August 11, 2024 1

I wouldn't actually rename the verify_ functions to be upper case, but instead leave them as lowercase functions, but with an uppercase macro around them [...]

Sounds good to me.

@theStack Are you interested to look into this by any chance?

from secp256k1.

theStack avatar theStack commented on August 11, 2024 1

I wouldn't actually rename the verify_ functions to be upper case, but instead leave them as lowercase functions, but with an uppercase macro around them [...]

Sounds good to me.

@theStack Are you interested to look into this by any chance?

Yes, planning to tackle this within the next days.

from secp256k1.

real-or-random avatar real-or-random commented on August 11, 2024

This is done, except for the potential renaming to "assert", which is now tracked in #1449.

from secp256k1.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.