antlr4
antlr4 copied to clipboard
Upgrade to go 1.21, replace golang.org/x/exp/slices with slices
Upgrade to go 1.21 to use slices package instead of golang.org/x/exp/slices package.
In the antlr4-go/antlr project, the go version declared in go.mod is already 1.22.
I have already done this. It does not need a pr
On Fri, Oct 11, 2024 at 03:33 Stephen Kitt @.***> wrote:
@.**** approved this pull request.
— Reply to this email directly, view it on GitHub https://github.com/antlr/antlr4/pull/4688#pullrequestreview-2362379885, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAJ7TMDYUOOTDQRP7PF6YPDZ26LM5AVCNFSM6AAAAABNOUCLYGVHI2DSMVQWIX3LMV43YUDVNRWFEZLROVSXG5CSMV3GSZLXHMZDGNRSGM3TSOBYGU . You are receiving this because you are subscribed to this thread.Message ID: @.***>
I have already done this. It does not need a pr
It’s just confusing because it’s done in https://github.com/antlr4-go/antlr but not in https://github.com/antlr/antlr4/tree/dev/runtime/Go/antlr/v4 and the former says it’s a copy of the latter.
Yes, but it referee to the build and release. You only use tagged versions
On Fri, Oct 11, 2024 at 05:49 Stephen Kitt @.***> wrote:
I have already done this. It does not need a pr
It’s just confusing because it’s done in https://github.com/antlr4-go/antlr but not in https://github.com/antlr/antlr4/tree/dev/runtime/Go/antlr/v4 and the former says it’s a copy of the latter.
— Reply to this email directly, view it on GitHub https://github.com/antlr/antlr4/pull/4688#issuecomment-2407245761, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAJ7TMHOCVQPLV6YRUTQH7LZ263LDAVCNFSM6AAAAABNOUCLYGVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDIMBXGI2DKNZWGE . You are receiving this because you commented.Message ID: @.***>
Yes, but it referee to the build and release. You only use tagged versions
OK, sorry for the noise.
I have already done this. It does not need a pr
It’s just confusing because it’s done in https://github.com/antlr4-go/antlr but not in https://github.com/antlr/antlr4/tree/dev/runtime/Go/antlr/v4 and the former says it’s a copy of the latter.
I have previously created a PR in the antlr4-go/antlr project. but as mentioned in the project README.md, Do not submit PRs or any change requests to this repo, I closed that PR.
I have already done this. It does not need a pr
@jimidle But golang.org/x/exp is still in use in the https://github.com/antlr4-go/antlr repository as of today. Did I miss anything?
I am confused, because the latest commit in https://github.com/antlr4-go/antlr is from May 2024 and does not contain this change. @jimidle can you clarify and maybe merge this? Thank you very much for your work!
(Reason is that I really want to drop the x/exp dependency in our project https://github.com/DAMEDIC/fhir-toolbox-go/blob/main/go.mod)
I am also confused. The old exp module is still used both in this repo and in https://github.com/antlr4-go/antlr (even in the dev branch).
@jimidle your changes seem to have been lost, I’m guessing they were deleted when https://github.com/antlr4-go/antlr was updated from this repository — I can’t find your equivalent changes any more. In any case, all the available releases of github.com/antlr4-go/antlr still use the x/exp slices package. Would it be possible to merge this PR to clean up the dependency?
I previously created a fork to address this issue by using the replace directive in go.mod to eliminate the dependency on golang.org/x/exp/slices. Here's a minimal example:
// git clone https://github.com/choral-io/antlr4-go.git ../antlr4-go
module github.com/choral-io/gommerce-server-core
go 1.25.0
replace github.com/antlr4-go/antlr/v4 v4.13.1 => ../antlr4-go
require (
github.com/antlr4-go/antlr/v4 v4.13.1
// other dependencies...
)
This workaround worked well in our project, but I sincerely hope the official repository can resolve this cleanly.
I will update it all shortly. I’ve just been too busy with work and moving
On Thu, Sep 18, 2025 at 08:35 Galen Suen @.***> wrote:
Tiscs left a comment (antlr/antlr4#4688) https://github.com/antlr/antlr4/pull/4688#issuecomment-3307820324
I previously created a fork https://github.com/choral-io/antlr4-go to address this issue by using the replace directive in go.mod to eliminate the dependency on golang.org/x/exp/slices. Here's a minimal example:
// git clone https://github.com/choral-io/antlr4-go.git ../antlr4-go module github.com/choral-io/gommerce-server-core go 1.25.0 replace github.com/antlr4-go/antlr/v4 v4.13.1 => ../antlr4-go require ( github.com/antlr4-go/antlr/v4 v4.13.1 // other dependencies... )
This workaround worked well in our project, but I sincerely hope the official repository can resolve this cleanly.
— Reply to this email directly, view it on GitHub https://github.com/antlr/antlr4/pull/4688#issuecomment-3307820324, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAJ7TMF5OC2NOBBHIJTGMGL3TK7JTAVCNFSM6AAAAABNOUCLYGVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZTGMBXHAZDAMZSGQ . You are receiving this because you were mentioned.Message ID: @.***>