@@ -88,6 +88,7 @@ let attribsOfSymbol (s:FSharpSymbol) =
8888 if v.IsImplicitConstructor then yield " ctor"
8989 if v.IsMutable then yield " mutable"
9090 if v.IsOverrideOrExplicitInterfaceImplementation then yield " overridemem"
91+ if v.IsInstanceMember && not v.IsInstanceMemberInCompiledCode then yield " funky"
9192 if v.IsExplicitInterfaceImplementation then yield " intfmem"
9293// if v.IsConstructorThisValue then yield "ctorthis"
9394// if v.IsMemberThisValue then yield "this"
@@ -202,7 +203,7 @@ let ``Test project1 whole project errors`` () =
202203 wholeProjectResults.Errors.[ 0 ]. EndColumn |> shouldEqual 44
203204
204205[<Test>]
205- let ``Test project39 should have protected FullName and TryFullName return same results`` () =
206+ let ``Test Project1 should have protected FullName and TryFullName return same results`` () =
206207 let wholeProjectResults = checker.ParseAndCheckProject( Project1.options) |> Async.RunSynchronously
207208 let rec getFullNameComparisons ( entity : FSharpEntity ) =
208209 seq { if not entity.IsProvided && entity.Accessibility.IsPublic then
@@ -2907,7 +2908,7 @@ let ``Test Project19 all symbols`` () =
29072908 ( " DayOfWeek" , " DayOfWeek" , " file1" , (( 10 , 15 ), ( 10 , 24 )), [],
29082909 [ " enum" ; " valuetype" ]);
29092910 ( " System" , " System" , " file1" , (( 10 , 8 ), ( 10 , 14 )), [], [ " namespace" ]);
2910- ( " field Monday" , " Monday" , " file1" , (( 10 , 8 ), ( 10 , 31 )), [], [ " field" ; " mutable " ; " static" ; " 1" ]);
2911+ ( " field Monday" , " Monday" , " file1" , (( 10 , 8 ), ( 10 , 31 )), [], [ " field" ; " static" ; " 1" ]);
29112912 ( " val s" , " s" , " file1" , (( 10 , 4 ), ( 10 , 5 )), [ " defn" ], [ " val" ]);
29122913 ( " Impl" , " Impl" , " file1" , (( 2 , 7 ), ( 2 , 11 )), [ " defn" ], [ " module" ])|]
29132914
@@ -4630,6 +4631,9 @@ let ``Test project37 typeof and arrays in attribute constructor arguments`` () =
46304631 |> Seq.map ( fun a -> a.AttributeType.CompiledName)
46314632 |> Array.ofSeq |> shouldEqual [| " AttrTestAttribute" ; " AttrTest2Attribute" |]
46324633
4634+ //-----------------------------------------------------------
4635+
4636+
46334637module Project38 =
46344638 open System.IO
46354639
@@ -4724,6 +4728,8 @@ let ``Test project38 abstract slot information`` () =
47244728 |]
47254729
47264730
4731+ //--------------------------------------------
4732+
47274733module Project39 =
47284734 open System.IO
47294735
@@ -4802,3 +4808,46 @@ let ``Test project39 all symbols`` () =
48024808 [[ " 'a" ]; [ " 'a0" ]; [ " 'a" ; " 'a0" ]]),
48034809 ( " return" , " 'b" ))]
48044810
4811+
4812+ //--------------------------------------------
4813+
4814+ module Project40 =
4815+ open System.IO
4816+
4817+ let fileName1 = Path.ChangeExtension( Path.GetTempFileName(), " .fs" )
4818+ let base2 = Path.GetTempFileName()
4819+ let dllName = Path.ChangeExtension( base2, " .dll" )
4820+ let projFileName = Path.ChangeExtension( base2, " .fsproj" )
4821+ let fileSource1 = """
4822+ module M
4823+
4824+ let f (x: option<_>) = x.IsSome, x.IsNone
4825+
4826+ (*
4827+ [<CompilationRepresentation(CompilationRepresentationFlags.UseNullAsTrueValue)>]
4828+ type C =
4829+ | A
4830+ | B of string
4831+ member x.IsItAnA = match x with A -> true | B _ -> false
4832+ member x.IsItAnAMethod() = match x with A -> true | B _ -> false
4833+
4834+ let g (x: C) = x.IsItAnA,x.IsItAnAMethod()
4835+ *)
4836+ """
4837+
4838+ File.WriteAllText( fileName1, fileSource1)
4839+ let fileNames = [ fileName1]
4840+ let args = mkProjectCommandLineArgs ( dllName, fileNames)
4841+ let options = checker.GetProjectOptionsFromCommandLineArgs ( projFileName, args)
4842+ let cleanFileName a = if a = fileName1 then " file1" else " ??"
4843+
4844+ [<Test>]
4845+ let ``Test Project40 all symbols`` () =
4846+
4847+ let wholeProjectResults = checker.ParseAndCheckProject( Project40.options) |> Async.RunSynchronously
4848+ let allSymbolUses = wholeProjectResults.GetAllUsesOfAllSymbols() |> Async.RunSynchronously
4849+ let allSymbolUsesInfo = [ for s in allSymbolUses -> s.Symbol.DisplayName, tups s.RangeAlternate, attribsOfSymbol s.Symbol ]
4850+ allSymbolUsesInfo |> shouldEqual
4851+ []
4852+
4853+
0 commit comments