catalog

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: May 31, 2026 License: MIT Imports: 5 Imported by: 0

Documentation

Overview

Package catalog assembles an IR Catalog from parsed DDL statements.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Diagnostic

type Diagnostic struct {
	Severity string // "info" | "warning" | "error"
	Message  string
}

Diagnostic is a single non-fatal issue with severity and message.

type Diagnostics

type Diagnostics struct {
	Items []Diagnostic
}

Diagnostics accumulates non-fatal issues found while building the catalog.

func Build

func Build(stmts []parse.Stmt) (*irv1.Catalog, *Diagnostics)

Build assembles a Catalog from parsed statements (schema DDL + applied migration up statements, in order). It never panics; unknown/odd shapes result in a diagnostic and are skipped.

func (*Diagnostics) Add

func (d *Diagnostics) Add(sev, msg string)

Add appends a diagnostic entry.

Jump to

Keyboard shortcuts

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