Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
dotNET Platform
fsharp
比较版本
30bbce677c36d8b190c5400dd909ee45bef8ed48...0e471797f52dc75f7052d84e8d5e142339a05d89
F
fsharp
项目概览
dotNET Platform
/
fsharp
9 个月 前同步成功
通知
0
Star
1
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
F
fsharp
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
前往新版Gitcode,体验更适合开发者的 AI 搜索 >>
源分支
0e471797f52dc75f7052d84e8d5e142339a05d89
选择Git版本
...
目标分支
30bbce677c36d8b190c5400dd909ee45bef8ed48
选择Git版本
比较
Commits (2)
https://gitcode.net/dotnet/fsharp/-/commit/77d05bb16c8c3672151b8f8265ba1fe8e91b425d
Backport #15845 to 17.7 (#15848)
2023-08-24T15:59:23+02:00
Vlad Zarytovskii
vzaritovsky@hotmail.com
Co-authored-by: <span data-trailer="Co-authored-by:"><a href="mailto:florian.verdonck@outlook.com" title="florian.verdonck@outlook.com"></a><a href="javascript:void(0)" class="avatar s16 avatar-inline identicon bg1" style="text-decoration: none">N</a><a href="mailto:florian.verdonck@outlook.com" title="florian.verdonck@outlook.com">Florian Verdonck</a> <<a href="mailto:florian.verdonck@outlook.com" title="florian.verdonck@outlook.com">florian.verdonck@outlook.com</a>></span> Co-authored-by: <span data-trailer="Co-authored-by:"><a href="mailto:tomasgrosup@microsoft.com" title="tomasgrosup@microsoft.com"></a><a href="javascript:void(0)" class="avatar s16 avatar-inline identicon bg6" style="text-decoration: none">N</a><a href="mailto:tomasgrosup@microsoft.com" title="tomasgrosup@microsoft.com">Tomas Grosup</a> <<a href="mailto:tomasgrosup@microsoft.com" title="tomasgrosup@microsoft.com">tomasgrosup@microsoft.com</a>></span>
https://gitcode.net/dotnet/fsharp/-/commit/0e471797f52dc75f7052d84e8d5e142339a05d89
Update azure-pipelines.yml (fix perl, so signed build works) (#15857)
2023-08-25T14:19:49+02:00
Vlad Zarytovskii
vzaritovsky@hotmail.com
隐藏空白更改
内联
并排
Showing
8 changed file
with
120 addition
and
12 deletion
+120
-12
azure-pipelines.yml
azure-pipelines.yml
+9
-0
eng/Build.ps1
eng/Build.ps1
+11
-8
eng/Versions.props
eng/Versions.props
+1
-1
global.json
global.json
+1
-1
src/Compiler/Checking/CheckDeclarations.fs
src/Compiler/Checking/CheckDeclarations.fs
+4
-2
tests/FSharp.Compiler.ComponentTests/ConstraintSolver/MemberConstraints.fs
...iler.ComponentTests/ConstraintSolver/MemberConstraints.fs
+28
-0
tests/FSharp.Compiler.ComponentTests/Signatures/TestCasesForGenerationRoundTrip/member-contrains-type-extension.fsx
...orGenerationRoundTrip/member-contrains-type-extension.fsx
+23
-0
tests/FSharp.Compiler.ComponentTests/Signatures/TypeTests.fs
tests/FSharp.Compiler.ComponentTests/Signatures/TypeTests.fs
+43
-0
未找到文件。
azure-pipelines.yml
浏览文件 @
0e471797
...
...
@@ -142,6 +142,8 @@ stages:
/p:PublishToSymbolServer=true
/p:VisualStudioDropName=$(VisualStudioDropName)
/p:GenerateSbom=true
env
:
NativeToolsOnMachine
:
true
-
script
:
.\tests\EndToEndBuildTests\EndToEndBuildTests.cmd -c $(_BuildConfig)
displayName
:
End to end build tests
-
task
:
PublishTestResults@2
...
...
@@ -365,9 +367,13 @@ stages:
# yes, this is miserable, but - https://github.com/dotnet/arcade/issues/13239
-
script
:
eng\CIBuild.cmd -compressallmetadata -configuration $(_configuration) -$(_testKind)
env
:
NativeToolsOnMachine
:
true
displayName
:
Build / Test
condition
:
ne(variables['_testKind'], 'testIntegration')
-
script
:
eng\CIBuild.cmd -compressallmetadata -configuration $(_configuration) -$(_testKind)
env
:
NativeToolsOnMachine
:
true
displayName
:
Build / Integration Test
continueOnError
:
true
condition
:
eq(variables['_testKind'], 'testIntegration')
...
...
@@ -519,6 +525,7 @@ stages:
clean
:
true
-
script
:
.\Build.cmd -c Release -pack
env
:
NativeToolsOnMachine
:
true
FSHARP_EXPERIMENTAL_FEATURES
:
$(_experimental_flag)
-
script
:
.\tests\EndToEndBuildTests\EndToEndBuildTests.cmd -c Release
env
:
...
...
@@ -649,6 +656,8 @@ stages:
-
script
:
dotnet --list-sdks
displayName
:
Report dotnet SDK versions
-
script
:
.\Build.cmd $(_kind) -pack -c $(_BuildConfig)
env
:
NativeToolsOnMachine
:
true
displayName
:
Initial build and prepare packages.
-
script
:
$(Build.SourcesDirectory)/tests/AheadOfTime/Trimming/check.cmd
displayName
:
Build, trim, publish and check the state of the trimmed app.
...
...
eng/Build.ps1
浏览文件 @
0e471797
...
...
@@ -514,18 +514,13 @@ try {
TryDownloadDotnetFrameworkSdk
$nativeTools
=
InitializeNativeTools
if
(
-not
(
Test-Path
variable:NativeToolsOnMachine
))
{
$
env
:
PERL5Path
=
Join-Path
$nativeTools
"perl\5.3
2.1
.1\perl\bin\perl.exe"
$
env
:
PERL5Path
=
Join-Path
$nativeTools
"perl\5.3
8.0
.1\perl\bin\perl.exe"
write-host
"variable:NativeToolsOnMachine = unset or false"
$nativeTools
write-host
"Path =
$
env
:
PERL5Path
"
}
else
{
$
env
:
PERL5Path
=
Join-Path
$nativeTools
[
"perl"
]
"perl\bin\perl.exe"
write-host
"variable:NativeToolsOnMachine =
$
variable
:
NativeToolsOnMachine
"
$nativeTools
.
values
write-host
"Path =
$
env
:
PERL5Path
"
}
$dotnetPath
=
InitializeDotNetCli
$
env
:
DOTNET_ROOT
=
"
$dotnetPath
"
...
...
@@ -606,7 +601,15 @@ try {
$
env
:
LINK_EXE
=
"
$RepoRoot
\tests\fsharpqa\testenv\bin\link\link.exe"
$
env
:
OSARCH
=
$
env
:
PROCESSOR_ARCHITECTURE
write-host
"Exec-Console
$
env
:
PERL5Path
"
Exec-Console
$
env
:
PERL5Path
"""
$RepoRoot
\tests\fsharpqa\testenv\bin\runall.pl"" -resultsroot ""
$resultsRoot
"" -results
$resultsLog
-log
$errorLog
-fail
$failLog
-cleanup:no -procs:
$
env
:
NUMBER_OF_PROCESSORS
"
if
(
-not
(
Test-Path
variable:NativeToolsOnMachine
))
{
Exec-Console
$
env
:
PERL5Path
"""
$RepoRoot
\tests\fsharpqa\testenv\bin\runall.pl"" -resultsroot ""
$resultsRoot
"" -results
$resultsLog
-log
$errorLog
-fail
$failLog
-cleanup:no -procs:
$
env
:
NUMBER_OF_PROCESSORS
"
}
else
{
Exec-Console
"perl.exe"
"""
$RepoRoot
\tests\fsharpqa\testenv\bin\runall.pl"" -resultsroot ""
$resultsRoot
"" -results
$resultsLog
-log
$errorLog
-fail
$failLog
-cleanup:no -procs:
$
env
:
NUMBER_OF_PROCESSORS
"
}
write-host
"Exec-Console finished"
Pop-Location
}
...
...
eng/Versions.props
浏览文件 @
0e471797
...
...
@@ -15,7 +15,7 @@
<!-- F# Version components -->
<FSMajorVersion>7</FSMajorVersion>
<FSMinorVersion>0</FSMinorVersion>
<FSBuildVersion>40
0
</FSBuildVersion>
<FSBuildVersion>40
1
</FSBuildVersion>
<FSRevisionVersion>0</FSRevisionVersion>
<!-- -->
<!-- F# Language version -->
...
...
global.json
浏览文件 @
0e471797
...
...
@@ -15,7 +15,7 @@
"xcopy-msbuild"
:
"17.6.0-2"
},
"native-tools"
:
{
"perl"
:
"5.3
2.1
.1"
"perl"
:
"5.3
8.0
.1"
},
"msbuild-sdks"
:
{
"Microsoft.DotNet.Arcade.Sdk"
:
"8.0.0-beta.23320.3"
,
...
...
src/Compiler/Checking/CheckDeclarations.fs
浏览文件 @
0e471797
...
...
@@ -3958,8 +3958,10 @@ module TcDeclarations =
if
tcref
.
TyparsNoRange
.
Length
=
synTypars
.
Length
then
(
tcref
.
TyparsNoRange
,
synTypars
)
||>
List
.
zip
|>
List
.
iter
(
fun
(
typar
,
SynTyparDecl
.
SynTyparDecl
(_,
SynTypar
(
ident
=
untypedIdent
)))
->
typar
.
SetIdent
(
untypedIdent
)
|>
List
.
iter
(
fun
(
typar
,
SynTyparDecl
.
SynTyparDecl
(_,
tp
))
->
let
(
SynTypar
(
ident
=
untypedIdent
;
staticReq
=
sr
))
=
tp
if
typar
.
StaticReq
=
sr
then
typar
.
SetIdent
(
untypedIdent
)
)
res
...
...
tests/FSharp.Compiler.ComponentTests/ConstraintSolver/MemberConstraints.fs
浏览文件 @
0e471797
...
...
@@ -46,3 +46,31 @@ else ()
|>
run
|>
shouldSucceed
|>
withExitCode
0
[<
Fact
>]
let
``Respect nowarn 957 for extension method``
()
=
FSharp
"""
module Foo
type DataItem<'data> =
{ Identifier: string
Label: string
Data: 'data }
static member Create<'data>(identifier: string, label: string, data: 'data) =
{ DataItem.Identifier = identifier
DataItem.Label = label
DataItem.Data = data }
#nowarn "
957
"
type DataItem< ^input> with
static member inline Create(item: ^input) =
let stringValue: string = (^input: (member get_StringValue: unit -> string) (item))
let friendlyStringValue: string = (^input: (member get_FriendlyStringValue: unit -> string) (item))
DataItem.Create< ^input>(stringValue, friendlyStringValue, item)
"""
|>
compile
|>
shouldSucceed
tests/FSharp.Compiler.ComponentTests/Signatures/TestCasesForGenerationRoundTrip/member-contrains-type-extension.fsx
0 → 100644
浏览文件 @
0e471797
module
Extensions
type
DataItem
<
'
data
>
=
{
Identifier
:
string
Label
:
string
Data
:
'
data
}
static
member
Create
<
'
data
>(
identifier
:
string
,
label
:
string
,
data
:
'
data
)
=
{
DataItem
.
Identifier
=
identifier
DataItem
.
Label
=
label
DataItem
.
Data
=
data
}
#
nowarn
"957"
type
DataItem
<
^
input
>
with
static
member
inline
Create
(
item
:
^
input
)
=
let
stringValue
:
string
=
(^
input
:
(
member
get_StringValue
:
unit
->
string
)
(
item
))
let
friendlyStringValue
:
string
=
(^
input
:
(
member
get_FriendlyStringValue
:
unit
->
string
)
(
item
))
DataItem
.
Create
<
^
input
>(
stringValue
,
friendlyStringValue
,
item
)
\ No newline at end of file
tests/FSharp.Compiler.ComponentTests/Signatures/TypeTests.fs
浏览文件 @
0e471797
...
...
@@ -133,6 +133,49 @@ type System.Collections.Concurrent.ConcurrentDictionary<'key,'value> with
member TryFind: key: 'key -> 'value option"""
[<
Fact
>]
let
``Don't update typar name in type extension when TyparStaticReq doesn't match``
()
=
FSharp
"""
module Extensions
type DataItem<'data> =
{ Identifier: string
Label: string
Data: 'data }
static member Create<'data>(identifier: string, label: string, data: 'data) =
{ DataItem.Identifier = identifier
DataItem.Label = label
DataItem.Data = data }
#nowarn "
957
"
type DataItem< ^input> with
static member inline Create(item: ^input) =
let stringValue: string = (^input: (member get_StringValue: unit -> string) (item))
let friendlyStringValue: string =
(^input: (member get_FriendlyStringValue: unit -> string) (item))
DataItem.Create< ^input>(stringValue, friendlyStringValue, item)
"""
|>
printSignatures
|>
should
equal
"""
module Extensions
type DataItem<'data> =
{
Identifier: string
Label: string
Data: 'data
}
static member inline Create: item: ^input -> DataItem<^input> when ^input: (member get_StringValue: unit -> string) and ^input: (member get_FriendlyStringValue: unit -> string)
static member Create<'data> : identifier: string * label: string * data: 'data -> DataItem<'data>"""
[<
Fact
>]
let
``ValText for C# abstract member override``
()
=
let
csharp
=
CSharp
"""
...
...