Skip to content

Conversation

@jtimon
Copy link
Contributor

@jtimon jtimon commented Aug 13, 2014

As a minimum I would do this before doing #4692
Although I don't mind to rebase things like this and merge them later.

@sipa
Copy link
Member

sipa commented Aug 13, 2014

NAK. IMHO CTxDestination belongs in script, as it encodes a particular subset of scripts. key.h is a wrapper for ECDSA logic, and works at a lower level.

@laanwj
Copy link
Member

laanwj commented Aug 14, 2014

Agree with @sipa here.

key.h isn't concerned with sending and destinations. There is no functionality using destinations at all in there. It's very low-level.

In script.h however, there are various utility functions that take a destination. Apart from the wallet it has the most methods involving these:

void CScript::SetDestination(const CTxDestination& address);
isminetype IsMine(const CKeyStore& keystore, const CTxDestination& dest);
bool ExtractDestination(const CScript& scriptPubKey, CTxDestination& addressRet);
bool ExtractDestinations(const CScript& scriptPubKey, txnouttype& typeRet, std::vector<CTxDestination>& addressRet, int& nRequiredRet);

Unless these utilities are somehow split off from the 'core' script interpreter, it makes no sense to move CTxDestination.

@laanwj laanwj closed this Aug 14, 2014
@jtimon jtimon deleted the destination branch August 14, 2014 13:35
@bitcoin bitcoin locked as resolved and limited conversation to collaborators Sep 8, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants