Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Introduced in originally in this PR polkadot-js/api#5699 (review) , it was suggested to be moved to the
@polkadot/common
package.I've basically just copied over the code form the pr in the api package. The
isWasm
andisRiscV
function signature differs as theisWasm
's parameter of bytes is optional. Should we align both functions to have a optional or required parameter?https://github.com/peetzweg/common/blob/d8a4d018f18fe69f2ad796d986ff950335cb2b35/packages/util/src/is/riscv.ts#L15-L17
https://github.com/peetzweg/common/blob/d8a4d018f18fe69f2ad796d986ff950335cb2b35/packages/util/src/is/wasm.ts#L15-L17