From 867ef2d0370119db4608b1a8be8884638c95e4c0 Mon Sep 17 00:00:00 2001 From: Koen Zandvliet Date: Sat, 29 Aug 2026 07:38:05 +0200 Subject: [PATCH] Request lalrpop-util's "lexer" feature as a regular dependency core/Cargo.toml requests lalrpop's "lexer" feature only under [build-dependencies] (used to generate the parser from the grammar), but [dependencies]'s lalrpop-util (used by the generated code itself) doesn't request the same feature. Cargo's older resolver unified build- and normal-dependency features, masking this; resolver v2 (the default for any consumer on edition 2021+) correctly keeps them separate, so consumers depending on scallop-core directly fail with: error[E0433]: cannot find `lexer` in `__lalrpop_util` This doesn't surface building scallop-core inside this repo's own workspace, only when embedded as a dependency by a resolver-v2 consumer. Verified: reproduced the failure by depending on scallop-core from a resolver-v2 project, confirmed this one-line fix resolves it, and confirmed reverting it reproduces the exact same 17 errors again. --- core/Cargo.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/Cargo.toml b/core/Cargo.toml index 43b442c4..4d626368 100644 --- a/core/Cargo.toml +++ b/core/Cargo.toml @@ -11,7 +11,7 @@ crate-type = ["rlib"] lalrpop = { version = "0.19.9", features = ["lexer"] } [dependencies] -lalrpop-util = "0.19.9" +lalrpop-util = { version = "0.19.9", features = ["lexer"] } proc-macro2 = { version = "1.0", features = ["span-locations"] } downcast = "0.11" quote = "1.0"