Skip to content

v0.2.1

Choose a tag to compare

@EdwardJoke EdwardJoke released this 01 Jun 09:46
· 15 commits to master since this release

Changelog

All notable changes to this project will be documented in this file.

The format is based on Keep a Changelog,
and this project adheres to Semantic Versioning.

[v0.2.1] - 2026-06-01

Added

  • lint subcommand replacing --check flag — m4 lint <file.m4> parses and type-checks without execution (M1)
  • m4 <command> help [--zon|--json|--yaml] pattern for command-specific help on all subcommands (lint, build, explain, version)

Changed

  • O(1) variable resolution in compiler via Locals wrapper (ArrayList + StringHashMap), replacing O(n) linear scans in ident and assign-target lookups
  • QBE emitter fmt() now writes directly to output buffer instead of allocating and freeing an intermediate string per line
  • QBE string collection uses getOrPut() single hash lookup instead of contains() + put() double lookup

Fixed

  • m4 build --target cross-compilation now correctly passes target architecture to assembler (-arch) and compiler/linker (-target triple). arm64_apple ↔ amd64_apple cross-compilation verified.
  • Native compilation on non-macOS platforms restored — assembler step falls back to plain as without -arch for native non-Apple targets
  • buildSubcommandHelpInfo returns empty subcommands list for unrecognized names instead of silently returning full help

Removed

  • --check global flag — replaced by lint subcommand

Generated by Relote

Full Changelog: v0.1.2...v0.2.1