"if" in comment can mess up indentaction
まだ誰も着手していません。
評価
調査の方向性
Start with the referenced logic in indent/rust.vim at lines 148–149 and check how it handles the example comment before a struct block. Reproduce the indentation issue with the supplied steps, then confirm that the closing brace is no longer indented by the comment. No test file is mentioned in the issue.
索引モデルが issue の本文から書いたものです。
説明
- rust.vim version: 4aa69b84c8a58fcec6b6dad6fe244b916b1cf830
Steps to reproduce:
- Edit a file with "If" inside a comment, on an indented line (I believe "fn" will also trigger the issue)
- Begin and end any block
Expected behavior: The comment shouldn't affect indenting
Actual behavior: The } char will be indented to match the indent of the comment line. Note the leading space in the example below:
/**
* Something is wrong if rust.vim adds indent to the last line
*/
struct Foo {
}
I believe this is due to this line, which doesn't take into account if a line is a comment or not: https://github.com/rust-lang/rust.vim/blob/master/indent/rust.vim#L148-L149
- 主要言語
- Vim Script
- スター
- 4.2k
- フォーク
- 323
- PR マージ指標
- 30日以内にマージされた PR はありません
環境構築
このプロジェクトには開発コンテナ、Dockerfile、コントリビューションガイドがありません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
rust-lang/rust.vim のほかの issue
-
難易度 1/5 1〜3時間 初心者へのやさしさ 76/100
-
It's Dead, Jim!オープン
難易度 5/5 1週間以上 初心者へのやさしさ 15/100
-
Remove hard coded edition fallback対応中かも @alerque が 230 日前に担当しました。 オープン
難易度 1/5 1時間未満 初心者へのやさしさ 35/100
-
難易度 1/5 1時間未満 初心者へのやさしさ 55/100
-
難易度 3/5 1〜2日 初心者へのやさしさ 45/100
rust-lang/rust.vim の issue をすべて見る
似ている issue
-
[Bug]: Python mod.Box[T] annotation gets a false generic_arg edge that replaces the parameter_type one ('is' on tree-sitter nodes)対応中かも @rohit-jsfreaky が今日担当しました。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 88/100
Graphify-Labs/graphify#5110 · コメント 1 件 ·
メンテナーはふだん 2 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 67/100
bigbio/sdrf-pipelines#372 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
-
area:plugins kind:bug priority:p2 ready
難易度 2/5 1〜3時間 初心者へのやさしさ 86/100
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
メンテナーはふだん 1 日以内に返信
-
Djangonauts
難易度 2/5 1〜3時間 初心者へのやさしさ 68/100
render-engine/render-engine-cli#71 ·
メンテナーはふだん 1 日以内に返信