-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[feature] Single Asset Vault #10
base: vault-base
Are you sure you want to change the base?
Conversation
7e5fec5
to
338ab5a
Compare
src/test/jtx/subcases.h
Outdated
|
||
struct Subcase | ||
{ | ||
Context& _; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
please do not use _
as a variable or data member name; C++ is about to get special meaning for it https://wg21.link/P2169
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
... already in C++ draft https://eel.is/c++draft/basic.scope.scope#5
75af896
to
7a2f337
Compare
a6abe03
to
6de56c4
Compare
b28479b
to
97d5023
Compare
@@ -90,6 +92,9 @@ class Asset | |||
void | |||
setJson(Json::Value& jv) const; | |||
|
|||
STAmount |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can this be explicit
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's a function call operator. What is there to make explicit?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Doh. For some reason I thought this to be conversion. NVM :)
@@ -189,6 +189,9 @@ enum LedgerSpecificFlags { | |||
|
|||
// ltCREDENTIAL | |||
lsfAccepted = 0x00010000, | |||
|
|||
// ltVAULT | |||
lsfVaultPrivate = 0x00010000, | |||
}; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess we do not have flag lsfShareNonTransferable
because, for this purpose, we will rely on lsfMPTCanTransfer
instead ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
also need flag lsfFrozen
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Answer to lsfShareNonTransferable
: correct. Please refer to the spec.
Answer to lsfFrozen
: there is no vault freeze, thus no lsfFrozen
.
ReadView const& view, | ||
std::shared_ptr<SLE> const& vault, | ||
STAmount const& shares); | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am confused by the use of STAmount
and Number
in the above three function signatures. I would assume that when we return take/shares, it would be STAmount
(but that's not correct) or when we take/return assets that would be ... Number
?? but that's also not correct.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
When I first wrote these, they returned Number
. They had no callers. Now that I'm calling them, I want STAmount
. I've switched the first one now that it has a caller. I expect to switch the others when I write a call for them.
src/test/jtx/Env.h
Outdated
@@ -785,6 +792,9 @@ Env::rpc(std::string const& cmd, Args&&... args) | |||
std::forward<Args>(args)...); | |||
} | |||
|
|||
extern std::string blob257; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
please add comment what these things are (e.g. hexadecimal blobs equivalent to N many bytes)
6de56c4
to
4abc370
Compare
This PR exists for incremental review. It remade XRPLF#5147. The branch is based on a merge of:
STIssue
wrappingAsset
(Add MPTIssue to STIssue XRPLF/rippled#5200)STNumber
(Add a new serialized type: STNumber XRPLF/rippled#5121)XRPIssue
andIOUIssue
from thebasics
module to theprotocol
module (Enforce levelization in libxrpl with CMake XRPLF/rippled#5111)Below is how to rebase this work when one of the above branches changes. If one of them is merged into
develop
, then generally it is best to wait until Greg mergesdevelop
into hisfeature/mpt-stissue
branch.