Skip to content

Ghi v0.2.2

Choose a tag to compare

@arm092 arm092 released this 24 Sep 23:00
· 45 commits to master since this release

Ghi v0.2.2

Language

  • Plain enums declare distinct types, for example enum Direction { North, South } with Direction.North values.
  • Enums with explicit values require a string, int or bool backing type. Their cases are immutable primitive constants and can be passed directly to parameters of that type.
  • Enum case imports, aliases, default arguments, generic comparable constraints and canonical formatting are supported. Plain enum construction/conversion and case mutation are rejected.
  • The English README includes the full enum syntax and rules, with a runnable examples/enums project. Existing match semantics remain unchanged.

Editor integration

ghi check --stdin --filename /absolute/project/main.ghi /absolute/project checks an unsaved editor buffer without changing its existing production source file. Diagnostics refer to the original source path and positions. Other project files and dependencies are loaded normally. This is supported by Ghi for GoLand v0.1.1.

Installation and versions

Download a Windows setup wizard or a portable archive for Windows/macOS, Intel/AMD64 or ARM64. Bundled Mojave remains independently versioned at v0.1.0. Ghi for GoLand v0.1.1 is available in its own GitHub repository.

Native macOS v0.2.2 execution and Homebrew verification are deferred. No v0.2.2 .pkg is published; the previous v0.2.1 .pkg does not include these features. Installers are unsigned. GitHub Actions was not used.

Verification

The full compiler/language/toolchain/CLI suite and go vet passed during implementation after fixing nullable parsing integration. Final enum tests cover original diagnostics, imports, shadowing, primitive calls, JSON, immutability, conversion rejection and formatter idempotence. Existing DDD integration/unit tests and the runnable enum and README examples passed. Release CLI tests passed after the version update. All four portable archives and their embedded executable checksums were verified. The packaged Windows compiler reports v0.2.2, runs the enum example, and returns the original-file diagnostic for an unsaved enum mutation without changing disk. The Windows installer passed install/reinstall, both compiler examples, independent Mojave version, uninstall and exact PATH restoration checks.

Language documentation · GoLand v0.1.1 · Mojave v0.1.0