1. 11 10月, 2014 3 次提交
    • T
      Remove duplicate package references. · 8fef5b5d
      tmeschter 提交于
      When our projects were last updated to a newer version of Microsoft.Net.ToolsetCompilers, NuGet didn't replace the old version--it just put the new version next to it. Every project ended up referencing both versions, and which set of compiler binaries "won" depended on the order they appeared in the project file. So different projects built with different compilers.
      
      This change strips out all references to the old version. (changeset 1352054)
      8fef5b5d
    • M
      Remove type constraint on ReplaceNodes API that forces the type of the... · c1f51f11
      mattwar 提交于
      Remove type constraint on ReplaceNodes API that forces the type of the replacement node to be of the same type as the node to be replaced. (changeset 1352036)
      c1f51f11
    • A
      C#: Report a use-site error if it could be a reason for failing to implement a... · 434bf14b
      AlekseyTs 提交于
      C#: Report a use-site error if it could be a reason for failing to implement a member of an interface. (changeset 1352026)
      434bf14b
  2. 10 10月, 2014 13 次提交
  3. 09 10月, 2014 6 次提交
  4. 08 10月, 2014 1 次提交
  5. 07 10月, 2014 15 次提交
    • T
      Merges MetadataReferenceProvider and MetadataReferenceResolver into a single type. · 7fa0b8fc
      TomasMatousek 提交于
      Previously the user had to pass both of these objects to CompilationOptions and the compiler had to call first the resolver to resolve the path specified in #r:
      
      string ResolveReference(string reference, string baseFilePath)
      
      and then the provider to create the reference:
      
      PortableExecutableReference GetReference(string resolvedPath, MetadataReferenceProperties properties)
      
      With this change the compiler simply calls on MetadataReferenceResolver:
      
      ImmutableArray<PortableExecutableReference> ResolveReference(string reference, string baseFilePath, MetadataReferenceProperties properties)
      
      Notice that now the resolver may return multiple references. This is needed to support #r of NuGet packages.
      
      We used reference resolvers and providers in many ways for multiple purposes. I left behind the metadata file resolvers and providers to avoid making too many changes, but made them internal. In some cases the usage is legitimate, but still an implementation detail. More cleanup will also be possible once we remove the old scripting API. For now I have worked around all these dependencies.
       (changeset 1349333)
      7fa0b8fc
    • M
      Add telemetry for FixAllOccurrences. (changeset 1349284) · e69b89d5
      manishv 提交于
      e69b89d5
    • J
      Make much of the Workspaces layer Portable. · e76a29a4
      jasonmalinowski 提交于
      This change splits the Workspaces layer into two parts, mirroring the Portable/Desktop split that the compilers did. The core parts of the Workspaces layer (managing documents and projects, formatting, some refactoring, code fixes) is kept in the portable subset, with a few non-portable pieces remaining, notably MSBuild support.
      
      This change has a major impact on how MEF now works in Roslyn. Traditional MEF (“MEFv1”) is not portable, and so we must move the Workspaces layer over to using the Microsoft.Composition NuGet package (“MEFv2”) which is. The APIs are distinct in that each has its own namespace, but the concepts are more or less identical. It requires some care though: the workspaces layer is simple in that it only references MEFv2, but higher layers have to reference both versions to use metadata attributes. Exports using metadata attributes from the editor (say, ContentTypeAttribute) must use MEFv1 attributes to export, whereas exports for the workspaces layer must use MEFv2 attributes. The rule is subtle and yet simple, and so a diagnostic is provided which catches any offenses to prevent confusion.
      
      This also has some impact in how we create MEF hosts: if you wish to host just the base workspaces layer, we can use MEFv2 to compose everything. The HostServices implementation (MefV1HostServices) that consumes a MEFv1 ExportProvider. If you’re in Visual Studio, you can use this implementation to get the full set of host services provided in Visual Studio.
      
      Otherwise, most of the changes in here are minor: we react to some APIs that have been moved/renamed in the portable subset we are targeting, and also align our various exception helper utilities with the compiler’s precedent. (changeset 1349276)
      e76a29a4
    • T
      Decouple Workspace metadata provider from compiler metadata provider. · d0ea0869
      TomasMatousek 提交于
      The service no longer derives directly from MetadataReferenceProvider. Instead the service exposes API to get metadata references and an instance of compiler reference provider. (changeset 1349108)
      d0ea0869
    • H
      4cbd636d
    • A
      InvalidCastException: ForEach->For (changeset 1348995) · 36fca427
      acasey 提交于
      36fca427
    • V
      Fix bug 990618: Fix spelling of SyntaxKind.BeginCDataToken from "<[CDATA[" to... · f5e03451
      vladres 提交于
      Fix bug 990618: Fix spelling of SyntaxKind.BeginCDataToken from "<[CDATA[" to "<![CDATA[". Also fix broken link in VisualBasicSyntaxGenerator.vbproj, removes some redundant code and fixes casing in some VB identifiers. (changeset 1348971)
      f5e03451
    • T
      Implements CR feedback for EmitOptions change: rename EmitOptions.OutputName... · cad06f2b
      TomasMatousek 提交于
      Implements CR feedback for EmitOptions change: rename EmitOptions.OutputName to OutputNameOverride and adds TolerateErrors and IncludePrivateMembers.  (changeset 1348868)
      cad06f2b
    • N
      629369-null check in delegate conversion · 755ffcd0
      nmgafter 提交于
      We insert a null check into the code generated for a delegate
      conversion, so that Nothing is converted to Nothing rather
      that throwing a null exception.
      
      Note that we continue to generate the incorrect null-throwing
      code for conversions appearing in expression trees. We do that
      because we don't want to break backward compatibility
      (there is no way to translate into the null-check version). (changeset 1348760)
      755ffcd0
    • J
      Fixing file IO race condition by always removing test files in-between... · adca56da
      jmarolf 提交于
      Fixing file IO race condition by always removing test files in-between compilations. (changeset 1348724)
      adca56da
    • V
    • C
    • M
      Fix for bug 1038056: Rationalize Diagnostic.Severity and Diagnostic.IsWarnAsError properties · a66bd965
      manishv 提交于
      Diagnostic.Severity property used to denote different things for compiler and user diagnostics. For compiler diagnostics, this property denotes the error code severity, i.e. the default severity of the diagnostic. For warnings as errors, this property still returned DiagnosticSeverity.Warning and the consumer had to check for the IsWarnAsError property to get the effective severity. For user diagnostics, this property denotes the effective severity based on the compilation options.
      
      This change makes the following changes:
      1) Change Diagnostic.Severity to always represent the effective severity of the diagnostic for both user and compiler diagnostics. So for warn as error, this will return error severity.
      2) Introduce Diagnostic.DefaultSeverity to represent the default severity of the diagnostic. This is the error code severity for compiler diagnostics and diagnostic descriptor severity for user diagnostics.
      3) Change IsWarningAsError property to return true iff Diagnostic.DefaultSeverity = Warning and Diagnostic.Severity = Error. (changeset 1348667)
      a66bd965
    • T
      042bc6fb
    • T
      Introduces EmitOptions for options passed to Compilation.Emit(). · 1621a00f
      TomasMatousek 提交于
           Moves options that were previously on CompilationOptions but were not used until emit phase to EmitOptions: fileAlignment, baseAddress, highEntropyVirtualAddressSpace, subsystemVersion, runtimeMetadataVersion. They hold on values written to various PE headers. We can now easily add other similar PE flags to EmitOptions, which is a common customer request, without affecting code that works with compilation options in other layers (workspaces, project system, etc.).
      
           Removes EmitMeadataOnly method and instead adds a MetadataOnly flag to EmitOptions. Removes MetadataOnlyEmitOptions - they were not used and can now be easily added as bools to EmitOptions.
      
           Moves pdbFilePath and outputName from parameters of Emit to EmitOptions.
      
      IDE: remove tracking of options that were moved to EmitOptions, since the IDE doesn't care about options that don't affect compilation. (changeset 1348623)
      1621a00f
  6. 06 10月, 2014 2 次提交
    • A
      Renamed the event and property accessor blocks to be consistent with each... · 601648f6
      ADGreen 提交于
      Renamed the event and property accessor blocks to be consistent with each other and the accessor statements they parent. (changeset 1348603)
      601648f6
    • A
      Refactors the DoLoopBlockSyntax kinds to be more useful to consumers.... · 2aa5c510
      ADGreen 提交于
      Refactors the DoLoopBlockSyntax kinds to be more useful to consumers. Specifically rather than merely identifying whether the loop has a top condition, bottom condition , or no condition, and requiring in the former two cases the caller to inspect the WhileOrUntilClause to determine how to interpret the condition this kind of the block now reflects this and which of the five forms a Do loop may take in VB. This is consistent with the pattern we use for MethodBlocks which have kinds aligned with the kinds of their method statements which are themselves aligned with the method keyword (i.e. Sub or Function). (changeset 1348593)
      2aa5c510