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

Redesign XmlDoc collecting mechanism #11973

Merged
merged 27 commits into from
Sep 17, 2021
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
27 commits
Select commit Hold shift + click to select a range
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
2 changes: 1 addition & 1 deletion src/fsharp/FSharp.Core/Linq.fs
Original file line number Diff line number Diff line change
Expand Up @@ -497,7 +497,7 @@ module LeafExpressionConverter =
// or type T to an argument expecting Expression<T>.
| ImplicitExpressionConversionHelperQ (_, [_], [x1]) -> ConvExprToLinqInContext env x1

/// Use witnesses if they are available
// Use witnesses if they are available
| CallWithWitnesses (objArgOpt, _, minfo2, witnessArgs, args) ->
let fullArgs = witnessArgs @ args
let replacementExpr =
Expand Down
8 changes: 4 additions & 4 deletions src/fsharp/FSharp.Core/Query.fsi
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,15 @@ namespace Microsoft.FSharp.Linq
open System.Collections
open System.Collections.Generic

[<NoComparison; NoEquality; Sealed>]
/// <summary>
/// A partial input or result in an F# query. This type is used to support the F# query syntax.
/// </summary>
///
/// <namespacedoc><summary>
/// Library functionality for F# query syntax and interoperability with .NET LINQ Expressions. See
/// Library functionality for F# query syntax and interoperability with .NET LINQ Expressions. See
/// also <a href="https://docs.microsoft.com/en-us/dotnet/fsharp/language-reference/query-expressions">F# Query Expressions</a> in the F# Language Guide.
/// </summary></namespacedoc>
[<NoComparison; NoEquality; Sealed>]
type QuerySource<'T, 'Q> =
/// <summary>
/// A method used to support the F# query syntax.
Expand All @@ -30,9 +30,9 @@ namespace Microsoft.FSharp.Linq
/// </summary>
member Source : seq<'T>

[<Class>]
/// The type used to support the F# query syntax. Use 'query { ... }' to use the query syntax. See
/// The type used to support the F# query syntax. Use 'query { ... }' to use the query syntax. See
/// also <a href="https://docs.microsoft.com/en-us/dotnet/fsharp/language-reference/query-expressions">F# Query Expressions</a> in the F# Language Guide.
[<Class>]
type QueryBuilder =
/// <summary>Create an instance of this builder. Use 'query { ... }' to use the query syntax.</summary>
new : unit -> QueryBuilder
Expand Down
106 changes: 53 additions & 53 deletions src/fsharp/FSharp.Core/SI.fs
Original file line number Diff line number Diff line change
Expand Up @@ -4,112 +4,112 @@
namespace Microsoft.FSharp.Data.UnitSystems.SI.UnitNames
open Microsoft.FSharp.Core

[<Measure>]
/// The SI unit of length
[<Measure>]
type metre

[<Measure>]
/// The SI unit of length
[<Measure>]
type meter = metre

[<Measure>]
/// The SI unit of mass
[<Measure>]
type kilogram

[<Measure>]
/// The SI unit of time
[<Measure>]
type second

[<Measure>]
/// The SI unit of electric current
[<Measure>]
type ampere

[<Measure>]
/// The SI unit of thermodynamic temperature
[<Measure>]
type kelvin

[<Measure>]
/// The SI unit of amount of substance
[<Measure>]
type mole

[<Measure>]
/// The SI unit of luminous intensity
[<Measure>]
type candela

[<Measure>]
/// The SI unit of frequency
[<Measure>]
type hertz = / second

[<Measure>]
/// The SI unit of force
[<Measure>]
type newton = kilogram metre / second^2

[<Measure>]
/// The SI unit of pressure, stress
[<Measure>]
type pascal = newton / metre^2

[<Measure>]
/// The SI unit of energy, work, amount of heat
[<Measure>]
type joule = newton metre

[<Measure>]
/// The SI unit of power, radiant flux
[<Measure>]
type watt = joule / second

[<Measure>]
/// The SI unit of electric charge, amount of electricity
[<Measure>]
type coulomb = second ampere

[<Measure>]
/// The SI unit of electric potential difference, electromotive force
[<Measure>]
type volt = watt/ampere

[<Measure>]
/// The SI unit of capacitance
[<Measure>]
type farad = coulomb/volt

[<Measure>]
/// The SI unit of electric resistance
[<Measure>]
type ohm = volt/ampere

[<Measure>]
/// The SI unit of electric conductance
[<Measure>]
type siemens = ampere/volt

[<Measure>]
/// The SI unit of magnetic flux
[<Measure>]
type weber = volt second

[<Measure>]
/// The SI unit of magnetic flux density
[<Measure>]
type tesla = weber/metre^2

[<Measure>]
/// The SI unit of inductance
[<Measure>]
type henry = weber/ampere

[<Measure>]
/// The SI unit of luminous flux
[<Measure>]
type lumen = candela

[<Measure>]
/// The SI unit of illuminance
[<Measure>]
type lux = lumen/metre^2

[<Measure>]
/// The SI unit of activity referred to a radionuclide
[<Measure>]
type becquerel = second^-1

[<Measure>]
/// The SI unit of absorbed dose
[<Measure>]
type gray = joule/kilogram

[<Measure>]
/// The SI unit of does equivalent
[<Measure>]
type sievert = joule/kilogram

[<Measure>]
/// The SI unit of catalytic activity
[<Measure>]
type katal = mole/second


Expand All @@ -118,106 +118,106 @@ namespace Microsoft.FSharp.Data.UnitSystems.SI.UnitSymbols
open Microsoft.FSharp.Core
open Microsoft.FSharp.Data.UnitSystems.SI.UnitNames

[<Measure>]
/// A synonym for Metre, the SI unit of length
[<Measure>]
type m = metre

[<Measure>]
/// A synonym for kilogram, the SI unit of mass
[<Measure>]
type kg = kilogram

[<Measure>]
/// A synonym for second, the SI unit of time
[<Measure>]
type s = second

[<Measure>]
/// A synonym for ampere, the SI unit of electric current
[<Measure>]
type A = ampere

[<Measure>]
/// A synonym for kelvin, the SI unit of thermodynamic temperature
[<Measure>]
type K = kelvin

[<Measure>]
/// A synonym for mole, the SI unit of amount of substance
[<Measure>]
type mol = mole

[<Measure>]
/// A synonym for candela, the SI unit of luminous intensity
[<Measure>]
type cd = candela

[<Measure>]
/// A synonym for hertz, the SI unit of frequency
[<Measure>]
type Hz = hertz

[<Measure>]
/// A synonym for newton, the SI unit of force
[<Measure>]
type N = newton

[<Measure>]
/// A synonym for pascal, the SI unit of pressure, stress
[<Measure>]
type Pa = pascal

[<Measure>]
/// A synonym for joule, the SI unit of energy, work, amount of heat
[<Measure>]
type J = joule

[<Measure>]
/// A synonym for watt, the SI unit of power, radiant flux
[<Measure>]
type W = watt

[<Measure>]
/// A synonym for coulomb, the SI unit of electric charge, amount of electricity
[<Measure>]
type C = coulomb

[<Measure>]
/// A synonym for volt, the SI unit of electric potential difference, electromotive force
[<Measure>]
type V = volt

[<Measure>]
/// A synonym for farad, the SI unit of capacitance
[<Measure>]
type F = farad

[<Measure>]
/// A synonym for siemens, the SI unit of electric conductance
[<Measure>]
type S = siemens

[<Measure>]
/// A synonym for UnitNames.ohm, the SI unit of electric resistance.
[<Measure>]
type ohm = Microsoft.FSharp.Data.UnitSystems.SI.UnitNames.ohm

[<Measure>]
/// A synonym for weber, the SI unit of magnetic flux
[<Measure>]
type Wb = weber

[<Measure>]
/// A synonym for tesla, the SI unit of magnetic flux density
[<Measure>]
type T = tesla

[<Measure>]
/// A synonym for lumen, the SI unit of luminous flux
[<Measure>]
type lm = lumen

[<Measure>]
/// A synonym for lux, the SI unit of illuminance
[<Measure>]
type lx = lux

[<Measure>]
/// A synonym for becquerel, the SI unit of activity referred to a radionuclide
[<Measure>]
type Bq = becquerel

[<Measure>]
/// A synonym for gray, the SI unit of absorbed dose
[<Measure>]
type Gy = gray

[<Measure>]
/// A synonym for sievert, the SI unit of does equivalent
[<Measure>]
type Sv = sievert

[<Measure>]
/// A synonym for katal, the SI unit of catalytic activity
[<Measure>]
type kat = katal

[<Measure>]
/// A synonym for henry, the SI unit of inductance
[<Measure>]
type H = henry
4 changes: 2 additions & 2 deletions src/fsharp/FSharp.Core/array2.fsi
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,6 @@ namespace Microsoft.FSharp.Collections
open Microsoft.FSharp.Collections
open Microsoft.FSharp.Core

[<CompilationRepresentation(CompilationRepresentationFlags.ModuleSuffix)>]
[<RequireQualifiedAccess>]
/// <summary>Contains operations for working with 2-dimensional arrays.</summary>
///
/// <remarks>
Expand All @@ -23,6 +21,8 @@ namespace Microsoft.FSharp.Collections
/// Non-zero-based arrays can also be created using <c>Array2D.zeroCreateBased</c>,
/// <c>Array2D.createBased</c> and <c>Array2D.initBased</c>.</para>
/// </remarks>
[<CompilationRepresentation(CompilationRepresentationFlags.ModuleSuffix)>]
[<RequireQualifiedAccess>]
module Array2D =

/// <summary>Fetches the base-index for the first dimension of the array.</summary>
Expand Down
6 changes: 3 additions & 3 deletions src/fsharp/FSharp.Core/array3.fsi
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,13 @@ namespace Microsoft.FSharp.Collections
open Microsoft.FSharp.Core
open Microsoft.FSharp.Core.Operators

[<CompilationRepresentation(CompilationRepresentationFlags.ModuleSuffix)>]
[<RequireQualifiedAccess>]
/// <summary>Contains operations for working with rank 3 arrays.</summary>
///
/// <remarks>
/// See also <a href="https://docs.microsoft.com/dotnet/fsharp/language-reference/arrays">F# Language Guide - Arrays</a>.
/// </remarks>
[<CompilationRepresentation(CompilationRepresentationFlags.ModuleSuffix)>]
[<RequireQualifiedAccess>]
module Array3D =

/// <summary>Creates an array whose elements are all initially the given value.</summary>
Expand Down Expand Up @@ -135,9 +135,9 @@ namespace Microsoft.FSharp.Collections



/// <summary>Contains operations for working with rank 4 arrays. </summary>
[<CompilationRepresentation(CompilationRepresentationFlags.ModuleSuffix)>]
[<RequireQualifiedAccess>]
/// <summary>Contains operations for working with rank 4 arrays. </summary>
module Array4D =

/// <summary>Creates an array whose elements are all initially the given value</summary>
Expand Down
8 changes: 4 additions & 4 deletions src/fsharp/FSharp.Core/async.fs
Original file line number Diff line number Diff line change
Expand Up @@ -233,9 +233,9 @@ namespace Microsoft.FSharp.Control
// NOTE: this must be a tailcall
cont res

/// Represents rarely changing components of an in-flight async computation
[<NoEquality; NoComparison>]
[<AutoSerializable(false)>]
/// Represents rarely changing components of an in-flight async computation
type AsyncActivationAux =
{ /// The active cancellation token
token: CancellationToken
Expand All @@ -249,9 +249,9 @@ namespace Microsoft.FSharp.Control
/// Holds some commonly-allocated callbacks and a mutable location to use for a trampoline
trampolineHolder: TrampolineHolder }

/// Represents context for an in-flight async computation
[<NoEquality; NoComparison>]
[<AutoSerializable(false)>]
/// Represents context for an in-flight async computation
type AsyncActivationContents<'T> =
{ /// The success continuation
cont: cont<'T>
Expand Down Expand Up @@ -305,7 +305,7 @@ namespace Microsoft.FSharp.Control
contents.aux.ccont (OperationCanceledException (contents.aux.token))

/// Check for trampoline hijacking.
// Note, this must make tailcalls, so may not be an instance member taking a byref argument,
/// Note, this must make tailcalls, so may not be an instance member taking a byref argument,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks like an internal comment to me. @dsyme Could you advice?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@auduchinok, here it is rather suspicious since the line below is a continuation of this one and it begins with ///

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, I thought maybe it was better to change all comments below to // here?

Copy link
Contributor Author

@DedSec256 DedSec256 Sep 8, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

oh, below in the same file there is a similar comment that uses //

image

/// nor call any members taking byref arguments.
static member inline HijackCheckThenCall (ctxt: AsyncActivation<'T>) cont arg =
ctxt.aux.trampolineHolder.HijackCheckThenCall cont arg
Expand Down Expand Up @@ -756,7 +756,7 @@ namespace Microsoft.FSharp.Control
/// - Hijack check after 'entering' the implied try/finally and after MoveNext call
/// - Do not apply 'GetEnumerator' with exception protection. However for an 'async'
/// in an 'async { ... }' the exception protection will be provided by the enclosing
// Delay or Bind or similar construct.
/// Delay or Bind or similar construct.
/// - Apply 'MoveNext' with exception protection
/// - Apply 'Current' with exception protection

Expand Down
Loading