cleanup: drop resolved-issue citations from src comments
Sweep all src/**.zig comments that cite resolved issues (issue NNNN / fix-NNNN / KB-N): the invariant or mechanism each comment states is kept; the historical citation is dropped, per the no-conclusion-comments rule. Pure-history parentheticals are removed outright. References to the 16 still-open issues (0030, 0041-0056) are untouched, as are test NAMES carrying regression provenance (matching the sanctioned "Regression (issue NNNN)" example-header convention). Also removes the issues/0019-import-non-transitive-c-scope/ fixture dir — the issue is superseded and its behavior is covered by examples/0706-modules-import-non-transitive.sx (the .md writeup stays). issues/0030's repro .sx stays: that issue is an open feature request. Gate: zig build OK; zig build test 426/426; run_examples 541/0; zero expected/ snapshot churn.
This commit is contained in:
@@ -45,7 +45,7 @@ pub fn constArrayLiteral(self: *Lowering, elements: []const *const Node, array_t
|
||||
/// Try to convert a single AST expression into a compile-time ConstantValue.
|
||||
/// `expected_ty` is the destination element/field type — it lets aggregate
|
||||
/// leaves (struct literals, nested arrays) serialize with the correct shape
|
||||
/// rather than collapsing to null (issue 0080). Returns null if the
|
||||
/// rather than collapsing to null. Returns null if the
|
||||
/// expression is not constant-foldable here.
|
||||
pub fn constExprValue(self: *Lowering, expr: *const Node, expected_ty: TypeId) ?inst_mod.ConstantValue {
|
||||
return switch (expr.data) {
|
||||
@@ -66,7 +66,7 @@ pub fn constExprValue(self: *Lowering, expr: *const Node, expected_ty: TypeId) ?
|
||||
.undef_literal => .zeroinit,
|
||||
// A `null` in a pointer (or optional-pointer) field is a
|
||||
// compile-time constant: the zero pointer. Without this arm the
|
||||
// aggregate is wrongly rejected as non-constant (issue 0081).
|
||||
// aggregate is wrongly rejected as non-constant.
|
||||
.null_literal => .null_val,
|
||||
.unary_op => |uo| switch (uo.op) {
|
||||
.negate => switch (uo.operand.data) {
|
||||
@@ -80,7 +80,7 @@ pub fn constExprValue(self: *Lowering, expr: *const Node, expected_ty: TypeId) ?
|
||||
.struct_literal => |sl| self.constStructLiteral(&sl, expected_ty),
|
||||
// An enum tag as an aggregate leaf (`[2]Color = .[.green, .blue]`, or
|
||||
// an enum field inside a global struct) serializes to its tag int
|
||||
// against the leaf's declared enum type (issue 0082).
|
||||
// against the leaf's declared enum type.
|
||||
.enum_literal => |el| self.constEnumLiteral(&el, expected_ty, expr.span),
|
||||
else => null,
|
||||
};
|
||||
@@ -92,7 +92,7 @@ pub fn constExprValue(self: *Lowering, expr: *const Node, expected_ty: TypeId) ?
|
||||
/// (`enum { a; b :: 5; }`); the enum's backing width is applied by the
|
||||
/// const emitters via the destination type's LLVM type. Plain enums only —
|
||||
/// a tagged-union or non-enum destination is diagnosed loudly rather than
|
||||
/// silently zero-initialized (issue 0082).
|
||||
/// silently zero-initialized.
|
||||
pub fn constEnumLiteral(self: *Lowering, el: *const ast.EnumLiteral, ty: TypeId, span: ast.Span) ?inst_mod.ConstantValue {
|
||||
if (!ty.isBuiltin()) {
|
||||
const info = self.module.types.get(ty);
|
||||
@@ -543,7 +543,7 @@ pub fn lowerComptimeCall(self: *Lowering, fd: *const ast.FnDecl, call_node: *con
|
||||
// its return type + anything it `#insert`s, e.g. `build_format` / `out`
|
||||
// / `emit` inside `std.print` / `log.*`), so those bare names resolve
|
||||
// in the defining module's visibility context rather than the call
|
||||
// site's (issue 0106). The call-site ARGS above are deliberately lowered
|
||||
// site's. The call-site ARGS above are deliberately lowered
|
||||
// BEFORE this, in the caller's context. Mirrors `lowerFunctionBodyInto`,
|
||||
// which switches to `func.source_file`. The defining path is stamped on
|
||||
// the body node by `resolveImports`; a sourceless body keeps the
|
||||
@@ -848,7 +848,7 @@ const ConstAuthor = union(enum) {
|
||||
///
|
||||
/// - **own-wins**: the querying module's OWN const author is selected outright.
|
||||
/// - else the FLAT-import-reachable const authors: exactly one → it; ≥2 distinct
|
||||
/// → `.ambiguous` (issue 0105 / 0760 — never a silent first-/last-wins pick).
|
||||
/// → `.ambiguous` (never a silent first-/last-wins pick).
|
||||
/// - none visible → `.none` (a namespaced-only const must be qualified `ns.X`;
|
||||
/// a non-const name folds to `.none` too).
|
||||
///
|
||||
|
||||
Reference in New Issue
Block a user