apache / apache/datafusion-sqlparser-rs
Support `proc-macro` TokenStream
- 主要语言
- Rust
- 星标
- 3.5k
- 派生
- 772
- 平均合并
- 4 天 9 小时
- 30 天内合并 PR
- 17
描述
I'm currently writing a proc macro that uses SQL to generate code that works with the storage pattern in [`specs`](https://github.com/slide-rs/specs). As is, I have to call `display` on the `TokenStream`, which converts it to a raw string. This will mean I'm undoing the tokenization for this parser to re-tokenize, while it should be possible for this parser to use the `TokenStream` directly.
This is low priority for me, as this issue only causes excess compilation time, but after creating this proc macro, I can add it to my own to-do.
贡献指南
这个仓库没有索引到贡献指南
调研方向
该 issue 提到了一个 proc-macro TokenStream 以及 parser 当前的 display-to-raw-string 路径,但没有提供任何 repository 文件或测试。首先定位此输入转换,并确定如何通过直接支持 TokenStream 来保留 tokenization;当能够在不经过 display 和重新 tokenization 步骤的情况下解析 proc-macro TokenStream 时,即表示完成。
由索引模型根据 Issue 内容生成。
评估
- 技术栈
- rust, sql
- 领域
- compilers
- Issue 类型
- 功能
- 难度
- 4/5
- 预计耗时
- 3-5 天
- 活跃度
- 停滞
- 描述清晰度
- 基本清楚
- 新手友好度
- 35/100