Skip to content

Commit

Permalink
Merge main to release/dev17.7 (#15041)
Browse files Browse the repository at this point in the history
* Make trimmed printf "%A" for F# records work when trimmed (#14941)

* Add tests

* Embed types

* baselines + fsx

* Extra telemetry for codefixes (#15035)

* BDN config option - ignore that Test.Utilities is not optimized (#15038)

* Unignore files for formatting (.fantomasignore) if the underlying Fantomas issue has been resolved (#14960)

* SI.fs fantomas'd

* unignore .fsi files in Fsharp.Core

* Removing commented out files from fantomasignore

* Automated command ran: fantomas

  Co-authored-by: T-Gro <46543583+T-Gro@users.noreply.github.com>

---------

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>

---------

Co-authored-by: Kevin Ransom (msft) <codecutter@hotmail.com>
Co-authored-by: Petr <psfinaki@users.noreply.github.com>
Co-authored-by: Tomas Grosup <tomasgrosup@microsoft.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
  • Loading branch information
5 people authored Apr 6, 2023
1 parent 415f84b commit e549827
Show file tree
Hide file tree
Showing 60 changed files with 9,768 additions and 3,790 deletions.
8 changes: 0 additions & 8 deletions .fantomasignore
Original file line number Diff line number Diff line change
Expand Up @@ -107,9 +107,6 @@ src/FSharp.Core/printf.fs
src/FSharp.Core/Query.fs
src/FSharp.Core/seqcore.fs

# Fantomas limitation https://github.com/fsprojects/fantomas/issues/2264

src/FSharp.Core/SI.fs

# Fantomas limitations on implementation files (to investigate)

Expand Down Expand Up @@ -139,8 +136,3 @@ src/FSharp.Core/Query.fsi
src/FSharp.Core/resumable.fsi
src/FSharp.Core/async.fsi

# Fantomas limitations on signature files in FSharp.Core (https://github.com/fsprojects/fantomas/issues/2230)

src/FSharp.Core/array.fsi
src/FSharp.Core/tasks.fsi
src/FSharp.Core/seq.fsi
13 changes: 13 additions & 0 deletions src/Compiler/AbstractIL/il.fs
Original file line number Diff line number Diff line change
Expand Up @@ -3292,6 +3292,12 @@ let destILArrTy ty =
[<Literal>]
let tname_Attribute = "System.Attribute"

[<Literal>]
let tname_Enum = "System.Enum"

[<Literal>]
let tname_SealedAttribute = "System.SealedAttribute"

[<Literal>]
let tname_Object = "System.Object"

Expand Down Expand Up @@ -3367,6 +3373,10 @@ type ILGlobals(primaryScopeRef: ILScopeRef, equivPrimaryAssemblyRefs: ILAssembly

member val typ_Attribute = mkILBoxedType (mkILNonGenericTySpec (mkSysILTypeRef tname_Attribute))

member val typ_Enum = mkILBoxedType (mkILNonGenericTySpec (mkSysILTypeRef tname_Enum))

member val typ_SealedAttribute = mkILBoxedType (mkILNonGenericTySpec (mkSysILTypeRef tname_SealedAttribute))

member val typ_Object = mkILBoxedType (mkILNonGenericTySpec (mkSysILTypeRef tname_Object))

member val typ_String = mkILBoxedType (mkILNonGenericTySpec (mkSysILTypeRef tname_String))
Expand Down Expand Up @@ -3985,6 +3995,9 @@ let mkILInstanceField (nm, ty, init, access) =
let mkILStaticField (nm, ty, init, at, access) =
mkILField (true, nm, ty, init, at, access, false)

let mkILStaticLiteralField (nm, ty, init, at, access) =
mkILField (true, nm, ty, Some init, at, access, true)

let mkILLiteralField (nm, ty, init, at, access) =
mkILField (true, nm, ty, Some init, at, access, true)

Expand Down
7 changes: 5 additions & 2 deletions src/Compiler/AbstractIL/il.fsi
Original file line number Diff line number Diff line change
Expand Up @@ -1815,7 +1815,10 @@ type internal ILGlobals =
member primaryAssemblyScopeRef: ILScopeRef
member primaryAssemblyRef: ILAssemblyRef
member primaryAssemblyName: string
member fsharpCoreAssemblyScopeRef: ILScopeRef

member typ_Attribute: ILType
member typ_Enum: ILType
member typ_Object: ILType
member typ_String: ILType
member typ_Type: ILType
Expand All @@ -1834,10 +1837,9 @@ type internal ILGlobals =
member typ_Double: ILType
member typ_Bool: ILType
member typ_Char: ILType
member typ_SealedAttribute: ILType
member typ_TypedReference: ILType

member fsharpCoreAssemblyScopeRef: ILScopeRef

/// Is the given assembly possibly a primary assembly?
/// In practice, a primary assembly is an assembly that contains the System.Object type definition
/// and has no referenced assemblies.
Expand Down Expand Up @@ -2051,6 +2053,7 @@ val internal mkILNonGenericInstanceMethod:
/// Make field definitions.
val internal mkILInstanceField: string * ILType * ILFieldInit option * ILMemberAccess -> ILFieldDef
val internal mkILStaticField: string * ILType * ILFieldInit option * byte[] option * ILMemberAccess -> ILFieldDef
val internal mkILStaticLiteralField: string * ILType * ILFieldInit * byte[] option * ILMemberAccess -> ILFieldDef
val internal mkILLiteralField: string * ILType * ILFieldInit * byte[] option * ILMemberAccess -> ILFieldDef

/// Make a type definition.
Expand Down
Loading

0 comments on commit e549827

Please sign in to comment.