From 64f4d33446308d3c00e22bca03aa365ed7f85935 Mon Sep 17 00:00:00 2001
From: Martin521 <29605222+Martin521@users.noreply.github.com>
Date: Sun, 1 Sep 2024 06:20:42 +0000
Subject: [PATCH 1/4] fix the checkFile bug
---
buildtools/fsyacc/fsyaccdriver.fs | 2 +
.../.FSharp.Compiler.Service/9.0.100.md | 1 +
docs/release-notes/.Language/preview.md | 1 +
src/Compiler/AbstractIL/ilpars.fsy | 1 +
src/Compiler/Driver/CompilerDiagnostics.fs | 24 ++++-----
src/Compiler/Driver/CompilerDiagnostics.fsi | 3 +-
src/Compiler/Driver/ParseAndCheckInputs.fs | 4 +-
src/Compiler/Driver/fsc.fs | 2 +-
src/Compiler/FSComp.txt | 1 +
src/Compiler/Facilities/LanguageFeatures.fs | 3 ++
src/Compiler/Facilities/LanguageFeatures.fsi | 1 +
src/Compiler/Service/IncrementalBuild.fs | 2 +-
src/Compiler/Service/TransparentCompiler.fs | 7 ++-
src/Compiler/pars.fsy | 1 +
src/Compiler/pppars.fsy | 1 +
src/Compiler/xlf/FSComp.txt.cs.xlf | 5 ++
src/Compiler/xlf/FSComp.txt.de.xlf | 5 ++
src/Compiler/xlf/FSComp.txt.es.xlf | 5 ++
src/Compiler/xlf/FSComp.txt.fr.xlf | 5 ++
src/Compiler/xlf/FSComp.txt.it.xlf | 5 ++
src/Compiler/xlf/FSComp.txt.ja.xlf | 5 ++
src/Compiler/xlf/FSComp.txt.ko.xlf | 5 ++
src/Compiler/xlf/FSComp.txt.pl.xlf | 5 ++
src/Compiler/xlf/FSComp.txt.pt-BR.xlf | 5 ++
src/Compiler/xlf/FSComp.txt.ru.xlf | 5 ++
src/Compiler/xlf/FSComp.txt.tr.xlf | 5 ++
src/Compiler/xlf/FSComp.txt.zh-Hans.xlf | 5 ++
src/Compiler/xlf/FSComp.txt.zh-Hant.xlf | 5 ++
.../CompilerDirectives/Nowarn.fs | 51 +++++++++++++++++++
.../FSharp.Compiler.ComponentTests.fsproj | 1 +
30 files changed, 150 insertions(+), 21 deletions(-)
create mode 100644 tests/FSharp.Compiler.ComponentTests/CompilerDirectives/Nowarn.fs
diff --git a/buildtools/fsyacc/fsyaccdriver.fs b/buildtools/fsyacc/fsyaccdriver.fs
index c9ca12e4710..f46e607f93a 100644
--- a/buildtools/fsyacc/fsyaccdriver.fs
+++ b/buildtools/fsyacc/fsyaccdriver.fs
@@ -199,6 +199,8 @@ let writeSpecToFile (generatorState: GeneratorState) (spec: ParserSpec) (compile
writer.WriteLineInterface "module %s" s;
writer.WriteLine "#nowarn \"64\";; // turn off warnings that type variables used in production annotations are instantiated to concrete type";
+ writer.WriteLine "#nowarn \"1182\" // the generated code often has unused variable 'parseState'"
+ writer.WriteLine "#nowarn \"3261\" // the generated code would need to properly annotate nulls, e.g. changing System.Object to `obj|null`";
for s in generatorState.opens do
writer.WriteLine "open %s" s;
diff --git a/docs/release-notes/.FSharp.Compiler.Service/9.0.100.md b/docs/release-notes/.FSharp.Compiler.Service/9.0.100.md
index 7e871eb33e1..e103b5a67b3 100644
--- a/docs/release-notes/.FSharp.Compiler.Service/9.0.100.md
+++ b/docs/release-notes/.FSharp.Compiler.Service/9.0.100.md
@@ -1,5 +1,6 @@
### Fixed
+* Fix a bug in the interaction between ``#line` and `#nowarn` directives ([PR #17649](https://github.com/dotnet/fsharp/pull/17649))
* Fix wrong TailCall warning ([Issue #17604](https://github.com/dotnet/fsharp/issues/17604), [PR #17637](https://github.com/dotnet/fsharp/pull/17637))
* Compiler hangs when compiling inline recursive invocation ([Issue #17376](https://github.com/dotnet/fsharp/issues/17376), [PR #17394](https://github.com/dotnet/fsharp/pull/17394))
* Fix reporting IsFromComputationExpression only for CE builder type constructors and let bindings. ([PR #17375](https://github.com/dotnet/fsharp/pull/17375))
diff --git a/docs/release-notes/.Language/preview.md b/docs/release-notes/.Language/preview.md
index dc79bbfe7e1..d57025fb5c3 100644
--- a/docs/release-notes/.Language/preview.md
+++ b/docs/release-notes/.Language/preview.md
@@ -21,6 +21,7 @@
* Enforce AttributeTargets on union case declarations. ([PR #16764](https://github.com/dotnet/fsharp/pull/16764))
* Enforce AttributeTargets on implicit constructors. ([PR #16845](https://github.com/dotnet/fsharp/pull/16845/))
* Enforce AttributeTargets on structs and classes ([PR #16790](https://github.com/dotnet/fsharp/pull/16790))
+* Ensure consistent interaction between ``#line` and `#nowarn` directives ([PR #17649](https://github.com/dotnet/fsharp/pull/17649))
### Changed
diff --git a/src/Compiler/AbstractIL/ilpars.fsy b/src/Compiler/AbstractIL/ilpars.fsy
index ca06f6570be..b8380364f6b 100644
--- a/src/Compiler/AbstractIL/ilpars.fsy
+++ b/src/Compiler/AbstractIL/ilpars.fsy
@@ -2,6 +2,7 @@
%{
+#nowarn "64" // turn off warnings that type variables used in production annotations are instantiated to concrete type
#nowarn "1182" // the generated code often has unused variable "parseState"
#nowarn "3261" // the generated code would need to properly annotate nulls, e.g. changing System.Object to `obj|null`
diff --git a/src/Compiler/Driver/CompilerDiagnostics.fs b/src/Compiler/Driver/CompilerDiagnostics.fs
index 1c50ca26781..2fb693a26d1 100644
--- a/src/Compiler/Driver/CompilerDiagnostics.fs
+++ b/src/Compiler/Driver/CompilerDiagnostics.fs
@@ -24,6 +24,7 @@ open FSharp.Compiler.ConstraintSolver
open FSharp.Compiler.DiagnosticMessage
open FSharp.Compiler.Diagnostics
open FSharp.Compiler.DiagnosticsLogger
+open FSharp.Compiler.Features
open FSharp.Compiler.Infos
open FSharp.Compiler.IO
open FSharp.Compiler.Lexhelp
@@ -2299,17 +2300,12 @@ type PhasedDiagnostic with
// Scoped #nowarn pragmas
/// Build an DiagnosticsLogger that delegates to another DiagnosticsLogger but filters warnings turned off by the given pragma declarations
-//
-// NOTE: we allow a flag to turn of strict file checking. This is because file names sometimes don't match due to use of
-// #line directives, e.g. for pars.fs/pars.fsy. In this case we just test by line number - in most cases this is sufficient
-// because we install a filtering error handler on a file-by-file basis for parsing and type-checking.
-// However this is indicative of a more systematic problem where source-line
-// sensitive operations (lexfilter and warning filtering) do not always
-// interact well with #line directives.
type DiagnosticsLoggerFilteringByScopedPragmas
- (checkFile, scopedPragmas, diagnosticOptions: FSharpDiagnosticOptions, diagnosticsLogger: DiagnosticsLogger) =
+ (langVersion: LanguageVersion, scopedPragmas, diagnosticOptions: FSharpDiagnosticOptions, diagnosticsLogger: DiagnosticsLogger) =
inherit DiagnosticsLogger("DiagnosticsLoggerFilteringByScopedPragmas")
+ let bugFixed = langVersion.SupportsFeature LanguageFeature.CheckFileBugFixed
+
let mutable realErrorPresent = false
override _.DiagnosticSink(diagnostic: PhasedDiagnostic, severity) =
@@ -2323,12 +2319,10 @@ type DiagnosticsLoggerFilteringByScopedPragmas
match diagnostic.Range with
| Some m ->
scopedPragmas
- |> List.exists (fun pragma ->
- let (ScopedPragma.WarningOff(pragmaRange, warningNumFromPragma)) = pragma
-
+ |> List.exists (fun (ScopedPragma.WarningOff(pragmaRange, warningNumFromPragma)) ->
warningNum = warningNumFromPragma
- && (not checkFile || m.FileIndex = pragmaRange.FileIndex)
- && posGeq m.Start pragmaRange.Start)
+ && (not bugFixed
+ || m.FileIndex = pragmaRange.FileIndex && posGeq m.Start pragmaRange.Start))
|> not
| None -> true
@@ -2344,5 +2338,5 @@ type DiagnosticsLoggerFilteringByScopedPragmas
override _.CheckForRealErrorsIgnoringWarnings = realErrorPresent
-let GetDiagnosticsLoggerFilteringByScopedPragmas (checkFile, scopedPragmas, diagnosticOptions, diagnosticsLogger) =
- DiagnosticsLoggerFilteringByScopedPragmas(checkFile, scopedPragmas, diagnosticOptions, diagnosticsLogger) :> DiagnosticsLogger
+let GetDiagnosticsLoggerFilteringByScopedPragmas (langVersion, scopedPragmas, diagnosticOptions, diagnosticsLogger) =
+ DiagnosticsLoggerFilteringByScopedPragmas(langVersion, scopedPragmas, diagnosticOptions, diagnosticsLogger) :> DiagnosticsLogger
diff --git a/src/Compiler/Driver/CompilerDiagnostics.fsi b/src/Compiler/Driver/CompilerDiagnostics.fsi
index 6139da434cf..7c5acef17d4 100644
--- a/src/Compiler/Driver/CompilerDiagnostics.fsi
+++ b/src/Compiler/Driver/CompilerDiagnostics.fsi
@@ -7,6 +7,7 @@ open System.Text
open FSharp.Compiler.CompilerConfig
open FSharp.Compiler.Diagnostics
open FSharp.Compiler.DiagnosticsLogger
+open FSharp.Compiler.Features
open FSharp.Compiler.Syntax
open FSharp.Compiler.Text
@@ -84,7 +85,7 @@ type PhasedDiagnostic with
/// Get a diagnostics logger that filters the reporting of warnings based on scoped pragma information
val GetDiagnosticsLoggerFilteringByScopedPragmas:
- checkFile: bool *
+ langVersion: LanguageVersion *
scopedPragmas: ScopedPragma list *
diagnosticOptions: FSharpDiagnosticOptions *
diagnosticsLogger: DiagnosticsLogger ->
diff --git a/src/Compiler/Driver/ParseAndCheckInputs.fs b/src/Compiler/Driver/ParseAndCheckInputs.fs
index a6804bfe746..d5d18d79651 100644
--- a/src/Compiler/Driver/ParseAndCheckInputs.fs
+++ b/src/Compiler/Driver/ParseAndCheckInputs.fs
@@ -511,7 +511,7 @@ let ParseInput
finally
// OK, now commit the errors, since the ScopedPragmas will (hopefully) have been scraped
let filteringDiagnosticsLogger =
- GetDiagnosticsLoggerFilteringByScopedPragmas(false, scopedPragmas, diagnosticOptions, diagnosticsLogger)
+ GetDiagnosticsLoggerFilteringByScopedPragmas(lexbuf.LanguageVersion, scopedPragmas, diagnosticOptions, diagnosticsLogger)
delayLogger.CommitDelayedDiagnostics filteringDiagnosticsLogger
@@ -1429,7 +1429,7 @@ let CheckOneInput
// Within a file, equip loggers to locally filter w.r.t. scope pragmas in each input
let DiagnosticsLoggerForInput (tcConfig: TcConfig, input: ParsedInput, oldLogger) =
- GetDiagnosticsLoggerFilteringByScopedPragmas(false, input.ScopedPragmas, tcConfig.diagnosticsOptions, oldLogger)
+ GetDiagnosticsLoggerFilteringByScopedPragmas(tcConfig.langVersion, input.ScopedPragmas, tcConfig.diagnosticsOptions, oldLogger)
/// Typecheck a single file (or interactive entry into F# Interactive)
let CheckOneInputEntry (ctok, checkForErrors, tcConfig: TcConfig, tcImports, tcGlobals, prefixPathOpt) tcState input =
diff --git a/src/Compiler/Driver/fsc.fs b/src/Compiler/Driver/fsc.fs
index ac4ee179538..9dccdec826d 100644
--- a/src/Compiler/Driver/fsc.fs
+++ b/src/Compiler/Driver/fsc.fs
@@ -745,7 +745,7 @@ let main2
yield! pragmas
]
- GetDiagnosticsLoggerFilteringByScopedPragmas(true, scopedPragmas, tcConfig.diagnosticsOptions, oldLogger)
+ GetDiagnosticsLoggerFilteringByScopedPragmas(tcConfig.langVersion, scopedPragmas, tcConfig.diagnosticsOptions, oldLogger)
SetThreadDiagnosticsLoggerNoUnwind diagnosticsLogger
diff --git a/src/Compiler/FSComp.txt b/src/Compiler/FSComp.txt
index 4776f65c28e..458954daebe 100644
--- a/src/Compiler/FSComp.txt
+++ b/src/Compiler/FSComp.txt
@@ -1782,3 +1782,4 @@ featureEmptyBodiedComputationExpressions,"Support for computation expressions wi
featureAllowAccessModifiersToAutoPropertiesGettersAndSetters,"Allow access modifiers to auto properties getters and setters"
3871,tcAccessModifiersNotAllowedInSRTPConstraint,"Access modifiers cannot be applied to an SRTP constraint."
featureAllowObjectExpressionWithoutOverrides,"Allow object expressions without overrides"
+featureCheckFileBugFixed,"checkFile bug fixed"
diff --git a/src/Compiler/Facilities/LanguageFeatures.fs b/src/Compiler/Facilities/LanguageFeatures.fs
index 5c311237594..d5406326e46 100644
--- a/src/Compiler/Facilities/LanguageFeatures.fs
+++ b/src/Compiler/Facilities/LanguageFeatures.fs
@@ -94,6 +94,7 @@ type LanguageFeature =
| ParsedHashDirectiveArgumentNonQuotes
| EmptyBodiedComputationExpressions
| AllowObjectExpressionWithoutOverrides
+ | CheckFileBugFixed
/// LanguageVersion management
type LanguageVersion(versionText) =
@@ -213,6 +214,7 @@ type LanguageVersion(versionText) =
LanguageFeature.ParsedHashDirectiveArgumentNonQuotes, languageVersion90
LanguageFeature.EmptyBodiedComputationExpressions, languageVersion90
LanguageFeature.EnforceAttributeTargets, languageVersion90
+ LanguageFeature.CheckFileBugFixed, languageVersion90
// F# preview
LanguageFeature.UnmanagedConstraintCsharpInterop, previewVersion // not enabled because: https://github.com/dotnet/fsharp/issues/17509
@@ -375,6 +377,7 @@ type LanguageVersion(versionText) =
| LanguageFeature.ParsedHashDirectiveArgumentNonQuotes -> FSComp.SR.featureParsedHashDirectiveArgumentNonString ()
| LanguageFeature.EmptyBodiedComputationExpressions -> FSComp.SR.featureEmptyBodiedComputationExpressions ()
| LanguageFeature.AllowObjectExpressionWithoutOverrides -> FSComp.SR.featureAllowObjectExpressionWithoutOverrides ()
+ | LanguageFeature.CheckFileBugFixed -> FSComp.SR.featureCheckFileBugFixed ()
/// Get a version string associated with the given feature.
static member GetFeatureVersionString feature =
diff --git a/src/Compiler/Facilities/LanguageFeatures.fsi b/src/Compiler/Facilities/LanguageFeatures.fsi
index 7408300b943..95e348b1b21 100644
--- a/src/Compiler/Facilities/LanguageFeatures.fsi
+++ b/src/Compiler/Facilities/LanguageFeatures.fsi
@@ -85,6 +85,7 @@ type LanguageFeature =
| ParsedHashDirectiveArgumentNonQuotes
| EmptyBodiedComputationExpressions
| AllowObjectExpressionWithoutOverrides
+ | CheckFileBugFixed
/// LanguageVersion management
type LanguageVersion =
diff --git a/src/Compiler/Service/IncrementalBuild.fs b/src/Compiler/Service/IncrementalBuild.fs
index 6b0c3f36c46..89f23605c79 100644
--- a/src/Compiler/Service/IncrementalBuild.fs
+++ b/src/Compiler/Service/IncrementalBuild.fs
@@ -259,7 +259,7 @@ type BoundModel private (
IncrementalBuilderEventTesting.MRU.Add(IncrementalBuilderEventTesting.IBETypechecked fileName)
let capturingDiagnosticsLogger = CapturingDiagnosticsLogger("TypeCheck")
- let diagnosticsLogger = GetDiagnosticsLoggerFilteringByScopedPragmas(false, input.ScopedPragmas, tcConfig.diagnosticsOptions, capturingDiagnosticsLogger)
+ let diagnosticsLogger = GetDiagnosticsLoggerFilteringByScopedPragmas(tcConfig.langVersion, input.ScopedPragmas, tcConfig.diagnosticsOptions, capturingDiagnosticsLogger)
use _ = new CompilationGlobalsScope(diagnosticsLogger, BuildPhase.TypeCheck)
beforeFileChecked.Trigger fileName
diff --git a/src/Compiler/Service/TransparentCompiler.fs b/src/Compiler/Service/TransparentCompiler.fs
index a2bc0beaf4b..908e2893124 100644
--- a/src/Compiler/Service/TransparentCompiler.fs
+++ b/src/Compiler/Service/TransparentCompiler.fs
@@ -1299,7 +1299,12 @@ type internal TransparentCompiler
let diagnosticsLogger = errHandler.DiagnosticsLogger
let diagnosticsLogger =
- GetDiagnosticsLoggerFilteringByScopedPragmas(false, input.ScopedPragmas, tcConfig.diagnosticsOptions, diagnosticsLogger)
+ GetDiagnosticsLoggerFilteringByScopedPragmas(
+ tcConfig.langVersion,
+ input.ScopedPragmas,
+ tcConfig.diagnosticsOptions,
+ diagnosticsLogger
+ )
use _ = new CompilationGlobalsScope(diagnosticsLogger, BuildPhase.TypeCheck)
diff --git a/src/Compiler/pars.fsy b/src/Compiler/pars.fsy
index fa45baa3c16..837dba035e8 100644
--- a/src/Compiler/pars.fsy
+++ b/src/Compiler/pars.fsy
@@ -2,6 +2,7 @@
%{
+#nowarn "64" // turn off warnings that type variables used in production annotations are instantiated to concrete type
#nowarn "1182" // generated code has lots of unused "parseState"
#nowarn "3261" // the generated code would need to properly annotate nulls, e.g. changing System.Object to `obj|null`
diff --git a/src/Compiler/pppars.fsy b/src/Compiler/pppars.fsy
index cd27722a254..41cb41ff38a 100644
--- a/src/Compiler/pppars.fsy
+++ b/src/Compiler/pppars.fsy
@@ -3,6 +3,7 @@
%{
open FSharp.Compiler.DiagnosticsLogger
+#nowarn "64" // turn off warnings that type variables used in production annotations are instantiated to concrete type
#nowarn "3261" // the generated code would need to properly annotate nulls, e.g. changing System.Object to `obj|null`
let dummy = IfdefId("DUMMY")
diff --git a/src/Compiler/xlf/FSComp.txt.cs.xlf b/src/Compiler/xlf/FSComp.txt.cs.xlf
index f48c78209bf..f6dfba1760f 100644
--- a/src/Compiler/xlf/FSComp.txt.cs.xlf
+++ b/src/Compiler/xlf/FSComp.txt.cs.xlf
@@ -297,6 +297,11 @@
Povolit implicitní atribut Extension pro deklarující typy, moduly
+
+ checkFile bug fixed
+ checkFile bug fixed
+
+ Raises warnings if a member or function has the 'TailCall' attribute, but is not being used in a tail recursive way.Vyvolá upozornění, pokud člen nebo funkce má atribut „TailCall“, ale nepoužívá se koncovým (tail) rekurzivním způsobem.
diff --git a/src/Compiler/xlf/FSComp.txt.de.xlf b/src/Compiler/xlf/FSComp.txt.de.xlf
index 7420a6afdc4..b1511ec69d1 100644
--- a/src/Compiler/xlf/FSComp.txt.de.xlf
+++ b/src/Compiler/xlf/FSComp.txt.de.xlf
@@ -297,6 +297,11 @@
Implizites Erweiterungsattribut für deklarierende Typen und Module zulassen
+
+ checkFile bug fixed
+ checkFile bug fixed
+
+ Raises warnings if a member or function has the 'TailCall' attribute, but is not being used in a tail recursive way.Löst Warnungen aus, wenn ein Member oder eine Funktion das Attribut "TailCall" aufweist, aber nicht endrekursiv verwendet wird.
diff --git a/src/Compiler/xlf/FSComp.txt.es.xlf b/src/Compiler/xlf/FSComp.txt.es.xlf
index 845bd6a8ca8..66b8b328c1f 100644
--- a/src/Compiler/xlf/FSComp.txt.es.xlf
+++ b/src/Compiler/xlf/FSComp.txt.es.xlf
@@ -297,6 +297,11 @@
Permitir atributo Extension implícito en tipos declarativo, módulos
+
+ checkFile bug fixed
+ checkFile bug fixed
+
+ Raises warnings if a member or function has the 'TailCall' attribute, but is not being used in a tail recursive way.Genera advertencias si un miembro o función tiene el atributo “TailCall”, pero no se usa de forma de recursión de cola.
diff --git a/src/Compiler/xlf/FSComp.txt.fr.xlf b/src/Compiler/xlf/FSComp.txt.fr.xlf
index 85ce7e5e43c..e2174c021a8 100644
--- a/src/Compiler/xlf/FSComp.txt.fr.xlf
+++ b/src/Compiler/xlf/FSComp.txt.fr.xlf
@@ -297,6 +297,11 @@
Autoriser l’attribut implicite Extension lors de la déclaration des types, modules
+
+ checkFile bug fixed
+ checkFile bug fixed
+
+ Raises warnings if a member or function has the 'TailCall' attribute, but is not being used in a tail recursive way.Lève des avertissements si un membre ou une fonction possède l'attribut « TailCall », mais n'est pas utilisé de manière récursive.
diff --git a/src/Compiler/xlf/FSComp.txt.it.xlf b/src/Compiler/xlf/FSComp.txt.it.xlf
index 887bd6e57cd..a03716a515f 100644
--- a/src/Compiler/xlf/FSComp.txt.it.xlf
+++ b/src/Compiler/xlf/FSComp.txt.it.xlf
@@ -297,6 +297,11 @@
Consentire l'attributo estensione implicito per i tipi dichiarabili, i moduli
+
+ checkFile bug fixed
+ checkFile bug fixed
+
+ Raises warnings if a member or function has the 'TailCall' attribute, but is not being used in a tail recursive way.Genera un avviso se un membro o una funzione ha l'attributo "TailCall", ma non è in uso in modo ricorsivo finale.
diff --git a/src/Compiler/xlf/FSComp.txt.ja.xlf b/src/Compiler/xlf/FSComp.txt.ja.xlf
index 1d5a0740a1e..593e514aac5 100644
--- a/src/Compiler/xlf/FSComp.txt.ja.xlf
+++ b/src/Compiler/xlf/FSComp.txt.ja.xlf
@@ -297,6 +297,11 @@
型、モジュールの宣言で暗黙的な拡張属性を許可する
+
+ checkFile bug fixed
+ checkFile bug fixed
+
+ Raises warnings if a member or function has the 'TailCall' attribute, but is not being used in a tail recursive way.メンバーまたは関数に 'TailCall' 属性があるが、末尾の再帰的な方法で使用されていない場合に警告を発生させます。
diff --git a/src/Compiler/xlf/FSComp.txt.ko.xlf b/src/Compiler/xlf/FSComp.txt.ko.xlf
index e8eebabddf5..4f825353cd1 100644
--- a/src/Compiler/xlf/FSComp.txt.ko.xlf
+++ b/src/Compiler/xlf/FSComp.txt.ko.xlf
@@ -297,6 +297,11 @@
유형, 모듈 선언에 암시적 확장 속성 허용
+
+ checkFile bug fixed
+ checkFile bug fixed
+
+ Raises warnings if a member or function has the 'TailCall' attribute, but is not being used in a tail recursive way.멤버 또는 함수에 'TailCall' 특성이 있지만 비상 재귀적인 방식으로 사용되지 않는 경우 경고를 발생합니다.
diff --git a/src/Compiler/xlf/FSComp.txt.pl.xlf b/src/Compiler/xlf/FSComp.txt.pl.xlf
index ca1b6a407b3..42105ef1ac2 100644
--- a/src/Compiler/xlf/FSComp.txt.pl.xlf
+++ b/src/Compiler/xlf/FSComp.txt.pl.xlf
@@ -297,6 +297,11 @@
Zezwalaj na niejawny atrybut Rozszerzenie dla deklarujących typów, modułów
+
+ checkFile bug fixed
+ checkFile bug fixed
+
+ Raises warnings if a member or function has the 'TailCall' attribute, but is not being used in a tail recursive way.Zgłasza ostrzeżenia, jeśli składowa lub funkcja ma atrybut „TailCall”, ale nie jest używana w sposób cykliczny końca.
diff --git a/src/Compiler/xlf/FSComp.txt.pt-BR.xlf b/src/Compiler/xlf/FSComp.txt.pt-BR.xlf
index f927f204fae..25ffed245a9 100644
--- a/src/Compiler/xlf/FSComp.txt.pt-BR.xlf
+++ b/src/Compiler/xlf/FSComp.txt.pt-BR.xlf
@@ -297,6 +297,11 @@
Permitir atributo de Extensão implícito em tipos declarativos, módulos
+
+ checkFile bug fixed
+ checkFile bug fixed
+
+ Raises warnings if a member or function has the 'TailCall' attribute, but is not being used in a tail recursive way.Gera avisos se um membro ou função tem o atributo "TailCall", mas não está sendo usado de maneira recursiva em cauda.
diff --git a/src/Compiler/xlf/FSComp.txt.ru.xlf b/src/Compiler/xlf/FSComp.txt.ru.xlf
index 5c3701a06de..cffc64c37da 100644
--- a/src/Compiler/xlf/FSComp.txt.ru.xlf
+++ b/src/Compiler/xlf/FSComp.txt.ru.xlf
@@ -297,6 +297,11 @@
Разрешить атрибут неявного расширения для объявляющих типов, модулей
+
+ checkFile bug fixed
+ checkFile bug fixed
+
+ Raises warnings if a member or function has the 'TailCall' attribute, but is not being used in a tail recursive way.Выдает предупреждения, если элемент или функция имеет атрибут "TailCall", но не используется в рекурсивном хвостовом режиме.
diff --git a/src/Compiler/xlf/FSComp.txt.tr.xlf b/src/Compiler/xlf/FSComp.txt.tr.xlf
index 9b13279b1eb..26f9b6ba627 100644
--- a/src/Compiler/xlf/FSComp.txt.tr.xlf
+++ b/src/Compiler/xlf/FSComp.txt.tr.xlf
@@ -297,6 +297,11 @@
Türler, modüller bildirirken örtük Extension özniteliğine izin ver
+
+ checkFile bug fixed
+ checkFile bug fixed
+
+ Raises warnings if a member or function has the 'TailCall' attribute, but is not being used in a tail recursive way.Üye veya işlevi, 'TailCallAttribute' özniteliğine sahip olmasına karşın kuyruk özyinelemeli bir şekilde kullanılmıyorsa uyarı verir.
diff --git a/src/Compiler/xlf/FSComp.txt.zh-Hans.xlf b/src/Compiler/xlf/FSComp.txt.zh-Hans.xlf
index c583e45c53d..58a671a7885 100644
--- a/src/Compiler/xlf/FSComp.txt.zh-Hans.xlf
+++ b/src/Compiler/xlf/FSComp.txt.zh-Hans.xlf
@@ -297,6 +297,11 @@
允许对声明类型、模块使用隐式扩展属性
+
+ checkFile bug fixed
+ checkFile bug fixed
+
+ Raises warnings if a member or function has the 'TailCall' attribute, but is not being used in a tail recursive way.如果成员或函数具有 "TailCall" 属性,但未以尾递归方式使用,则引发警告。
diff --git a/src/Compiler/xlf/FSComp.txt.zh-Hant.xlf b/src/Compiler/xlf/FSComp.txt.zh-Hant.xlf
index 17fc8934c3c..0da32b79869 100644
--- a/src/Compiler/xlf/FSComp.txt.zh-Hant.xlf
+++ b/src/Compiler/xlf/FSComp.txt.zh-Hant.xlf
@@ -297,6 +297,11 @@
允許宣告類型、模組上的隱含擴充屬性
+
+ checkFile bug fixed
+ checkFile bug fixed
+
+ Raises warnings if a member or function has the 'TailCall' attribute, but is not being used in a tail recursive way.如果成員或函式具有 'TailCall' 屬性,但未以尾遞迴方式使用,則引發警告。
diff --git a/tests/FSharp.Compiler.ComponentTests/CompilerDirectives/Nowarn.fs b/tests/FSharp.Compiler.ComponentTests/CompilerDirectives/Nowarn.fs
new file mode 100644
index 00000000000..78067aa8c32
--- /dev/null
+++ b/tests/FSharp.Compiler.ComponentTests/CompilerDirectives/Nowarn.fs
@@ -0,0 +1,51 @@
+// Copyright (c) Microsoft Corporation. All Rights Reserved. See License.txt in the project root for license information.
+namespace CompilerDirectives
+
+open Xunit
+open FSharp.Test.Compiler
+
+module Nowarn =
+
+ let warn20Text = "The result of this expression has type 'string' and is implicitly ignored. Consider using 'ignore' to discard this value explicitly, e.g. 'expr |> ignore', or 'let' to bind the result to a name, e.g. 'let result = expr'."
+
+ let checkFileBugSource = """
+module A
+#nowarn "20"
+#line 1 "xyz.fs"
+""
+ """
+
+ let checkFileBugSource2 = """
+module A
+#line 1 "xyz.fs"
+#nowarn "20"
+""
+ """
+
+
+ []
+ let ``checkFile bug simulation for compatibility`` () =
+
+ FSharp checkFileBugSource
+ |> withLangVersion80
+ |> compile
+ |> shouldSucceed
+
+ []
+ let ``checkFile bug fixed leads to new warning`` () =
+
+ FSharp checkFileBugSource
+ |> withLangVersion90
+ |> compile
+ |> shouldFail
+ |> withDiagnostics [
+ (Warning 20, Line 1, Col 1, Line 1, Col 3, warn20Text)
+ ]
+
+ []
+ let ``checkFile bug fixed, no warning if nowarn is correctly used`` () =
+
+ FSharp checkFileBugSource2
+ |> withLangVersion90
+ |> compile
+ |> shouldSucceed
diff --git a/tests/FSharp.Compiler.ComponentTests/FSharp.Compiler.ComponentTests.fsproj b/tests/FSharp.Compiler.ComponentTests/FSharp.Compiler.ComponentTests.fsproj
index 5c79022dc03..418c2c879ed 100644
--- a/tests/FSharp.Compiler.ComponentTests/FSharp.Compiler.ComponentTests.fsproj
+++ b/tests/FSharp.Compiler.ComponentTests/FSharp.Compiler.ComponentTests.fsproj
@@ -33,6 +33,7 @@
+
From d2fd933b61174057676e88c02483b50ce5eb633d Mon Sep 17 00:00:00 2001
From: Martin521 <29605222+Martin521@users.noreply.github.com>
Date: Fri, 6 Sep 2024 21:10:04 +0000
Subject: [PATCH 2/4] change the feature flag name
---
src/Compiler/Driver/CompilerDiagnostics.fs | 5 +++--
src/Compiler/FSComp.txt | 2 +-
src/Compiler/Facilities/LanguageFeatures.fs | 6 +++---
src/Compiler/Facilities/LanguageFeatures.fsi | 2 +-
4 files changed, 8 insertions(+), 7 deletions(-)
diff --git a/src/Compiler/Driver/CompilerDiagnostics.fs b/src/Compiler/Driver/CompilerDiagnostics.fs
index 2fb693a26d1..c73b8e5d197 100644
--- a/src/Compiler/Driver/CompilerDiagnostics.fs
+++ b/src/Compiler/Driver/CompilerDiagnostics.fs
@@ -2304,7 +2304,8 @@ type DiagnosticsLoggerFilteringByScopedPragmas
(langVersion: LanguageVersion, scopedPragmas, diagnosticOptions: FSharpDiagnosticOptions, diagnosticsLogger: DiagnosticsLogger) =
inherit DiagnosticsLogger("DiagnosticsLoggerFilteringByScopedPragmas")
- let bugFixed = langVersion.SupportsFeature LanguageFeature.CheckFileBugFixed
+ let needCompatibilityWithEarlierInconsistentInteraction =
+ not (langVersion.SupportsFeature LanguageFeature.ConsistentNowarnLineDirectiveInteraction)
let mutable realErrorPresent = false
@@ -2321,7 +2322,7 @@ type DiagnosticsLoggerFilteringByScopedPragmas
scopedPragmas
|> List.exists (fun (ScopedPragma.WarningOff(pragmaRange, warningNumFromPragma)) ->
warningNum = warningNumFromPragma
- && (not bugFixed
+ && (needCompatibilityWithEarlierInconsistentInteraction
|| m.FileIndex = pragmaRange.FileIndex && posGeq m.Start pragmaRange.Start))
|> not
| None -> true
diff --git a/src/Compiler/FSComp.txt b/src/Compiler/FSComp.txt
index 783dd553285..d1682d2dd1f 100644
--- a/src/Compiler/FSComp.txt
+++ b/src/Compiler/FSComp.txt
@@ -1784,4 +1784,4 @@ featureAllowAccessModifiersToAutoPropertiesGettersAndSetters,"Allow access modif
3871,tcAccessModifiersNotAllowedInSRTPConstraint,"Access modifiers cannot be applied to an SRTP constraint."
featureAllowObjectExpressionWithoutOverrides,"Allow object expressions without overrides"
3872,tcPartialActivePattern,"Multi-case partial active patterns are not supported. Consider using a single-case partial active pattern or a full active pattern."
-featureCheckFileBugFixed,"checkFile bug fixed"
+featureConsistentNowarnLineDirectiveInteraction,"checkFile bug fixed"
diff --git a/src/Compiler/Facilities/LanguageFeatures.fs b/src/Compiler/Facilities/LanguageFeatures.fs
index d5406326e46..530d0e5f2ba 100644
--- a/src/Compiler/Facilities/LanguageFeatures.fs
+++ b/src/Compiler/Facilities/LanguageFeatures.fs
@@ -94,7 +94,7 @@ type LanguageFeature =
| ParsedHashDirectiveArgumentNonQuotes
| EmptyBodiedComputationExpressions
| AllowObjectExpressionWithoutOverrides
- | CheckFileBugFixed
+ | ConsistentNowarnLineDirectiveInteraction
/// LanguageVersion management
type LanguageVersion(versionText) =
@@ -214,7 +214,7 @@ type LanguageVersion(versionText) =
LanguageFeature.ParsedHashDirectiveArgumentNonQuotes, languageVersion90
LanguageFeature.EmptyBodiedComputationExpressions, languageVersion90
LanguageFeature.EnforceAttributeTargets, languageVersion90
- LanguageFeature.CheckFileBugFixed, languageVersion90
+ LanguageFeature.ConsistentNowarnLineDirectiveInteraction, languageVersion90
// F# preview
LanguageFeature.UnmanagedConstraintCsharpInterop, previewVersion // not enabled because: https://github.com/dotnet/fsharp/issues/17509
@@ -377,7 +377,7 @@ type LanguageVersion(versionText) =
| LanguageFeature.ParsedHashDirectiveArgumentNonQuotes -> FSComp.SR.featureParsedHashDirectiveArgumentNonString ()
| LanguageFeature.EmptyBodiedComputationExpressions -> FSComp.SR.featureEmptyBodiedComputationExpressions ()
| LanguageFeature.AllowObjectExpressionWithoutOverrides -> FSComp.SR.featureAllowObjectExpressionWithoutOverrides ()
- | LanguageFeature.CheckFileBugFixed -> FSComp.SR.featureCheckFileBugFixed ()
+ | LanguageFeature.ConsistentNowarnLineDirectiveInteraction -> FSComp.SR.featureConsistentNowarnLineDirectiveInteraction ()
/// Get a version string associated with the given feature.
static member GetFeatureVersionString feature =
diff --git a/src/Compiler/Facilities/LanguageFeatures.fsi b/src/Compiler/Facilities/LanguageFeatures.fsi
index 95e348b1b21..4ae722c7f60 100644
--- a/src/Compiler/Facilities/LanguageFeatures.fsi
+++ b/src/Compiler/Facilities/LanguageFeatures.fsi
@@ -85,7 +85,7 @@ type LanguageFeature =
| ParsedHashDirectiveArgumentNonQuotes
| EmptyBodiedComputationExpressions
| AllowObjectExpressionWithoutOverrides
- | CheckFileBugFixed
+ | ConsistentNowarnLineDirectiveInteraction
/// LanguageVersion management
type LanguageVersion =
From a9370268ef6f26edaff5590b5485cf54fb080cee Mon Sep 17 00:00:00 2001
From: Martin521 <29605222+Martin521@users.noreply.github.com>
Date: Fri, 6 Sep 2024 21:35:26 +0000
Subject: [PATCH 3/4] updated xlf files
---
src/Compiler/xlf/FSComp.txt.cs.xlf | 10 +++++-----
src/Compiler/xlf/FSComp.txt.de.xlf | 10 +++++-----
src/Compiler/xlf/FSComp.txt.es.xlf | 10 +++++-----
src/Compiler/xlf/FSComp.txt.fr.xlf | 10 +++++-----
src/Compiler/xlf/FSComp.txt.it.xlf | 10 +++++-----
src/Compiler/xlf/FSComp.txt.ja.xlf | 10 +++++-----
src/Compiler/xlf/FSComp.txt.ko.xlf | 10 +++++-----
src/Compiler/xlf/FSComp.txt.pl.xlf | 10 +++++-----
src/Compiler/xlf/FSComp.txt.pt-BR.xlf | 10 +++++-----
src/Compiler/xlf/FSComp.txt.ru.xlf | 10 +++++-----
src/Compiler/xlf/FSComp.txt.tr.xlf | 10 +++++-----
src/Compiler/xlf/FSComp.txt.zh-Hans.xlf | 10 +++++-----
src/Compiler/xlf/FSComp.txt.zh-Hant.xlf | 10 +++++-----
13 files changed, 65 insertions(+), 65 deletions(-)
diff --git a/src/Compiler/xlf/FSComp.txt.cs.xlf b/src/Compiler/xlf/FSComp.txt.cs.xlf
index eb7f4096591..2fac271cd43 100644
--- a/src/Compiler/xlf/FSComp.txt.cs.xlf
+++ b/src/Compiler/xlf/FSComp.txt.cs.xlf
@@ -297,11 +297,6 @@
Povolit implicitní atribut Extension pro deklarující typy, moduly
-
- checkFile bug fixed
- checkFile bug fixed
-
- Raises warnings if a member or function has the 'TailCall' attribute, but is not being used in a tail recursive way.Vyvolá upozornění, pokud člen nebo funkce má atribut „TailCall“, ale nepoužívá se koncovým (tail) rekurzivním způsobem.
@@ -312,6 +307,11 @@
Vyvolá upozornění, pokud je atribut TailCall použit u nerekurzivních funkcí.
+
+ checkFile bug fixed
+ checkFile bug fixed
+
+ Constraint intersection on flexible typesPrůnik omezení u flexibilních typů
diff --git a/src/Compiler/xlf/FSComp.txt.de.xlf b/src/Compiler/xlf/FSComp.txt.de.xlf
index 8b94e7b1f47..8a328e5367a 100644
--- a/src/Compiler/xlf/FSComp.txt.de.xlf
+++ b/src/Compiler/xlf/FSComp.txt.de.xlf
@@ -297,11 +297,6 @@
Implizites Erweiterungsattribut für deklarierende Typen und Module zulassen
-
- checkFile bug fixed
- checkFile bug fixed
-
- Raises warnings if a member or function has the 'TailCall' attribute, but is not being used in a tail recursive way.Löst Warnungen aus, wenn ein Member oder eine Funktion das Attribut "TailCall" aufweist, aber nicht endrekursiv verwendet wird.
@@ -312,6 +307,11 @@
Löst Warnungen aus, wenn das Attribut "TailCall" für nicht rekursive Funktionen verwendet wird.
+
+ checkFile bug fixed
+ checkFile bug fixed
+
+ Constraint intersection on flexible typesEinschränkungsüberschneidung für flexible Typen
diff --git a/src/Compiler/xlf/FSComp.txt.es.xlf b/src/Compiler/xlf/FSComp.txt.es.xlf
index 3a8ebc75600..3a20491722e 100644
--- a/src/Compiler/xlf/FSComp.txt.es.xlf
+++ b/src/Compiler/xlf/FSComp.txt.es.xlf
@@ -297,11 +297,6 @@
Permitir atributo Extension implícito en tipos declarativo, módulos
-
- checkFile bug fixed
- checkFile bug fixed
-
- Raises warnings if a member or function has the 'TailCall' attribute, but is not being used in a tail recursive way.Genera advertencias si un miembro o función tiene el atributo “TailCall”, pero no se usa de forma de recursión de cola.
@@ -312,6 +307,11 @@
Genera advertencias si el atributo 'TailCall' se usa en funciones no recursivas.
+
+ checkFile bug fixed
+ checkFile bug fixed
+
+ Constraint intersection on flexible typesIntersección de restricciones en tipos flexibles
diff --git a/src/Compiler/xlf/FSComp.txt.fr.xlf b/src/Compiler/xlf/FSComp.txt.fr.xlf
index 495ed304d26..d0d368f1d6b 100644
--- a/src/Compiler/xlf/FSComp.txt.fr.xlf
+++ b/src/Compiler/xlf/FSComp.txt.fr.xlf
@@ -297,11 +297,6 @@
Autoriser l’attribut implicite Extension lors de la déclaration des types, modules
-
- checkFile bug fixed
- checkFile bug fixed
-
- Raises warnings if a member or function has the 'TailCall' attribute, but is not being used in a tail recursive way.Lève des avertissements si un membre ou une fonction possède l'attribut « TailCall », mais n'est pas utilisé de manière récursive.
@@ -312,6 +307,11 @@
Émet des avertissements si l’attribut « TailCall » est utilisé sur des fonctions non récursives.
+
+ checkFile bug fixed
+ checkFile bug fixed
+
+ Constraint intersection on flexible typesIntersection de contraintes sur les types flexibles
diff --git a/src/Compiler/xlf/FSComp.txt.it.xlf b/src/Compiler/xlf/FSComp.txt.it.xlf
index 413ed01efa4..52bb65f9426 100644
--- a/src/Compiler/xlf/FSComp.txt.it.xlf
+++ b/src/Compiler/xlf/FSComp.txt.it.xlf
@@ -297,11 +297,6 @@
Consentire l'attributo estensione implicito per i tipi dichiarabili, i moduli
-
- checkFile bug fixed
- checkFile bug fixed
-
- Raises warnings if a member or function has the 'TailCall' attribute, but is not being used in a tail recursive way.Genera un avviso se un membro o una funzione ha l'attributo "TailCall", ma non è in uso in modo ricorsivo finale.
@@ -312,6 +307,11 @@
Genera avvisi se l'attributo 'TailCall' viene utilizzato in funzioni non ricorsive.
+
+ checkFile bug fixed
+ checkFile bug fixed
+
+ Constraint intersection on flexible typesIntersezione di vincoli su tipi flessibili
diff --git a/src/Compiler/xlf/FSComp.txt.ja.xlf b/src/Compiler/xlf/FSComp.txt.ja.xlf
index 7c758e6c936..f25fa729ee6 100644
--- a/src/Compiler/xlf/FSComp.txt.ja.xlf
+++ b/src/Compiler/xlf/FSComp.txt.ja.xlf
@@ -297,11 +297,6 @@
型、モジュールの宣言で暗黙的な拡張属性を許可する
-
- checkFile bug fixed
- checkFile bug fixed
-
- Raises warnings if a member or function has the 'TailCall' attribute, but is not being used in a tail recursive way.メンバーまたは関数に 'TailCall' 属性があるが、末尾の再帰的な方法で使用されていない場合に警告を発生させます。
@@ -312,6 +307,11 @@
'TailCall' 属性が再帰関数以外で使用されている場合、警告が発せられます。
+
+ checkFile bug fixed
+ checkFile bug fixed
+
+ Constraint intersection on flexible typesフレキシブル型の制約積集合
diff --git a/src/Compiler/xlf/FSComp.txt.ko.xlf b/src/Compiler/xlf/FSComp.txt.ko.xlf
index 4b92a16e2e5..a5fe2374459 100644
--- a/src/Compiler/xlf/FSComp.txt.ko.xlf
+++ b/src/Compiler/xlf/FSComp.txt.ko.xlf
@@ -297,11 +297,6 @@
유형, 모듈 선언에 암시적 확장 속성 허용
-
- checkFile bug fixed
- checkFile bug fixed
-
- Raises warnings if a member or function has the 'TailCall' attribute, but is not being used in a tail recursive way.멤버 또는 함수에 'TailCall' 특성이 있지만 비상 재귀적인 방식으로 사용되지 않는 경우 경고를 발생합니다.
@@ -312,6 +307,11 @@
'TailCall' 특성이 비 재귀 함수에 사용되는 경우 경고를 발생합니다.
+
+ checkFile bug fixed
+ checkFile bug fixed
+
+ Constraint intersection on flexible types유연한 형식의 제약 조건 교집합
diff --git a/src/Compiler/xlf/FSComp.txt.pl.xlf b/src/Compiler/xlf/FSComp.txt.pl.xlf
index 6674626daa6..607a0702279 100644
--- a/src/Compiler/xlf/FSComp.txt.pl.xlf
+++ b/src/Compiler/xlf/FSComp.txt.pl.xlf
@@ -297,11 +297,6 @@
Zezwalaj na niejawny atrybut Rozszerzenie dla deklarujących typów, modułów
-
- checkFile bug fixed
- checkFile bug fixed
-
- Raises warnings if a member or function has the 'TailCall' attribute, but is not being used in a tail recursive way.Zgłasza ostrzeżenia, jeśli składowa lub funkcja ma atrybut „TailCall”, ale nie jest używana w sposób cykliczny końca.
@@ -312,6 +307,11 @@
Zgłasza ostrzeżenia, jeśli atrybut „TailCall” jest używany w funkcjach niekursywnych.
+
+ checkFile bug fixed
+ checkFile bug fixed
+
+ Constraint intersection on flexible typesPrzecięcie ograniczenia dla typów elastycznych
diff --git a/src/Compiler/xlf/FSComp.txt.pt-BR.xlf b/src/Compiler/xlf/FSComp.txt.pt-BR.xlf
index 51a4c8be6be..df9ebf2696d 100644
--- a/src/Compiler/xlf/FSComp.txt.pt-BR.xlf
+++ b/src/Compiler/xlf/FSComp.txt.pt-BR.xlf
@@ -297,11 +297,6 @@
Permitir atributo de Extensão implícito em tipos declarativos, módulos
-
- checkFile bug fixed
- checkFile bug fixed
-
- Raises warnings if a member or function has the 'TailCall' attribute, but is not being used in a tail recursive way.Gera avisos se um membro ou função tem o atributo "TailCall", mas não está sendo usado de maneira recursiva em cauda.
@@ -312,6 +307,11 @@
Gera avisos se o atributo "TailCall" for usado em funções não recursivas.
+
+ checkFile bug fixed
+ checkFile bug fixed
+
+ Constraint intersection on flexible typesInterseção de restrição em tipos flexíveis
diff --git a/src/Compiler/xlf/FSComp.txt.ru.xlf b/src/Compiler/xlf/FSComp.txt.ru.xlf
index 0ee6392b4f7..1c957d45ac8 100644
--- a/src/Compiler/xlf/FSComp.txt.ru.xlf
+++ b/src/Compiler/xlf/FSComp.txt.ru.xlf
@@ -297,11 +297,6 @@
Разрешить атрибут неявного расширения для объявляющих типов, модулей
-
- checkFile bug fixed
- checkFile bug fixed
-
- Raises warnings if a member or function has the 'TailCall' attribute, but is not being used in a tail recursive way.Выдает предупреждения, если элемент или функция имеет атрибут "TailCall", но не используется в рекурсивном хвостовом режиме.
@@ -312,6 +307,11 @@
Выдает предупреждения, если атрибут TailCall используется в нерекурсивных функциях.
+
+ checkFile bug fixed
+ checkFile bug fixed
+
+ Constraint intersection on flexible typesПересечение ограничений на гибких типах
diff --git a/src/Compiler/xlf/FSComp.txt.tr.xlf b/src/Compiler/xlf/FSComp.txt.tr.xlf
index 3d3df6fa394..b7ea06c7d13 100644
--- a/src/Compiler/xlf/FSComp.txt.tr.xlf
+++ b/src/Compiler/xlf/FSComp.txt.tr.xlf
@@ -297,11 +297,6 @@
Türler, modüller bildirirken örtük Extension özniteliğine izin ver
-
- checkFile bug fixed
- checkFile bug fixed
-
- Raises warnings if a member or function has the 'TailCall' attribute, but is not being used in a tail recursive way.Üye veya işlevi, 'TailCallAttribute' özniteliğine sahip olmasına karşın kuyruk özyinelemeli bir şekilde kullanılmıyorsa uyarı verir.
@@ -312,6 +307,11 @@
'TailCall' özniteliği özyinelemeli olmayan işlevlerde kullanılıyorsa uyarılar oluşturur.
+
+ checkFile bug fixed
+ checkFile bug fixed
+
+ Constraint intersection on flexible typesEsnek türlerde kısıtlama kesişimi
diff --git a/src/Compiler/xlf/FSComp.txt.zh-Hans.xlf b/src/Compiler/xlf/FSComp.txt.zh-Hans.xlf
index 27d807d92cc..79ee5b2e20c 100644
--- a/src/Compiler/xlf/FSComp.txt.zh-Hans.xlf
+++ b/src/Compiler/xlf/FSComp.txt.zh-Hans.xlf
@@ -297,11 +297,6 @@
允许对声明类型、模块使用隐式扩展属性
-
- checkFile bug fixed
- checkFile bug fixed
-
- Raises warnings if a member or function has the 'TailCall' attribute, but is not being used in a tail recursive way.如果成员或函数具有 "TailCall" 属性,但未以尾递归方式使用,则引发警告。
@@ -312,6 +307,11 @@
如果在非递归函数上使用“TailCall”属性,则引发警告。
+
+ checkFile bug fixed
+ checkFile bug fixed
+
+ Constraint intersection on flexible types灵活类型的约束交集
diff --git a/src/Compiler/xlf/FSComp.txt.zh-Hant.xlf b/src/Compiler/xlf/FSComp.txt.zh-Hant.xlf
index c59f10ffd2f..7d0d09941a8 100644
--- a/src/Compiler/xlf/FSComp.txt.zh-Hant.xlf
+++ b/src/Compiler/xlf/FSComp.txt.zh-Hant.xlf
@@ -297,11 +297,6 @@
允許宣告類型、模組上的隱含擴充屬性
-
- checkFile bug fixed
- checkFile bug fixed
-
- Raises warnings if a member or function has the 'TailCall' attribute, but is not being used in a tail recursive way.如果成員或函式具有 'TailCall' 屬性,但未以尾遞迴方式使用,則引發警告。
@@ -312,6 +307,11 @@
如果 'TailCall' 屬性用於非遞迴函數,則引發警告。
+
+ checkFile bug fixed
+ checkFile bug fixed
+
+ Constraint intersection on flexible types彈性類型上的條件約束交集
From 4e06e988b5991d4afe9117ea1d9cb6518ae84b4a Mon Sep 17 00:00:00 2001
From: Martin521 <29605222+Martin521@users.noreply.github.com>
Date: Sat, 7 Sep 2024 05:35:09 +0000
Subject: [PATCH 4/4] Another small name change
---
src/Compiler/FSComp.txt | 2 +-
src/Compiler/xlf/FSComp.txt.cs.xlf | 4 ++--
src/Compiler/xlf/FSComp.txt.de.xlf | 4 ++--
src/Compiler/xlf/FSComp.txt.es.xlf | 4 ++--
src/Compiler/xlf/FSComp.txt.fr.xlf | 4 ++--
src/Compiler/xlf/FSComp.txt.it.xlf | 4 ++--
src/Compiler/xlf/FSComp.txt.ja.xlf | 4 ++--
src/Compiler/xlf/FSComp.txt.ko.xlf | 4 ++--
src/Compiler/xlf/FSComp.txt.pl.xlf | 4 ++--
src/Compiler/xlf/FSComp.txt.pt-BR.xlf | 4 ++--
src/Compiler/xlf/FSComp.txt.ru.xlf | 4 ++--
src/Compiler/xlf/FSComp.txt.tr.xlf | 4 ++--
src/Compiler/xlf/FSComp.txt.zh-Hans.xlf | 4 ++--
src/Compiler/xlf/FSComp.txt.zh-Hant.xlf | 4 ++--
14 files changed, 27 insertions(+), 27 deletions(-)
diff --git a/src/Compiler/FSComp.txt b/src/Compiler/FSComp.txt
index d1682d2dd1f..2e391fa5515 100644
--- a/src/Compiler/FSComp.txt
+++ b/src/Compiler/FSComp.txt
@@ -1784,4 +1784,4 @@ featureAllowAccessModifiersToAutoPropertiesGettersAndSetters,"Allow access modif
3871,tcAccessModifiersNotAllowedInSRTPConstraint,"Access modifiers cannot be applied to an SRTP constraint."
featureAllowObjectExpressionWithoutOverrides,"Allow object expressions without overrides"
3872,tcPartialActivePattern,"Multi-case partial active patterns are not supported. Consider using a single-case partial active pattern or a full active pattern."
-featureConsistentNowarnLineDirectiveInteraction,"checkFile bug fixed"
+featureConsistentNowarnLineDirectiveInteraction,"The interaction between #nowarn and #line is now consistent."
diff --git a/src/Compiler/xlf/FSComp.txt.cs.xlf b/src/Compiler/xlf/FSComp.txt.cs.xlf
index 2fac271cd43..39b41f3b382 100644
--- a/src/Compiler/xlf/FSComp.txt.cs.xlf
+++ b/src/Compiler/xlf/FSComp.txt.cs.xlf
@@ -308,8 +308,8 @@
- checkFile bug fixed
- checkFile bug fixed
+ The interaction between #nowarn and #line is now consistent.
+ The interaction between #nowarn and #line is now consistent.
diff --git a/src/Compiler/xlf/FSComp.txt.de.xlf b/src/Compiler/xlf/FSComp.txt.de.xlf
index 8a328e5367a..402571c8a5a 100644
--- a/src/Compiler/xlf/FSComp.txt.de.xlf
+++ b/src/Compiler/xlf/FSComp.txt.de.xlf
@@ -308,8 +308,8 @@
- checkFile bug fixed
- checkFile bug fixed
+ The interaction between #nowarn and #line is now consistent.
+ The interaction between #nowarn and #line is now consistent.
diff --git a/src/Compiler/xlf/FSComp.txt.es.xlf b/src/Compiler/xlf/FSComp.txt.es.xlf
index 3a20491722e..d3267a7425c 100644
--- a/src/Compiler/xlf/FSComp.txt.es.xlf
+++ b/src/Compiler/xlf/FSComp.txt.es.xlf
@@ -308,8 +308,8 @@
- checkFile bug fixed
- checkFile bug fixed
+ The interaction between #nowarn and #line is now consistent.
+ The interaction between #nowarn and #line is now consistent.
diff --git a/src/Compiler/xlf/FSComp.txt.fr.xlf b/src/Compiler/xlf/FSComp.txt.fr.xlf
index d0d368f1d6b..f74bc4e3196 100644
--- a/src/Compiler/xlf/FSComp.txt.fr.xlf
+++ b/src/Compiler/xlf/FSComp.txt.fr.xlf
@@ -308,8 +308,8 @@
- checkFile bug fixed
- checkFile bug fixed
+ The interaction between #nowarn and #line is now consistent.
+ The interaction between #nowarn and #line is now consistent.
diff --git a/src/Compiler/xlf/FSComp.txt.it.xlf b/src/Compiler/xlf/FSComp.txt.it.xlf
index 52bb65f9426..3495d0c1659 100644
--- a/src/Compiler/xlf/FSComp.txt.it.xlf
+++ b/src/Compiler/xlf/FSComp.txt.it.xlf
@@ -308,8 +308,8 @@
- checkFile bug fixed
- checkFile bug fixed
+ The interaction between #nowarn and #line is now consistent.
+ The interaction between #nowarn and #line is now consistent.
diff --git a/src/Compiler/xlf/FSComp.txt.ja.xlf b/src/Compiler/xlf/FSComp.txt.ja.xlf
index f25fa729ee6..a87915633be 100644
--- a/src/Compiler/xlf/FSComp.txt.ja.xlf
+++ b/src/Compiler/xlf/FSComp.txt.ja.xlf
@@ -308,8 +308,8 @@
- checkFile bug fixed
- checkFile bug fixed
+ The interaction between #nowarn and #line is now consistent.
+ The interaction between #nowarn and #line is now consistent.
diff --git a/src/Compiler/xlf/FSComp.txt.ko.xlf b/src/Compiler/xlf/FSComp.txt.ko.xlf
index a5fe2374459..70a64e75a53 100644
--- a/src/Compiler/xlf/FSComp.txt.ko.xlf
+++ b/src/Compiler/xlf/FSComp.txt.ko.xlf
@@ -308,8 +308,8 @@
- checkFile bug fixed
- checkFile bug fixed
+ The interaction between #nowarn and #line is now consistent.
+ The interaction between #nowarn and #line is now consistent.
diff --git a/src/Compiler/xlf/FSComp.txt.pl.xlf b/src/Compiler/xlf/FSComp.txt.pl.xlf
index 607a0702279..31b8d2a6215 100644
--- a/src/Compiler/xlf/FSComp.txt.pl.xlf
+++ b/src/Compiler/xlf/FSComp.txt.pl.xlf
@@ -308,8 +308,8 @@
- checkFile bug fixed
- checkFile bug fixed
+ The interaction between #nowarn and #line is now consistent.
+ The interaction between #nowarn and #line is now consistent.
diff --git a/src/Compiler/xlf/FSComp.txt.pt-BR.xlf b/src/Compiler/xlf/FSComp.txt.pt-BR.xlf
index df9ebf2696d..c49d815ca06 100644
--- a/src/Compiler/xlf/FSComp.txt.pt-BR.xlf
+++ b/src/Compiler/xlf/FSComp.txt.pt-BR.xlf
@@ -308,8 +308,8 @@
- checkFile bug fixed
- checkFile bug fixed
+ The interaction between #nowarn and #line is now consistent.
+ The interaction between #nowarn and #line is now consistent.
diff --git a/src/Compiler/xlf/FSComp.txt.ru.xlf b/src/Compiler/xlf/FSComp.txt.ru.xlf
index 1c957d45ac8..495089d8c53 100644
--- a/src/Compiler/xlf/FSComp.txt.ru.xlf
+++ b/src/Compiler/xlf/FSComp.txt.ru.xlf
@@ -308,8 +308,8 @@
- checkFile bug fixed
- checkFile bug fixed
+ The interaction between #nowarn and #line is now consistent.
+ The interaction between #nowarn and #line is now consistent.
diff --git a/src/Compiler/xlf/FSComp.txt.tr.xlf b/src/Compiler/xlf/FSComp.txt.tr.xlf
index b7ea06c7d13..93dfdedb2bd 100644
--- a/src/Compiler/xlf/FSComp.txt.tr.xlf
+++ b/src/Compiler/xlf/FSComp.txt.tr.xlf
@@ -308,8 +308,8 @@
- checkFile bug fixed
- checkFile bug fixed
+ The interaction between #nowarn and #line is now consistent.
+ The interaction between #nowarn and #line is now consistent.
diff --git a/src/Compiler/xlf/FSComp.txt.zh-Hans.xlf b/src/Compiler/xlf/FSComp.txt.zh-Hans.xlf
index 79ee5b2e20c..54f6b088094 100644
--- a/src/Compiler/xlf/FSComp.txt.zh-Hans.xlf
+++ b/src/Compiler/xlf/FSComp.txt.zh-Hans.xlf
@@ -308,8 +308,8 @@
- checkFile bug fixed
- checkFile bug fixed
+ The interaction between #nowarn and #line is now consistent.
+ The interaction between #nowarn and #line is now consistent.
diff --git a/src/Compiler/xlf/FSComp.txt.zh-Hant.xlf b/src/Compiler/xlf/FSComp.txt.zh-Hant.xlf
index 7d0d09941a8..df3a706ae28 100644
--- a/src/Compiler/xlf/FSComp.txt.zh-Hant.xlf
+++ b/src/Compiler/xlf/FSComp.txt.zh-Hant.xlf
@@ -308,8 +308,8 @@
- checkFile bug fixed
- checkFile bug fixed
+ The interaction between #nowarn and #line is now consistent.
+ The interaction between #nowarn and #line is now consistent.