packages

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Dec 15, 2023 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Overview

Package packages provides functionality for creating datalog packages.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Package

type Package struct {
	Name  string
	Atoms []ast.Atom
	// contains filtered or unexported fields
}

Package represents a Melange package.

func Extract

func Extract(su parse.SourceUnit) (Package, error)

Extract components from a parse.SourceUnit type.

func (*Package) Clauses

func (p *Package) Clauses() ([]ast.Clause, error)

Clauses returns Clauses of the package with rewritten identifiers.

func (*Package) Decls

func (p *Package) Decls() ([]ast.Decl, error)

Decls returns Decls of the package with rewritten identifiers.

func (*Package) Merge

func (p *Package) Merge(other Package) error

Merge merges two packages.

Jump to

Keyboard shortcuts

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