Skip to content
This repository has been archived by the owner on Feb 26, 2024. It is now read-only.

Add type guards for all Format.Values.Result types #5945

Closed
wants to merge 1 commit into from

Conversation

gnidan
Copy link
Contributor

@gnidan gnidan commented Mar 2, 2023

PR description

This adds isResult, isValue, and isErrorResult type guards (i.e., e.g., isUintResult, etc.) to all top-level Result types in @truffle/codec. This is taken and modified from https://github.com/cliffoo/codec-explore, where @cliffoo needed this functionality and implemented it there.

Testing instructions

Documentation

  • I thought about documentation and added the doc-change-required label to this PR if documentation updates are required.

Breaking changes and new features

  • I have added any needed breaking-change and new-feature labels for the appropriate packages.

Co-authored-by: Cliff Zhang <41348973+cliffoo@users.noreply.github.com>
@gnidan gnidan added the codec label Mar 2, 2023
@gnidan
Copy link
Contributor Author

gnidan commented Apr 4, 2023

Closing this for now

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant