You signed in with another tab or window.Reload to refresh your session.You signed out in another tab or window.Reload to refresh your session.You switched accounts on another tab or window.Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: src/fsharp/FSComp.txt
+2-2Lines changed: 2 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -656,8 +656,8 @@ tcExpressionWithIfRequiresParenthesis,"This list or array expression includes an
656
656
799,tcInvalidAssignment,"Invalid assignment"
657
657
800,tcInvalidUseOfTypeName,"Invalid use of a type name"
658
658
801,tcTypeHasNoAccessibleConstructor,"This type has no accessible object constructors"
659
-
802,tcInvalidUseOfTypeNameOrConstructor,"Invalid use of a type name and/or object constructor. If necessary use 'new' and apply the constructor to its arguments, e.g. 'new Type(args)'."
660
-
803,tcInvalidUseOfTypeNameOrConstructorWithOverloads,"Invalid use of a type name and/or object constructor. If necessary use 'new' and apply the constructor to its arguments, e.g. 'new Type(args)'. The required signature is:\n\t%s."
659
+
#802,tcInvalidUseOfTypeNameOrConstructor,"Invalid use of a type name and/or object constructor. If necessary use 'new' and apply the constructor to its arguments, e.g. 'new Type(args)'."
660
+
#803,tcInvalidUseOfTypeNameOrConstructorWithOverloads,"Invalid use of a type name and/or object constructor. If necessary use 'new' and apply the constructor to its arguments, e.g. 'new Type(args)'. The required signature is:\n\t%s."
661
661
804,tcInvalidUseOfInterfaceType,"Invalid use of an interface type"
662
662
805,tcInvalidUseOfDelegate,"Invalid use of a delegate constructor. Use the syntax 'new Type(args)' or just 'Type(args)'."
663
663
806,tcPropertyIsNotStatic,"Property '%s' is not static"
Copy file name to clipboardExpand all lines: tests/fsharp/typecheck/sigs/neg20.bsl
+23-4Lines changed: 23 additions & 4 deletions
Original file line number
Diff line number
Diff line change
@@ -356,9 +356,28 @@ neg20.fs(319,8,319,17): typecheck error FS3132: This type definition may not hav
356
356
357
357
neg20.fs(322,8,322,18): typecheck error FS3132: This type definition maynot have the 'CLIMutable' attribute. Only record types may have this attribute.
358
358
359
-
neg20.fs(335,11,335,24): typecheck errorFS0802: Invalid use of atypenameand/or object constructor.If necessary use 'new'and apply the constructorto its arguments, e.g. 'newType(args)'.
359
+
neg20.fs(335,11,335,24): typecheck errorFS0041: A unique overloadfor method 'String' couldnot be determined based ontypeinformation priorto this program point. A type annotation may be needed. Candidates: System.String(value: char []) : unit, System.String(value: nativeptr<char>) : unit, System.String(value: nativeptr<sbyte>) : unit
360
360
361
-
neg20.fs(336,11,336,22): typecheck errorFS0802: Invalid use of atypenameand/or object constructor.If necessary use 'new'and apply the constructorto its arguments, e.g. 'newType(args)'.
361
+
neg20.fs(336,11,336,22): typecheck errorFS0041: A unique overloadfor method 'Guid' couldnot be determined based ontypeinformation priorto this program point. A type annotation may be needed. Candidates: System.Guid(b: byte []) : unit, System.Guid(g: string) : unit
362
362
363
-
neg20.fs(340,11,340,34): typecheck error FS0803: Invalid use of a type nameand/or object constructor.If necessary use 'new'and apply the constructorto its arguments, e.g. 'newType(args)'. The required signature is:
364
-
new : x:int-> ClassWithOneConstructor.
363
+
neg20.fs(355,19,355,38): typecheck error FS1124: Multiple types exist called 'OverloadedClassName', taking different numbers of generic parameters. Provide a type instantiationto disambiguate the type resolution, e.g. 'OverloadedClassName<_>'.
364
+
365
+
neg20.fs(356,22,356,41): typecheck error FS1124: Multiple types exist called 'OverloadedClassName', taking different numbers of generic parameters. Provide a type instantiationto disambiguate the type resolution, e.g. 'OverloadedClassName<_>'.
366
+
367
+
neg20.fs(370,19,370,38): typecheck error FS0039: The valueor constructor 'OverloadedClassName' isnot defined
368
+
369
+
neg20.fs(371,19,371,38): typecheck error FS1124: Multiple types exist called 'OverloadedClassName', taking different numbers of generic parameters. Provide a type instantiationto disambiguate the type resolution, e.g. 'OverloadedClassName<_>'.
370
+
371
+
neg20.fs(372,22,372,41): typecheck error FS0039: The valueor constructor 'OverloadedClassName' isnot defined
372
+
373
+
neg20.fs(373,22,373,41): typecheck error FS1124: Multiple types exist called 'OverloadedClassName', taking different numbers of generic parameters. Provide a type instantiationto disambiguate the type resolution, e.g. 'OverloadedClassName<_>'.
374
+
375
+
neg20.fs(382,19,382,40): typecheck error FS1124: Multiple types exist called 'OverloadedClassName', taking different numbers of generic parameters. Provide a type instantiationto disambiguate the type resolution, e.g. 'OverloadedClassName<_>'.
376
+
377
+
neg20.fs(383,39,383,41): typecheck error FS0039: The field, constructoror member 'S2' isnot defined
378
+
379
+
neg20.fs(428,19,428,38): typecheck error FS0039: The valueor constructor 'OverloadedClassName' isnot defined
380
+
381
+
neg20.fs(430,22,430,41): typecheck error FS0039: The valueor constructor 'OverloadedClassName' isnot defined
382
+
383
+
neg20.fs(444,39,444,41): typecheck error FS0039: The field, constructoror member 'S2' isnot defined
lett2=3|> OverloadedClassName<int,int>// CHANGE IN ERROR MESSAGE IN F# 4.x: Was "Invalid use of a type name", now "The value or constructor 'OverloadedClassName' is not defined"
lett2s="3"|> OverloadedClassName<int,int>// CHANGE IN ERROR MESSAGE IN F# 4.x: Was "Invalid use of a type name", now "The value or constructor 'OverloadedClassName' is not defined"
lett2=3|> OverloadedClassName<int,int>// CHANGE IN ERROR MESSAGE IN F# 4.x: Was "Invalid use of a type name", now "The value or constructor 'OverloadedClassName' is not defined"
429
+
lett3=3|> OverloadedClassName// NO ERROR EXPECTED
430
+
lett2s="3"|> OverloadedClassName<int,int>// CHANGE IN ERROR MESSAGE IN F# 4.x: Was "Invalid use of a type name", now "The value or constructor 'OverloadedClassName' is not defined"