forked from dotnet/fsharp
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Include end in nested module range. (dotnet#14751)
- Loading branch information
Showing
5 changed files
with
75 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
7 changes: 7 additions & 0 deletions
7
tests/service/data/SyntaxTree/NestedModule/NestedModuleWithBeginEndAndDecls.fs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
namespace X | ||
|
||
module Y = | ||
begin | ||
let a = 0 | ||
end | ||
|
30 changes: 30 additions & 0 deletions
30
tests/service/data/SyntaxTree/NestedModule/NestedModuleWithBeginEndAndDecls.fs.bsl
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
ImplFile | ||
(ParsedImplFileInput | ||
("/root/NestedModule/NestedModuleWithBeginEndAndDecls.fs", false, | ||
QualifiedNameOfFile NestedModuleWithBeginEndAndDecls, [], [], | ||
[SynModuleOrNamespace | ||
([X], false, DeclaredNamespace, | ||
[NestedModule | ||
(SynComponentInfo | ||
([], None, [], [Y], | ||
PreXmlDoc ((3,0), FSharp.Compiler.Xml.XmlDocCollector), false, | ||
None, (3,0--3,8)), false, | ||
[Let | ||
(false, | ||
[SynBinding | ||
(None, Normal, false, false, [], | ||
PreXmlDoc ((5,8), FSharp.Compiler.Xml.XmlDocCollector), | ||
SynValData | ||
(None, SynValInfo ([], SynArgInfo ([], false, None)), | ||
None), | ||
Named (SynIdent (a, None), false, None, (5,12--5,13)), | ||
None, Const (Int32 0, (5,16--5,17)), (5,12--5,13), | ||
Yes (5,8--5,17), { LeadingKeyword = Let (5,8--5,11) | ||
InlineKeyword = None | ||
EqualsRange = Some (5,14--5,15) })], | ||
(5,8--5,17))], false, (3,0--6,7), | ||
{ ModuleKeyword = Some (3,0--3,6) | ||
EqualsRange = Some (3,9--3,10) })], PreXmlDocEmpty, [], None, | ||
(1,0--6,7), { LeadingKeyword = Namespace (1,0--1,9) })], (true, false), | ||
{ ConditionalDirectives = [] | ||
CodeComments = [] }, set [])) |
5 changes: 5 additions & 0 deletions
5
tests/service/data/SyntaxTree/NestedModule/RangeOfBeginEnd.fs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
namespace X | ||
|
||
module Y = | ||
begin end | ||
|
16 changes: 16 additions & 0 deletions
16
tests/service/data/SyntaxTree/NestedModule/RangeOfBeginEnd.fs.bsl
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
ImplFile | ||
(ParsedImplFileInput | ||
("/root/NestedModule/RangeOfBeginEnd.fs", false, | ||
QualifiedNameOfFile RangeOfBeginEnd, [], [], | ||
[SynModuleOrNamespace | ||
([X], false, DeclaredNamespace, | ||
[NestedModule | ||
(SynComponentInfo | ||
([], None, [], [Y], | ||
PreXmlDoc ((3,0), FSharp.Compiler.Xml.XmlDocCollector), false, | ||
None, (3,0--3,8)), false, [], false, (3,0--4,13), | ||
{ ModuleKeyword = Some (3,0--3,6) | ||
EqualsRange = Some (3,9--3,10) })], PreXmlDocEmpty, [], None, | ||
(1,0--4,13), { LeadingKeyword = Namespace (1,0--1,9) })], | ||
(true, false), { ConditionalDirectives = [] | ||
CodeComments = [] }, set [])) |