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

Possibly wrong pattern for `union-type-case-data` in spec

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

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

評価

難易度
2/5
見積もり時間
1〜3時間
初心者へのやさしさ
55/100
issue の種類
ドキュメント
明瞭さ
明確に書かれている
活発さ
停滞
技術スタック
fsharp
領域
documentation

調査の方向性

まず、型定義セクションの139ページのソースを見つけ、文書化されている union-type-case-data の文法を、issue にあるコンパイルに成功する例および失敗する例と比較します。関数型のケースが必要な構文に一致するように文法を更新し、その後、レンダリングされた仕様に修正が反映されていることを確認します。

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

説明

language-spec

On a page 139 (8. Type definition) possible union cases listed as follow:

union-type-case-data := 
    ident --null union case
    ident of union-type-field * ... * union-type-field --n-ary union case
    ident : uncurried-sig --n-ary union case

uncurried-sig :=
    args-spec -> type

args-spec :=
    arg-spec * ... * arg-spec

But this one doesn't compile:

type Test =
    | A
    | B of int*int
    | C : int->int

with error:

Return types of union cases must be identical to the type being defined, up to abbreviations
This construct is deprecated: it is only for use in the F# library

But this one is correct:

type Test =
    | A
    | B of int*int
    | C of (int->int) //parentheses are required

So probably union-type-case-data should look like:

union-type-case-data := 
    ident --null union case
    ident of union-type-field * ... * union-type-field --n-ary union case
    ident of (uncurried-sig) --n-ary union case
主要言語
TeX
スター
311
フォーク
291
PR マージ指標
30日以内にマージされた PR はありません

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

このリポジトリのコントリビューションガイドは索引されていません

はじめの一歩

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

fsharp/fsharp.org のほかの issue

fsharp/fsharp.org の issue をすべて見る

似ている issue

Documentation の issue をもっと見る

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

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