Hacktoberfest 2026:维护者为十月标记出来的 issue,仍然开放、适合新手。 浏览 Hacktoberfest issue

Remove always-on language feature flag: ConstraintIntersectionOnFlexibleTypes

未关闭
#20,177 0 条评论 0 个 reaction 已指派 1 人 在 GitHub 查看

维护者通常 4 天内回复

@T-Gro 已经在做这个了。

开始于 2026年8月4日。

  • #20712 来自 @T-Gro —— 未关闭

评估

这个 Issue 还没有评估数据。

描述

LanguageFeature.ConstraintIntersectionOnFlexibleTypes has shipped since F# 8.0 and is enabled for every selectable language version (the minimum accepted --langversion is 8.0). Its feature flag can therefore never be turned off, so it is dead configuration. This issue removes the flag and collapses the guarded code to its enabled behaviour.

What to remove

  • The ConstraintIntersectionOnFlexibleTypes case in LanguageFeatures.fs and LanguageFeatures.fsi
  • Its entry in the features map and its GetFeatureString arm
  • The featureConstraintIntersectionOnFlexibleTypes string in FSComp.txt
  • Every SupportsFeature LanguageFeature.ConstraintIntersectionOnFlexibleTypes / checkLanguageFeatureAndRecover … ConstraintIntersectionOnFlexibleTypes guard — keep only the enabled path and delete the legacy branch
  • Adjust affected tests and baselines accordingly

Consequence: --disableLanguageFeature:ConstraintIntersectionOnFlexibleTypes is no longer a recognised feature name.

Version mapping
https://github.com/dotnet/fsharp/blob/ea778bb414648883fca4219bf7a69286bf82dd6b/src/Compiler/Facilities/LanguageFeatures.fs#L218

Feature string
https://github.com/dotnet/fsharp/blob/ea778bb414648883fca4219bf7a69286bf82dd6b/src/Compiler/FSComp.txt#L1608

Part of #20139

主要语言
F#
星标
4.3k
派生
879
平均合并
4 天 21 小时
30 天内合并 PR
105

环境准备

在 Codespaces 中打开

在浏览器里用你自己的 GitHub 账号启动这个项目的开发容器。

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

dotnet/fsharp 的其他 Issue

查看 dotnet/fsharp 的全部 Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。