Skip to content

在不生成proto的代码的前提下,实现IDE 内的代码提示、属性跳转 #217

Open

Description

@tangb4c

问题背景

在业务场景中,使用protobuf的地方很多,而且部分业务的protobuf也是越来越大,导致生成的代码(pb文件)也很大,(单个pb 10M 以上,代码行数 26万行)。
从而导致 IDE 在解析protobuf生成的代码时,消耗很多资源,大一点 的工程,差不多要 2 分钟,对内存的占用也很高(整个工程 10G 以上),在编码时,代码提示也会显得卡顿。

image image

解决思路

由于这些代码是自动生成的,是否可以在不生成这些代码的情况下,实现代码提示,以及跳转?

目前,在没有.pb.cc, .pb.h等文件的情况下,没有代码提示,跳转。

我这里是使用的 CLion

image

Activity

  1. devkanro commented on Dec 18, 2023

    @devkanro
    Owner

    理论上可行,但是工作量可能有点大,对于不同的语言还需要做不同的工作...
    有闲空的话可以试试...

  2. added
    enhancementNew feature or request
    PR welcomeWelcome to create a pull request for this feature/bug
    on Dec 18, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    PR welcomeWelcome to create a pull request for this feature/bugenhancementNew feature or request

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions