corpusfixture

package
v1.3.2 Latest Latest
Warning

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

Go to latest
Published: Sep 13, 2026 License: MIT Imports: 1 Imported by: 0

Documentation

Overview

Copyright (c) 2026 Tarek Wasfy Package corpusfixture decodes Tree-sitter corpus fixture containers. It deliberately knows nothing about any source language; it only separates the executable source field from a following expected S-expression.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func SplitTreeSitterFixture

func SplitTreeSitterFixture(source, expected string) (string, string)

SplitTreeSitterFixture returns executable source and its expected tree. Some corpus exporters store both fields in source_text. A separator is a line of three or more hyphens whose next nonblank line begins an S-expression. That final condition prevents ordinary minus operators and hyphen comments from being treated as a fixture boundary. An explicit expected tree wins, while an embedded tree is always removed from source to prevent leakage.

Types

This section is empty.

Jump to

Keyboard shortcuts

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