transpiler

package module
v0.0.0-...-7fbf898 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 15, 2022 License: Apache-2.0 Imports: 17 Imported by: 1

Documentation

Overview

Package transpiler contains an implementation of a Whistle Tree Visitor that produces a Whistler Program.

Index

Constants

View Source
const (
	// SourcePosStart is the metadata key for start position in Whistle source.
	SourcePosStart = "Source Position Start"

	// SourcePosStop is the metadata key for stop position in Whistle source.
	// The Column is exclusive, i.e., the last character is the one before.
	SourcePosStop = "Source Position Stop"
)

Variables

View Source
var IncludeSourcePositions option = func(t *transpiler) {
	t.includeSourcePositions = true
}

IncludeSourcePositions is a transpiler option to add Whistle source position metadata to the Whistler proto during transpilation.

Functions

func Transpile

func Transpile(whistle string, opts ...option) (mp *mpb.MappingConfig, err error)

Transpile converts the given Whistle into a Whistler mapping config.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL