Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

format removing extra blank lines and add some fantomas defaults #13156

Merged
merged 1 commit into from
May 18, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,13 @@ root = true

[*.fs]
fsharp_newline_between_type_definition_and_members=true
fsharp_max_infix_operator_expression=80
fsharp_max_array_or_list_width=80
fsharp_max_array_or_list_number_of_items=5
fsharp_max_dot_get_expression_width=80
fsharp_multiline_block_brackets_on_same_column=true
fsharp_keep_max_number_of_blank_lines=1

[*.fsi]
fsharp_newline_between_type_definition_and_members=true
fsharp_keep_max_number_of_blank_lines=1
2 changes: 0 additions & 2 deletions src/Compiler/AbstractIL/il.fsi
Original file line number Diff line number Diff line change
Expand Up @@ -1535,7 +1535,6 @@ type ILPreTypeDef =
/// Realise the actual full typedef
abstract GetTypeDef: unit -> ILTypeDef


[<NoEquality; NoComparison; Sealed>]
type internal ILPreTypeDefImpl =
interface ILPreTypeDef
Expand Down Expand Up @@ -1710,7 +1709,6 @@ type ILAssemblyManifest =
member CustomAttrs: ILAttributes
member SecurityDecls: ILSecurityDecls


[<RequireQualifiedAccess>]
type ILNativeResource =
internal
Expand Down
6 changes: 0 additions & 6 deletions src/Compiler/AbstractIL/ilbinary.fsi
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,6 @@ type HasFieldMarshalTag =
val hfm_FieldDef: HasFieldMarshalTag
val hfm_ParamDef: HasFieldMarshalTag


[<Struct>]
type HasDeclSecurityTag =
member Tag: int32
Expand All @@ -117,7 +116,6 @@ val hds_TypeDef: HasDeclSecurityTag
val hds_MethodDef: HasDeclSecurityTag
val hds_Assembly: HasDeclSecurityTag


[<Struct>]
type MemberRefParentTag =
member Tag: int32
Expand All @@ -127,31 +125,27 @@ val mrp_ModuleRef: MemberRefParentTag
val mrp_MethodDef: MemberRefParentTag
val mrp_TypeSpec: MemberRefParentTag


[<Struct>]
type HasSemanticsTag =
member Tag: int32

val hs_Event: HasSemanticsTag
val hs_Property: HasSemanticsTag


[<Struct>]
type MethodDefOrRefTag =
member Tag: int32

val mdor_MethodDef: MethodDefOrRefTag
val mdor_MemberRef: MethodDefOrRefTag


[<Struct>]
type MemberForwardedTag =
member Tag: int32

val mf_FieldDef: MemberForwardedTag
val mf_MethodDef: MemberForwardedTag


[<Struct>]
type ImplementationTag =
member Tag: int32
Expand Down
2 changes: 0 additions & 2 deletions src/Compiler/AbstractIL/ilx.fsi
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ type IlxUnionCase =
member IsNullary: bool
member FieldTypes: ILType[]


type IlxUnionHasHelpers =
| NoHelpers
| AllHelpers
Expand Down Expand Up @@ -109,7 +108,6 @@ type IlxClosureSpec =
/// Indicates if a static field being used to store an instance of this closure (because it has no free variables)
member UseStaticField: bool


/// IlxClosureApps - i.e. types being applied at a callsite.
type IlxClosureApps =
| Apps_tyapp of ILType * IlxClosureApps
Expand Down
1 change: 0 additions & 1 deletion src/Compiler/Checking/InfoReader.fsi
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
// Copyright (c) Microsoft Corporation. All Rights Reserved. See License.txt in the project root for license information.


/// Select members from a type by name, searching the type hierarchy if needed
module internal FSharp.Compiler.InfoReader

Expand Down
2 changes: 0 additions & 2 deletions src/Compiler/Checking/NameResolution.fsi
Original file line number Diff line number Diff line change
Expand Up @@ -510,7 +510,6 @@ type TcResultsSink =
static member NoSink: TcResultsSink
static member WithSink: ITypecheckResultsSink -> TcResultsSink


/// Indicates if we only need one result or all possible results from a resolution.
[<RequireQualifiedAccess>]
type ResultCollectionSettings =
Expand Down Expand Up @@ -599,7 +598,6 @@ type LookupKind =
| Type
| Ctor


/// Indicates if a warning should be given for the use of upper-case identifiers in patterns
type WarnOnUpperFlag =
| WarnOnUpperCase
Expand Down
1 change: 0 additions & 1 deletion src/Compiler/Driver/CompilerImports.fsi
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,6 @@ type ImportedAssembly =
#endif
FSharpOptimizationData: Lazy<Option<LazyModuleInfo>> }


/// Tables of assembly resolutions
[<Sealed>]
type TcAssemblyResolutions =
Expand Down
1 change: 0 additions & 1 deletion src/Compiler/Interactive/fsi.fsi
Original file line number Diff line number Diff line change
Expand Up @@ -354,7 +354,6 @@ module Settings =

member internal AddedPrinters: Choice<Type * (obj -> string), Type * (obj -> obj)> list


/// <summary>The command line arguments after ignoring the arguments relevant to the interactive
/// environment and replacing the first argument with the name of the last script file,
/// if any. Thus 'fsi.exe test1.fs test2.fs -- hello goodbye' will give arguments
Expand Down
1 change: 0 additions & 1 deletion src/Compiler/Optimize/Optimizer.fsi
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,6 @@ type OptimizationSettings =
reportTotalSizes: bool
}


member JitOptimizationsEnabled: bool

member LocalOptimizationsEnabled: bool
Expand Down
1 change: 0 additions & 1 deletion src/Compiler/Service/SemanticClassificationKey.fsi
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ type internal SemanticClassificationKeyStore =
/// Get a read only view on the semantic classification key store
member GetView: unit -> SemanticClassificationView


/// A builder that will build an semantic classification key store based on the written Item and its associated range.
[<Sealed>]
type internal SemanticClassificationKeyStoreBuilder =
Expand Down
1 change: 0 additions & 1 deletion src/Compiler/Service/ServiceLexing.fsi
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ open System
open System.Threading
open FSharp.Compiler
open FSharp.Compiler.Text

#nowarn "57"

/// Represents encoded information for the end-of-line continuation of lexing
Expand Down
1 change: 0 additions & 1 deletion src/Compiler/Symbols/SymbolHelpers.fsi
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@ type public FSharpXmlDoc =
/// Indicates that the XML for the documentation can be found in a .xml documentation file for the given DLL, using the given signature key
| FromXmlFile of dllName: string * xmlSig: string


// Implementation details used by other code in the compiler
module internal SymbolHelpers =

Expand Down
1 change: 0 additions & 1 deletion src/Compiler/Symbols/Symbols.fsi
Original file line number Diff line number Diff line change
Expand Up @@ -990,7 +990,6 @@ type FSharpParameter =
/// Indicate this is an optional argument
member IsOptionalArg: bool


/// A subtype of FSharpSymbol that represents a single case within an active pattern
[<Class>]
type FSharpActivePatternCase =
Expand Down
1 change: 0 additions & 1 deletion src/Compiler/TypedTree/TypeProviders.fsi
Original file line number Diff line number Diff line change
Expand Up @@ -306,7 +306,6 @@ type ProvidedFieldInfo =

inherit ProvidedMemberInfo


member IsInitOnly: bool

member IsStatic: bool
Expand Down
3 changes: 0 additions & 3 deletions src/Compiler/TypedTree/TypedTreeOps.fsi
Original file line number Diff line number Diff line change
Expand Up @@ -920,7 +920,6 @@ val MeasureExprConExponent: TcGlobals -> bool -> TyconRef -> Measure -> Rational

val normalizeMeasure: TcGlobals -> Measure -> Measure


//-------------------------------------------------------------------------
// Members
//-------------------------------------------------------------------------
Expand Down Expand Up @@ -1936,7 +1935,6 @@ val mkByteArrayTy: TcGlobals -> TType

val mkInvalidCastExnNewobj: TcGlobals -> ILInstr


//-------------------------------------------------------------------------
// Construct calls to some intrinsic functions
//-------------------------------------------------------------------------
Expand Down Expand Up @@ -2254,7 +2252,6 @@ val mkCompilationMappingAttr: TcGlobals -> int -> ILAttribute

val mkCompilationMappingAttrWithSeqNum: TcGlobals -> int -> int -> ILAttribute


val mkCompilationMappingAttrWithVariantNumAndSeqNum: TcGlobals -> int -> int -> int -> ILAttribute

val mkCompilationMappingAttrForQuotationResource: TcGlobals -> string * ILTypeRef list -> ILAttribute
Expand Down
1 change: 0 additions & 1 deletion src/Compiler/TypedTree/tainted.fsi
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,6 @@ type internal TypeProviderError =
/// provides uniform way to process aggregated errors
member Iter: (TypeProviderError -> unit) -> unit


/// This struct wraps a value produced by a type provider to properly attribute any failures.
[<NoEquality; NoComparison; Class>]
type internal Tainted<'T> =
Expand Down
1 change: 0 additions & 1 deletion src/Compiler/Utilities/FileSystem.fsi
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,6 @@ type public IFileSystem =
/// Used to determine if a file will not be subject to deletion during the lifetime of a typical client process.
abstract IsStableFileHeuristic: fileName: string -> bool


/// Represents a default (memory-mapped) implementation of the file system
type DefaultFileSystem =
/// Create a default implementation of the file system
Expand Down
3 changes: 0 additions & 3 deletions src/Compiler/Utilities/illib.fsi
Original file line number Diff line number Diff line change
Expand Up @@ -229,7 +229,6 @@ module internal ValueOptionInternal =

val inline bind: f: ('a -> 'b voption) -> x: 'a voption -> 'b voption


module internal String =

val make: n: int -> c: char -> string
Expand Down Expand Up @@ -521,7 +520,6 @@ module internal NameMap =

val exists: f: ('a -> 'b -> bool) -> m: Map<'a, 'b> -> bool when 'a: comparison


val ofKeyedList: f: ('a -> 'b) -> l: 'a list -> Map<'b, 'a> when 'b: comparison

val ofList: l: (string * 'T) list -> NameMap<'T>
Expand Down Expand Up @@ -612,7 +610,6 @@ module internal MultiMap =

type internal LayeredMap<'Key, 'Value when 'Key: comparison> = Map<'Key, 'Value>


[<AutoOpen>]
module internal MapAutoOpens =
type internal Map<'Key, 'Value when 'Key: comparison> with
Expand Down
1 change: 0 additions & 1 deletion src/FSharp.Compiler.Interactive.Settings/fsiaux.fsi
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,6 @@ type InteractiveSession =
/// <summary>Sets the current event loop being used to process interactions.</summary>
member internal SetEventLoop: (unit -> bool) * ((unit -> obj) -> obj) * (unit -> unit) -> unit


module Settings =

/// <summary>The settings associated with the interactive session.</summary>
Expand Down
1 change: 0 additions & 1 deletion src/FSharp.Core/option.fsi
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ open System
open Microsoft.FSharp.Core
open Microsoft.FSharp.Collections


/// <summary>Contains operations for working with options.</summary>
///
/// <category>Options</category>
Expand Down
1 change: 0 additions & 1 deletion src/FSharp.Core/set.fsi
Original file line number Diff line number Diff line change
Expand Up @@ -380,7 +380,6 @@ module Set =
[<CompiledName("IsProperSuperset")>]
val isProperSuperset: set1: Set<'T> -> set2: Set<'T> -> bool


/// <summary>Returns the number of elements in the set. Same as <c>size</c>.</summary>
///
/// <param name="set">The input set.</param>
Expand Down