Skip to content
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

core/types: improve LogForStorage and ReceiptForStorage comments #25032

Merged
merged 5 commits into from Jun 8, 2022
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
3 changes: 1 addition & 2 deletions core/types/log.go
Expand Up @@ -98,8 +98,7 @@ func (l *Log) DecodeRLP(s *rlp.Stream) error {
return err
}

// LogForStorage is a wrapper around a Log that flattens and parses the entire content of
// a log including non-consensus fields.
// LogForStorage is a wrapper around a Log that handles backward compatibility with prior storage formats.
type LogForStorage Log

// EncodeRLP implements rlp.Encoder.
Expand Down
4 changes: 2 additions & 2 deletions core/types/receipt.go
Expand Up @@ -267,8 +267,8 @@ func (r *Receipt) Size() common.StorageSize {
return size
}

// ReceiptForStorage is a wrapper around a Receipt that flattens and parses the
// entire content of a receipt, as opposed to only the consensus fields originally.
// ReceiptForStorage is a wrapper around a Receipt with RLP serialization that omits the Bloom
// field and deserialization that re-computes it.
type ReceiptForStorage Receipt

// EncodeRLP implements rlp.Encoder, and flattens all content fields of a receipt
Expand Down