Bitcoin: call to consteval function ‘util::ConstevalHexDigit’ is not a constant expression

Oshibba in Bitcoin Constavalhexdigit

Bitcoin: call to consteval function 'util::ConstevalHexDigit' is not a constant expression

How to work out with a bitcoin project, you, verbathetically, do not blow up to his philosophy. I faded with a scoop with a conted process of cmake. The problem appears to be attracted to the Bitcoin code, using the Optiya -build with a few sweat.

Problem: Constevalhexdigit Function

The problem is concluded in the function Util :: Contevalhexdigit, which, by vidim, is asked to name the indisputable expression. In C ++ 11 and more late versions for the decayed operats, the functions are “stoled”, which are always supposedly giving the post -gaps.

Variants CMAKE CMAKE

Let’s subtract you into what you go when you run CME -Build Build -j $ (Sysctl -n hw.ncpu). Here’s a broken vowed variants:

  • -build: Specifications of the process of gaming for use.

  • -J $ (Sysctl -n H.NCPU): Includes Compilation Competitions with Substract Peats. The substantial $ is used to replace the dynamic system, which allows us to dynamically establish the amount of nuclear.

Oshybka

When you give up your code, use Cmee -build Build -y $ (Sysctl -n H.Ncpu), the compilator is a pace with the demand to release the non -controlled expression in Util :: Contevalhexdigit. It is connected by the C ++ constituent expression should be covered with the nailing stained (with a pureb) Operators.

solving

To solve this problem, we can use the functions contexpr in our code. These functions can be extended as “storage” that the C ++ standards for the summary of unpopular expressions.

Here’s how you can rewrite your code, use Contexpr:

`CPP

#include

#inClude "Util/Consteval_hex_digit.hpp"

Static ConstExpr Uint256_T Contesavalhexdigit (CONST STD :: String & Input) {

// Realization here remains more ...

}

Constevalhexdigit as “contexpr”, we have made it possible that it coated all the treats of the indispensable expression, the crackdown.

Bitcoin When Does Miner

Leave a Reply

Your email address will not be published. Required fields are marked *