Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

Is `VisitBaseType` internal field used consistently?

オープン
#144 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

評価

難易度
4/5
見積もり時間
3〜5日
初心者へのやさしさ
35/100
issue の種類
バグ
明瞭さ
おおむね明確
活発さ
停滞
技術スタック
csharp
領域
compilers

調査の方向性

TSqlFragmentVisitor から始め、Visit と ExplicitVisit の実装を比較し、具体例として DeclareCursorStatement とその VisitBaseType 分岐を使用します。対応する SQL フラグメント visitor メソッドで条件が逆になっていないか確認し、その動作が意図的なものかどうか、また VisitBaseType をどのように解釈すべきかを文書化します。

索引モデルが issue の本文から書いたものです。

説明

While diving deep into debugging my app I accidentally have noticed this: TSqlFragmentVisitor final code contains many blocks which check of VisitBaseType internal field value and if it is true then Visit method for base types is called, but for some sql-fragment classes Visit method implementation has this check negated and the behavior is reversed:

    // Summary:
    //     Visitor for DeclareCursorStatement
    public virtual void Visit(DeclareCursorStatement node)
    {
        if (!VisitBaseType)     <<<--- here
        {
            Visit((TSqlFragment)node);
        }
    }

    //
    // Summary:
    //     Explicit Visitor for DeclareCursorStatement
    public virtual void ExplicitVisit(DeclareCursorStatement node)
    {
        if (VisitBaseType)
        {
            Visit((TSqlStatement)node);
            Visit((TSqlFragment)node);
        }

        Visit(node);
        node.AcceptChildren(this);
    }

Is this expected behavior? If so, please clarify what was the intent, how VisitBaseType should be understood.

主要言語
GAP
スター
277
フォーク
43
平均マージ
6日 17時間
マージ済み PR(30日)
3

コントリビューションガイド

コントリビューションガイドを開く

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

microsoft/SqlScriptDOM のほかの issue

microsoft/SqlScriptDOM の issue をすべて見る

似ている issue

Compilers の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。