parser

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Jul 15, 2026 License: MIT Imports: 11 Imported by: 0

Documentation

Overview

Package parser builds the IR from Go source via go/packages and go/types. It is transport-neutral: it knows the generic "service" directive and method shape, but nothing about HTTP. Emitters interpret their own directives later.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Load

func Load(dir string, opts Options) (*model.Service, error)

Load parses the package rooted at dir into a transport-neutral Service.

Types

type Options

type Options struct {
	// KnownDirectives are directive names emitters recognize (e.g. "route").
	// Any framework:* directive that is neither "service" nor in this set is a
	// hard error (SPEC.md D15).
	KnownDirectives []string
}

Options carries emitter-contributed knowledge into the transport-neutral parser.

Jump to

Keyboard shortcuts

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