Delphi parser drops every class member after a `const [ref]` parameter
メンテナーはふだん 1 日以内に返信
まだ誰も着手していません。
評価
- 難易度
- 4/5
- 見積もり時間
- 3〜5日
- 初心者へのやさしさ
- 60/100
- issue の種類
- バグ
- 明瞭さ
- 明確に書かれている
- 活発さ
- 活発
- 領域
- tooling
調査の方向性
Start by reproducing with the Min.pas file from the issue in an empty directory, running codegraph init -y . then codegraph node TMin and codegraph query ''. The payload does not name the parser source files, so locate the Delphi class-declaration parsing and how it reads method parameter lists, then compare the const [ref] case with the control that has the decoration removed. Done means TMin lists Before, WithRef and After, TMin.After resolves, and no AValue field is indexed.
索引モデルが issue の本文から書いたものです。
説明
Summary
In a Delphi (Object Pascal) unit, a method declared with a const [ref] parameter followed by another
parameter ends the class declaration for the parser: the [ref] method is lost, the parameter after it
is recorded as a field of the class, every member declared after it is missing from the index, and the
qualified names of those members (node TClass.Method) answer "not found". Parsing resumes at the next
class declaration.
Versions
codegraph --version: 1.6.0 (global install).npx -y @colbymchenry/[email protected]: same result on the same file.- Windows 10 Pro 10.0.19045; Node from the global npm install.
Minimal reproduction
Min.pas:
unit Min;
interface
type
TMin = class
public
procedure Before;
procedure WithRef(const [ref] AValue: Integer; const AOther: string);
procedure After;
end;
TNext = class
public
procedure Other;
end;
const
CAfterClass = 1;
implementation
procedure TMin.Before;
begin
end;
procedure TMin.WithRef(const [ref] AValue: Integer; const AOther: string);
begin
end;
procedure TMin.After;
begin
Before;
end;
procedure TNext.Other;
begin
end;
end.
Steps, in a directory holding only that file:
codegraph init -y .
codegraph node TMin
codegraph node TMin.After
codegraph node TNext
codegraph query '' --limit 50
Observed (1.6.0):
● 8 nodes, 7 edges
**Members (2):**
- Before (method):8
- AValue (field):9
Symbol "TMin.After" not found in the codebase
TNext lists Other (method):15, so parsing resumes at the next class. query '' lists AValue as a
field at :9, Before, CAfterClass, Other, TMin, TNext — no WithRef, no After.
Expected: TMin with three methods Before, WithRef, After; TMin.After resolving; no field AValue.
Control: the same file with [ref] removed (procedure WithRef(const AValue: Integer; const AOther: string);)
indexes with TMin listing all three methods and TMin.After resolving.
A [ref] parameter that is the last one in its list (procedure WithRef(const [ref] AValue: Integer);)
loses only that method and shifts the next member's recorded line by one (After (method):9 for a
declaration at line 10).
Note on the syntax
const [ref] is Delphi's "pass by reference even for small types" parameter decoration (documented under
Parameters (Delphi) — constant parameters, the [Ref] attribute). It appears in interface and
implementation declarations alike.
- 主要言語
- C
- スター
- 73.2k
- フォーク
- 4.7k
- 平均マージ
- 12時間 30分
- マージ済み PR(30日)
- 558
環境構築
このプロジェクトには開発コンテナ、Dockerfile、コントリビューションガイドがありません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
colbymchenry/codegraph のほかの issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 70/100
colbymchenry/codegraph#2770 ·
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 90/100
colbymchenry/codegraph#2634 ·
メンテナーはふだん 1 日以内に返信
-
Windows: bundled Node v24.16.0 can abort at exit (nodejs/node#56645); please bundle Node >= 24.20.0対応中かも @Ancienttwo が 5 日前に担当しました。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 67/100
colbymchenry/codegraph#2617 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 68/100
colbymchenry/codegraph#1900 · コメント 2 件 · リアクション 5 件 ·
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
colbymchenry/codegraph#1700 ·
メンテナーはふだん 1 日以内に返信
colbymchenry/codegraph の issue をすべて見る
似ている issue
-
bug
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
valkey-io/valkey#4979 · リアクション 1 件 ·
メンテナーはふだん 2 日以内に返信
-
area/ysql kind/enhancement priority/medium status/awaiting-triage
難易度 2/5 1〜3時間 初心者へのやさしさ 73/100
yugabyte/yugabyte-db#35578 ·
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 66/100
メンテナーはふだん 1 日以内に返信
-
test_announce_and_connect_via_dns binds a fixed port that other tests' nodes can be handed対応中かも @ksedgwic が今日担当しました。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 83/100
ElementsProject/lightning#9642 ·
メンテナーはふだん 2 日以内に返信
-
Bug Status: Needs Triage
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
メンテナーはふだん 1 日以内に返信