1. 07 2月, 2015 5 次提交
  2. 06 2月, 2015 22 次提交
    • B
      Move Expression Evaluator to Open (changeset 1411117) · 6f53207a
      beep boop 提交于
      6f53207a
    • J
      Background: · ccb1afd7
      jaredpar 提交于
      As discussed in the dev team all hands all code under the GitHub dotnet foundation is using a single process for contribution, API review, infrastructure and coding style. The idea is to present a unified view to our customer and give them a single story for contributing to any project under the dotnet foundation.
      
      https://github.com/dotnet/corefx/wiki/Contributing#c-coding-style
      
      The coding style transition is automated using a Roslyn based rewrite tool:
      
      https://github.com/dotnet/codeformatter
      
      This will be applied in stages across our developer tree. Right now the focus is on the Open directory as this is what is being presented on github. Code owners will be contacted before the transition happens.
      
      Note: this is a soft style requirement. There are no build errors that come from this change. (changeset 1411068)
      ccb1afd7
    • T
      Warn if analyzers have dependencies with the same identity but different contents. · 04e4d15d
      tmeschter 提交于
      Consider what happens if you have two analyzers, A and B, that each depend on an assembly named C.
      
        Directory 1:
          A.dll
          C.dll
      
        Directory 2:
          B.dll
          C.dll
      
      If both copies of C have the same identity (name, version, culture, public key token, etc.) then only one of them is actually going to be loaded into VS. If both copies are identical then it doesn't matter, but if their contents differ the analyzers may not work the way they are supposed to or may fail outright.
      
      Here we attempt to let the user know that this might happen. Whenever an analyzer is added or removed we identify the transitive set of assemblies the analyzers' may load and identify assemblies that have the same identity. We then hash the file contents of these assemblies and compare. If they are different we surface a conflict in the Error List.
      
      In solutions with many different analyzers or dependencies this is a potentially expensive operation. To limit the impact on the system we only allow one of these operations to run at a time. If an analyzer is added or removed while a check is in progress we immediately signal for cancellation, wait for the existing task to finish up, and only then start the new one. (changeset 1411056)
      04e4d15d
    • T
      Enable the DeclarePublicAPI analyzer for VB projects · 9065cff1
      tmeschter 提交于
      When the DeclarePublicAPI analyzer was first put to use there were a couple of bugs in the compiler and IDE analyzer drivers for VB projects; this effectively limited the analyzer to C# projects. These have now been fixed, and it can be turned on for VB. (changeset 1411047)
      9065cff1
    • C
      Expose the compiler's helper to find ConditionalAccessExpressions at the... · 4045852b
      chandera 提交于
      Expose the compiler's helper to find ConditionalAccessExpressions at the Workspace layer. 1113971 tracks making this a public API in the compiler. (changeset 1411035)
      4045852b
    • C
      DescriptionModifyingCompletionItem should use the default task scheduler when... · fcac7546
      chandera 提交于
      DescriptionModifyingCompletionItem should use the default task scheduler when computing the snippet text. Use of "TaskScheduler.Current" will deadlock if the UI thread is blocking waiting for a description."TaskScheduler.Current" would deadlock if the UI thread was blocking waiting for a description.
      
      Note that this was previously checked into Dev14CTP as changeset 1350549 but somehow didn't get included when that branch RIed to Roslyn\Main. (changeset 1410908)
      fcac7546
    • A
    • T
    • V
      Fix bug 1042696. Changing shape of syntax nodes representing XML document... · 81f86053
      vladres 提交于
      Fix bug 1042696. Changing shape of syntax nodes representing XML document literals, as was planned initially, proved to be risky and time-consuming approach. After discussing this issue with KevinPi, I decided to apply a simpler fix on the compiler side (basically, a rollback of the changeset 1071554 that introduced this breaking change -- approved by the triage at that time). With this fix, the trailing whitespace is accepted and parsed as trailing trivia on the last token in the XML document. This fixes the compat break in the compiler, and extends the set of valid VB programs. But it requires reactivating IDE bug 602208, because some of the newly valid programs are not automatically supported by all refactorings (nothing that was previously working is being broken by this changeset - it just was OK that those programs were not supported because they were invalid). (changeset 1410876)
      81f86053
    • S
      This change addresses five issues around light bulb preview pane - · bbcf7241
      shyamn 提交于
      1. Stop displaying superfluous 'No Preview' under the header section of the preview pane for fixes such as 'rename tracking' and 'generate type dialog' that don't provide any visual preview.
      
      2. Make preview pane header font use the VS 'Environment' font settings so that user can change /scale the font.
      
      3. We were not displaying the preview header in the case of hidden diagnostics (which don't show up in the error list) - start displaying the header for hidden diagnostics (except if the diagnostic is a 'trigger' diagnostic).
      
      4. Disable tab stop / focus in the code diff view portion of the preview pane. When using keyboard, we were allowing user to stop in the diff view portion - this ended up causing confusion since we would display a blinking cursor in the code diff view portion giving users the impression that they could type something there.
      
      5. Set Focusable=true on the preview pane control. Light bulb checks for this before shifting keyboard focus to the preview pane in the case where there are no 'flavored' actions under the preview pane (such as 'Preview Changes' and 'Fix All Occurrences'). (changeset 1410707)
      bbcf7241
    • T
      Change MetadataReferenceProperties.Aliases to never return default array. · 663995d6
      TomasMatousek 提交于
      Makes it easier to use the property and fixes a couple of bugs, where the code didn't check for either IsDefault or IsEmpty. Now all use-sites just need to check for IsEmpty.
      
      Fixes 1119812. (changeset 1410494)
      663995d6
    • H
      rollback DiagnosticData.cs · 4671249e
      heejaechang 提交于
      the file belongs to different changes accidentally got checked in with telemetry change
      
      I rolling back the change. (changeset 1410406)
      4671249e
    • H
      call data type specific API for VS telemetry · e6775635
      heejaechang 提交于
      VS telemetry now has data type specific APIs that can be used to reprot various data type to server. once used, data can be manipulated better by reporting side. (changeset 1410375)
      e6775635
    • D
      Two dialog improvements: · afaec75e
      dpoeschl 提交于
      - Explicitly set HasDialogFrame="True" in all dialogs to maintain current behavior when the platform changes the default to False.
      - Add a resize grip to the GenerateType dialog (changeset 1410362)
      afaec75e
    • J
      Remove CopyLocal from Microsoft.VisualStudio.Composition.Configuration... · 035fe505
      jasonmalinowski 提交于
      Remove CopyLocal from Microsoft.VisualStudio.Composition.Configuration references (changeset 1410325)
      035fe505
    • M
      Skip failing CompilerServer test. (changeset 1410313) · 076b5679
      manishv 提交于
      076b5679
    • A
      Remove traces of ErrorListDiagnostics.csproj from Roslyn.sln. · f8aa8d55
      angocke 提交于
      The project wasn't fully removed from the solution so NuGet restore
      complained about the project not existing when run on the solution. (changeset 1410281)
      f8aa8d55
    • B
      Add an unit test for an extract method bug that is no longer reproducible. The... · cc239acc
      BalajiKris 提交于
      Add an unit test for an extract method bug that is no longer reproducible. The bug was that extracting an expression from yield return statement did not work. (changeset 1410266)
      cc239acc
    • T
      PDB import scopes refactoring. · 2e2e8ee8
      TomasMatousek 提交于
      Changes:
      
      To enable producing both Portable and native PDB formats we need to move the format specific imports encoding down to the PdbWriter. Instead of constructing NamespaceScope objects containing strings that encode usings/imports the C# and VB constructs that hold on to bound imports (ImportChain in C#, SourceFile in VB) now implement a new CCI-level interface IImportScope that provides an array of UsedTypeOrNamespace for each import scope. UsedTypeOrNamespace struct now doesn’t contain strings but symbols that represent the entities that re referenced in usings/Imports. IImportScope only represents imports on file level and below. Project level imports are exposed via new API on Cci.IModule (GetImports method). To represent a namespace a new CCI-level interface INamespace is introduced and implemented by NamespaceSymbol. In future we could replace usage of qualified namespace strings with this interface in other places in the compiler-CCI interface, but to minimize the impact I have not done so in this change.
      
      Background:
      
      Currently C# and VB compilers build a list of namespace scopes in NamespaceScopeBuilder that are then passed via MethodBody to the MetadataWriter, which then passes them to the PdbWriter. The NamespaceScopeBuilder encodes various forms of usings, extern aliases and imports in specially formatted strings that the EE understands how to decode. It constructs a list of all usings/imports/extern-aliases/etc. for each method. The PdbWriter then writes these string lists to PDB namespace scope records and implements a forwarding optimization – within a set of methods that have the same usings we designate one that we associate the strings with and the others forward to it. The forwarding is implemented differently by VB and C#. VB also defines some additional namespace scope records for default namespace, NoPia assembly names and method namespace.
      
      The new portable PDB format has a different, simpler and more efficient representation of import scopes with the same encoding for C# and VB. Import scopes are first class entities that have parent pointer and thus form a tree. The structure of the tree is language specific. The root of the tree represents a project/compilation-wide import scope. For C# this scope contains assembly reference aliases (/r:Alias=Reference.dll). For VB this scope declares project level imports. The import scope tree for VB is 2 level deep – file level and project level. C# may define deeper trees as namespaces may define their own usings.
      Also some information that Dev12 encodes in PDB namespace scopes is not used anymore by our new EEs (such as VB NoPia names, VB method namespace). These are not emitted to Portable PDB since the old EEs won’t be able to consume the new format anyways.
       (changeset 1410225)
      2e2e8ee8
    • T
    • T
      fb432a32
    • T
      When adding an analyzer, warn if an older version of the assembly has already been loaded. · 89de8217
      tmeschter 提交于
      If an analyzer assembly changes on disk after it has been loaded in VS we put a warning in the Error List letting the user know that they will need to restart VS to use the new version. We do not, however, warn the user in the situation where they add an analyzer to a project but an older version of that file has already been loaded.
      
      This change updates the AnalyzerFileWatcherService to record the creation/modification time when it sees an analyzer assembly being loaded. Later, when an analyzer is added to a project we check if the current creation/modification time of the file matches the recorded time; if it does not, the file does not currently match what was loaded and we need to raise the warning.
      
      We also now tell the AnalyzerFileWatcherService when an analyzer is removed so that the corresponding warnings can be removed from the Error List. (changeset 1410175)
      89de8217
  3. 05 2月, 2015 3 次提交
  4. 04 2月, 2015 10 次提交
    • J
      50db6c33
    • V
      Change path utilities and command line parser to work on Unix-like platforms. · 622b8ae0
      VSadov 提交于
      For the most part the path utilities were already intended to accept '/' and '\' as path separators when appropriate, as well as to accept  '/' and '-' as option tokens
      There were however some missed cases related to the handling of the rooted absolute paths
      When we get a path like /home/joe/test.cs  , we do not want to treat it as a compiler option.
      
      ***NO_CI***
       (changeset 1409887)
      622b8ae0
    • J
      Fix empty array tests in Jenkins · f69ac51b
      jaredpar 提交于
      While our internal runtime contains the new Array.Empty member, the runtime used by tests in Jenkins does not.  This caused the Jenkins tests to begin to fail once we updated our empty array suites to always expect the member to be present.  I changed the suites to test for the member and change their behavior based in its presence or absence.
      
       (changeset 1409795)
      f69ac51b
    • J
      The CreateInstanceAndUnwrap call below is failing somewhat randomly in our... · 4ab155a8
      jaredpar 提交于
         The CreateInstanceAndUnwrap call below is failing somewhat randomly in our test runs with an error claiming it can't load Roslyn.Test.Utilities.  So far we've been unable to actually catch this failure under a debugger because as previously stated the failure is random.  The only interesting data we have is that it's much more likely to fail in xUnit2 parallel mode than xUnit1.
      
           Looking at the code there seems to be an obvious explanation.  The Environment.CurrentDirectory value becomes the resolver path for the newly created AppDomain instance.  If this value doesn't point to the test binaries directory then it would explain the failure.  This is a process wide value that can easily be changed by other code.  Even if the code is careful to reset the value afterwards the intermediate value would be visible across AppDomains and cause this problem.
      
           A more stable value is AppDomain.CurrentDomain.BaseDirectory.  This value is AppDomain specific, immutable, and was already sufficient to load this particular assembly.
       (changeset 1409768)
      4ab155a8
    • B
      Move a few more projects to Open (changeset 1409682) · 9c1de4ac
      beep boop 提交于
      9c1de4ac
    • N
    • B
      Fix Bug 1070773 - option... · 131c88d6
      Basoundr_ms 提交于
      Fix Bug 1070773  - option "NewLinesForBracesInObjectCollectionArrayInitializers" will handle Collection, Array and Object Initializers
      
      Changing the New Line option "NewLinesForBracesInObjectInitializers" to "NewLinesForBracesInObjectCollectionArrayInitializers" which will now affect Collection Initializer and Array Initializers in addition to Object Initializers. Check Bug 853748 regarding this.
      
      This change does not affect the Custom formatted Array Initializers and Collection Initializers since we have appropriate Suppress operation. (changeset 1409656)
      131c88d6
    • A
      DevDiv #1112908: Not-yet-loaded assemblies · ddf216a3
      acasey 提交于
      When the expression compiler sees a diagnostic indicating that a reference should be added to the compilation, it should invoke DkmClrAppDomain.LoadAssembly so that the debugger can try to load and then re-invoke the expression compiler.
      
      TODO: Make this work for WinMDs (1114866).
      
      CR: ChuckS; KevinH; VladRes; PaNelson (changeset 1409642)
      ddf216a3
    • B
      Fix Bug 1087167 - Format AttributeLists of a parameter appropriately · 1a2a566a
      Basoundr_ms 提交于
      AttributeLists of the Parameter should be left untouched by the VB PrettyLister. The AttributeLists of the other statement is formatted in such way that the first attributeList of the lot is formatted with expected indentation and the rest of the attributeList anchors to the first attributeList and moves accordingly. (changeset 1409606)
      1a2a566a
    • C
      Pass the IsCaseSensitive flag along to VS' NavigateTo subsystem. · f1794d64
      cyrusn 提交于
      This will ensure that case sensitive matches are placed above insensitive ones in the NavigateTo results list.
      ***NO_CI***
       (changeset 1409531)
      f1794d64