You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

Proleap COBOL Parser与antlr4-runtime 13兼容版本及依赖问题咨询

Proleap Cobol Parser与antlr4-runtime兼容版本解决方案

问题根源

Proleap Cobol Parser的每个版本都绑定了特定版本的antlr4-runtime:

  • 自动引入的antlr4-runtime 13与Proleap Cobol Parser 4.7.2编译时依赖的ATN序列化版本不匹配,触发java.io.InvalidClassException
  • 强制降级到antlr4-runtime 4.7.2会因版本差异出现方法不可访问的兼容性问题

正确兼容版本组合

Proleap Cobol Parser 4.7.2 对应的官方兼容antlr4-runtime版本为4.9.3

修正后的依赖管理配置

替换原配置为:

<dependencyManagement>
    <dependencies>
        <dependency>
            <groupId>org.antlr</groupId>
            <artifactId>antlr4-runtime</artifactId>
            <version>4.9.3</version>
            <scope>runtime</scope>
        </dependency>
    </dependencies>
</dependencyManagement>

验证依据

Proleap Cobol Parser 4.7.2的官方构建配置中明确依赖antlr4-runtime 4.9.3,使用该版本可同时解决ATN反序列化错误和方法兼容性问题。

内容的提问来源于stack exchange,提问作者Ashish Gupta

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.06.14 16:08:10