Skip to content

Commit 2b5a42b

Browse files
committed
wip
1 parent b12e354 commit 2b5a42b

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

tests/FSharp.Compiler.ComponentTests/Language/ComputationExpressionTests.fs

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2092,6 +2092,7 @@ task {
20922092
|> typecheck
20932093
|> shouldFail
20942094
|> withDiagnostics [
2095+
// x: string
20952096
Error 1, Line 7, Col 10, Line 7, Col 19, "This expression was expected to have type
20962097
'int'
20972098
but here has type
@@ -2115,6 +2116,7 @@ task {
21152116
|> typecheck
21162117
|> shouldFail
21172118
|> withDiagnostics [
2119+
// x: string
21182120
Error 1, Line 7, Col 11, Line 7, Col 20, "This expression was expected to have type
21192121
'int'
21202122
but here has type
@@ -2138,6 +2140,7 @@ task {
21382140
|> typecheck
21392141
|> shouldFail
21402142
|> withDiagnostics [
2143+
// (x: string): int
21412144
Error 1, Line 7, Col 10, Line 7, Col 26, "This expression was expected to have type
21422145
'string'
21432146
but here has type
@@ -2167,10 +2170,12 @@ builder {
21672170
|> typecheck
21682171
|> shouldFail
21692172
|> withDiagnostics [
2173+
// y: string
21702174
Error 1, Line 13, Col 10, Line 13, Col 19, "This expression was expected to have type
21712175
'int'
21722176
but here has type
2173-
'string' ";
2177+
'string' "
2178+
// x: int
21742179
Warning 25, Line 12, Col 10, Line 12, Col 16, "Incomplete pattern matches on this expression."
21752180
]
21762181

@@ -2197,6 +2202,7 @@ builder {
21972202
|> typecheck
21982203
|> shouldFail
21992204
|> withDiagnostics [
2205+
// y: string
22002206
Error 1, Line 13, Col 11, Line 13, Col 20, "This expression was expected to have type
22012207
'int'
22022208
but here has type
@@ -2226,10 +2232,12 @@ builder {
22262232
|> typecheck
22272233
|> shouldFail
22282234
|> withDiagnostics [
2235+
// (y: int): string
22292236
Error 1, Line 13, Col 10, Line 13, Col 26, "This expression was expected to have type
22302237
'int'
22312238
but here has type
22322239
'string' "
2240+
// y: int
22332241
Error 1, Line 13, Col 11, Line 13, Col 17, "This expression was expected to have type
22342242
'string'
22352243
but here has type

0 commit comments

Comments
 (0)