Skip to content

Commit

Permalink
Update type of Module.from_file
Browse files Browse the repository at this point in the history
  • Loading branch information
hoodmane committed Sep 8, 2023
1 parent f41d2ee commit f67619e
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion wasmtime/_module.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,12 @@
import ctypes
from wasmtime import Engine, wat2wasm, ImportType, ExportType, WasmtimeError
import typing
from os import PathLike


class Module:
@classmethod
def from_file(cls, engine: Engine, path: str) -> "Module":
def from_file(cls, engine: Engine, path: str | bytes | PathLike) -> "Module":
"""
Compiles and creates a new `Module` by reading the file at `path` and
then delegating to the `Module` constructor.
Expand Down

0 comments on commit f67619e

Please sign in to comment.