Packages

  • package root
    Definition Classes
    root
  • package swam
    Definition Classes
    root
  • package binary
    Definition Classes
    swam
  • package decompilation
    Definition Classes
    swam
  • package runtime

    This package contains all the classes and types related to running WebAssembly modules.

    This package contains all the classes and types related to running WebAssembly modules.

    The entry point for almost all users will be Engine. A typical use of the engine is:

    import swam._
    import text._
    import runtime._
    import exports._
    
    import cats.implicits._
    import cats.effect._
    
    import java.nio.file.Paths
    
    val tcompiler = Compiler[IO]
    val engine = Engine[IO]
    
    for {
      tcompiler <- tcompiler
      engine <- engine
      mod <- engine.compile(/* source of the module */)
      inst <- mod.newInstance()
      f <- inst.exports.function1[Int, Int]("f")
      res <- f(43)
    } yield res
    
    println(res.unsafeRunSync())
    Definition Classes
    swam
  • package syntax

    Instructions in this package are grouped by category as described in the specification.

    Instructions in this package are grouped by category as described in the specification.

    Definition Classes
    swam
  • package text
    Definition Classes
    swam
  • package traversal
    Definition Classes
    swam
  • package util
    Definition Classes
    swam
  • package pretty

    Implementation of a pretty printer inspired by Wadler's one and adapted to strict language (port of https://github.com/kfl/wpp).

  • Positioner
  • TextFilePosition
  • package validation
    Definition Classes
    swam
p

swam

util

package util

Type Members

  1. trait Positioner[Pos] extends AnyRef

    Used to transform a position into a position type.

    Used to transform a position into a position type. The concrete type of position depends on the meaning of the position index (offset in wast file, in binary stream, ...)

  2. case class TextFilePosition(file: Path, line: Int, column: Int, content: String) extends Product with Serializable

Ungrouped