Skip to content

Instantly share code, notes, and snippets.

@SteveGilham
Last active December 8, 2018 20:22
Show Gist options
  • Save SteveGilham/64576d78f871727388106b788df87878 to your computer and use it in GitHub Desktop.
Save SteveGilham/64576d78f871727388106b788df87878 to your computer and use it in GitHub Desktop.
This is what happens to a record with an [<Obsolete>] field
{ Wanted = String.Empty
----^
stdin(8,5): warning FS0044: This construct is deprecated. Use 'Wanted' instead
{ Wanted = String.Empty
----^
stdin(8,5): warning FS0044: This construct is deprecated. Use 'Wanted' instead
let r2 = { R.Create() with Wanted = s }
-----------^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
stdin(14,12): warning FS0044: This construct is deprecated. Use 'Wanted' instead
let r3 = { R.Create() with Unwanted = s }
-----------^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
stdin(16,12): warning FS0044: This construct is deprecated. Use 'Wanted' instead
let r3 = { R.Create() with Unwanted = s }
-----------^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
stdin(16,12): warning FS0044: This construct is deprecated. Use 'Wanted' instead
{Wanted = "";
Unwanted = "";}
{Wanted = "is this wanted?";
Unwanted = "";}
{Wanted = "";
Unwanted = "is this wanted?";}
type R =
{Wanted: System.String;
Unwanted: System.String;}
with
static member Create : unit -> R
end
val UseR : s:System.String -> unit
val it : unit = ()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment