Skip to content

Better types for opcodes #1966

Closed
Closed
@vostrnad

Description

@vostrnad

ops.ts exports the list of opcodes as:

const OPS: { [key: string]: number }

That's not a very safe type, as it permits access with any string key. It also doesn't work with code completion.

Can this type be made more specific? It would technically be a breaking change for anyone using this in an unsafe manner, but I believe it's worth it. I'm happy to work on this.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions