Skip to content

Commit 05d11d8

Browse files
committed
update tests
1 parent e404fa1 commit 05d11d8

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

src/Compiler/Checking/Expressions/CheckComputationExpressions.fs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1794,7 +1794,7 @@ let rec TryTranslateComputationExpression
17941794
ceenv.cenv.g.langVersion.SupportsFeature LanguageFeature.UseBangBindingValueDiscard
17951795

17961796
let supportsTypedLetOrUseBang =
1797-
ceenv.cenv.g.langVersion.SupportsFeature LanguageFeature.UseBangBindingValueDiscard
1797+
ceenv.cenv.g.langVersion.SupportsFeature LanguageFeature.AllowTypedLetOrUseBang
17981798

17991799
// use! x = ...
18001800
// use! (x) = ...

tests/FSharp.Compiler.ComponentTests/Conformance/BasicGrammarElements/UseBindings/UseBangBindings.fs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,9 @@ module UseBangBindingsVersion9 =
5959
|> typecheck
6060
|> shouldFail
6161
|> withDiagnostics [
62-
(Error 1228, Line 40, Col 14, Line 40, Col 29, "'use!' bindings must be of the form 'use! <var> = <expr>'")
62+
(Error 3350, Line 43, Col 14, Line 43, Col 28, "Feature 'Allow typed let! and use! bindings in computation expressions' is not available in F# 9.0. Please use language version 'PREVIEW' or greater.");
63+
(Error 3350, Line 41, Col 14, Line 41, Col 28, "Feature 'Allow typed let! and use! bindings in computation expressions' is not available in F# 9.0. Please use language version 'PREVIEW' or greater.");
64+
(Error 3350, Line 40, Col 14, Line 40, Col 29, "Feature 'Allow typed let! and use! bindings in computation expressions' is not available in F# 9.0. Please use language version 'PREVIEW' or greater.")
6365
]
6466

6567
module UseBangBindingsPreview =

0 commit comments

Comments
 (0)