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

Implement Mock Runtime Syscalls #542

Merged
merged 4 commits into from
Jul 15, 2020
Merged

Conversation

RajarupanSampanthan
Copy link
Contributor

Summary of changes
Changes introduced in this pull request:

  • Implementing the five syscalls for MockRunTime
  • Added More ExpectVerify.* structs
  • Added PartialEq trait for PieceInfo
  • Added Clone Trait for ConsensusFault

Reference issue to close (if applicable)

Closes #482

Other information and links

#[derive(Clone)]
pub struct ExpectComputeUnsealedSectorCid<'a> {
reg: RegisteredSealProof,
pieces: &'a Vec<PieceInfo>,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you should never need to have a reference to a vec instead of using a slice, is there a reason this is taking a reference to this where other types take owned values?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No lol I was trying to match the argument in the function that used pieces. Completely forgot slices were a thing
◴_◶

@RajarupanSampanthan RajarupanSampanthan merged commit b635c08 into main Jul 15, 2020
@RajarupanSampanthan RajarupanSampanthan deleted the rupan/mockruntime_syscalls branch July 15, 2020 05:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Implement MockRuntime syscalls
3 participants