-
Notifications
You must be signed in to change notification settings - Fork 4.9k
Conversation
// Copyright (c) Microsoft. All rights reserved. | ||
// Licensed under the MIT license. See LICENSE file in the project root for full license information. | ||
|
||
using System.Resources; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Are such AssemblyInfo.cs files needed? I was under the impression that the buildtools supplied such attributes automatically.
Lots of tests are failing, with errors like:
|
/// </summary> | ||
public class PartConventionBuilder | ||
{ | ||
private readonly Type[] _emptyTypeArray = new Type[0]; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How about using Array.Empty<Type>
at call sites instead of having this field?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@stephentoub This library targets platforms like .NET 4.5, Windows Store 8, and Windows Phone 8 which I don't think have support for Array.Empty<T>
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I see, I didn't realize these libraries weren't just .NET Core versions.
Thanks, Daniel! Glad it's all building and almost ready to go. I'll re-review one more time once the remaining issues are addressed and it's squashed down (doesn't need to be a single commit, but it should be many fewer than 33, especially since many of those commits didn't build successfully). |
38aaa61
to
3bedf89
Compare
👍 |
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' "> | ||
</PropertyGroup> | ||
<ItemGroup> | ||
<Compile Include="..\..\Common\src\Microsoft\Internal\Assumes.cs"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
"..\..\Common\src"
should be replaced with "$(CommonPath)"
Regarding the remaining issues:
No.
Ideally, but there are tons of unused usings across corefx as is. I'm ok with this being addressed separately and in a cleanup effort consistently across the repo.
At this point, stable dependencies no longer need "-beta-*". |
@@ -0,0 +1,1185 @@ | |||
{ | |||
"locked": false, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Needs to be true
Thanks, Daniel. Left a few more comments, but otherwise LGTM for the initial merge. |
I've addressed all the feedback. I think @joshfree was of the opinion that when adding newly ported code, it should all be squashed down to one commit. Should I do so and then press the big green "merge" button? |
Personally I'd suggest squashing this down to two commits: one that covers your first three commits currently (initial code, formatting, building), and one that covers all of the subsequent cleanup you then did. The first commit would be from dotnet-bot, and the second commit would be from you. But if you feel there's a cleaner approach, maybe you feel some specific commit should be kept separate, etc., that's fine, too. Once that's done and CI passes again, merge away. |
So now it is just a matter of squashing the commits and after that it will be merged? Yay! Love to see System.Composition getting merged into CoreFX! 🎆 Going by @stephentoub's suggestion and other "initial commit" PRs, it would probably be 1c3415a, 1f1d240, 63f15b5 and 62bc5bd fixed up to 5b5364c. And remaining squashed to a separate commit with bulleted list ( Thanks for doing this @dsplaisted! 👌 |
* Use ReaderWriterLockSlim * Move duplicated code into common folder * Use EmptyArray<T> instead of new T[0] * Fix CLS Compliance error in System.Composition test library (See dotnet/roslyn#4293: CLS Compliance warning CS3016 is reported on non-public members) * Rename SilverlightTraceWriter.cs to DebuggerTraceWriter.cs * Use CommonPath build property to include common files * Remove unnecessary AssemblyInfo.cs files * Remove unused private constant in System.Composition.AttributedModel
c4f5fda
to
e40d701
Compare
…ition Add System.Composition Commit migrated from dotnet/corefx@7645db0
This PR adds System.Composition to CoreFx.
System.Composition consists of 5 different assemblies:
There is a general test project for all the assemblies, and another one specific to System.Composition.Convention. There are also two assemblies referenced by the general test project, and a project for perf testing.
I've created separate folders under /src for each of the five main assemblies, and put the general test project, the assemblies it references, and the perf test project in /src/System.Composition. I've put the solution file (System.Composition.sln) directly under /src.
I think this follows the current repository structure as closely as possible. Perhaps it makes more sense to put everything here under a System.Composition folder. Feedback is welcome.
Remaining issues
Follow-up for after PR is merged
ReadLock
type (discussion) #2995