<legend id='IdcYO'><style id='IdcYO'><dir id='IdcYO'><q id='IdcYO'></q></dir></style></legend>
  • <tfoot id='IdcYO'></tfoot>

    <small id='IdcYO'></small><noframes id='IdcYO'>

      1. <i id='IdcYO'><tr id='IdcYO'><dt id='IdcYO'><q id='IdcYO'><span id='IdcYO'><b id='IdcYO'><form id='IdcYO'><ins id='IdcYO'></ins><ul id='IdcYO'></ul><sub id='IdcYO'></sub></form><legend id='IdcYO'></legend><bdo id='IdcYO'><pre id='IdcYO'><center id='IdcYO'></center></pre></bdo></b><th id='IdcYO'></th></span></q></dt></tr></i><div id='IdcYO'><tfoot id='IdcYO'></tfoot><dl id='IdcYO'><fieldset id='IdcYO'></fieldset></dl></div>
          <bdo id='IdcYO'></bdo><ul id='IdcYO'></ul>
      2. .net 中未使用的用法会影响性能吗?

        Do unused usings in .net affect performance?(.net 中未使用的用法会影响性能吗?)
          • <bdo id='vKlFt'></bdo><ul id='vKlFt'></ul>
          • <tfoot id='vKlFt'></tfoot>

            <small id='vKlFt'></small><noframes id='vKlFt'>

              <tbody id='vKlFt'></tbody>

                  <i id='vKlFt'><tr id='vKlFt'><dt id='vKlFt'><q id='vKlFt'><span id='vKlFt'><b id='vKlFt'><form id='vKlFt'><ins id='vKlFt'></ins><ul id='vKlFt'></ul><sub id='vKlFt'></sub></form><legend id='vKlFt'></legend><bdo id='vKlFt'><pre id='vKlFt'><center id='vKlFt'></center></pre></bdo></b><th id='vKlFt'></th></span></q></dt></tr></i><div id='vKlFt'><tfoot id='vKlFt'></tfoot><dl id='vKlFt'><fieldset id='vKlFt'></fieldset></dl></div>
                  <legend id='vKlFt'><style id='vKlFt'><dir id='vKlFt'><q id='vKlFt'></q></dir></style></legend>

                  本文介绍了.net 中未使用的用法会影响性能吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着跟版网的小编来一起学习吧!


                  为什么要删除不必要的 C# using 指令?
                  未使用的 using 语句对性能有何影响

                  c# 中未使用的用法会影响运行时性能吗?如果是,怎么做?

                  Do unused usings in c# affect runtime performance? If yes, How do so?

                  using System;
                  using System.Collections.Generic;
                  using System.ComponentModel; -----//Unused
                  using System.Data;---------------//Unused
                  using System.Drawing;-----------//Unused
                  using System.Text;-------------//Unused
                  using System.Windows.Forms;
                  using System.Threading;------//Unused
                  using System.Linq;----------//Unused
                  using System.IO;-----------//Unused
                  using System.Diagnostics;-//Unused
                  using System.Data.OleDb;
                  using OBID; 


                  不会,但是会影响IDE性能和项目的编译过程.我可以给你一个简短的例子.如果你曾经使用过 coderush http://devexpress.com/Products/Visual_Studio_Add-in/Coding_Assistance/ 来自 devexpress,他们的 IDE 优化器和代码优化器也会建议您删除未使用的命名空间.

                  NO, but It effects the IDE performance and the compilation process of your project. I can give you a short example. If you have ever used coderush http://devexpress.com/Products/Visual_Studio_Add-in/Coding_Assistance/ which is from devexpress, their IDE optimizer and code optimizer will also suggest you to remove unused namespaces.

                  更新:这是来自 Dmitriy 博客的更多使用信息您应该删除 C# 代码中未使用的用法的原因很少.

                  Update: Here is more use information from Dmitriy's Blog There are few reasons why you should remove unused usings in you C# code.

                  It is useless code, that just creates clutter in your source code and it also confusing for the developer because you don’t know which namespaces are actually used.
                  Over time as your code changes it can accumulate a lot of unused using statements which create even more clutter in you code.
                  It can make your compiling faster, since compiler does not have to look up all those extra unused namespaces.
                  It will help avoid name conflict with new items that you going to add to your solution if both of those have same names.
                  It will reduce number of items in your Visual Studio editor auto completion


                  There are couple ways to remove those unused usings, you can do it individually on each file


                  您还可以下载名为 batchFormat for Visual Studio 2010 的插件,它可以帮助您删除整个项目中所有未使用的用途.

                  You also can download plugin called batchFormat for Visual Studio 2010 that can help you to remove all unused usings for the whole project.


                  这篇关于.net 中未使用的用法会影响性能吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!



                  C# namespace alias - what#39;s the point?(C# 命名空间别名 - 有什么意义?)
                  Using Xpath With Default Namespace in C#(在 C# 中使用具有默认命名空间的 Xpath)
                  IBM.Data.DB2.Core connection problems(IBM.Data.DB2.Core 连接问题)
                  Generating an EDMX from a DB2 Database(从 DB2 数据库生成 EDMX)
                  Datetime field overflow with IBM Data Server Client v9.7fp5(IBM Data Server Client v9.7fp5 的日期时间字段溢出)
                  Using entity Framework with .NET Core and DB2(将实体框架与 .NET Core 和 DB2 结合使用)
                  <legend id='nBXuD'><style id='nBXuD'><dir id='nBXuD'><q id='nBXuD'></q></dir></style></legend>

                        <tbody id='nBXuD'></tbody>
                        <bdo id='nBXuD'></bdo><ul id='nBXuD'></ul>
                      • <i id='nBXuD'><tr id='nBXuD'><dt id='nBXuD'><q id='nBXuD'><span id='nBXuD'><b id='nBXuD'><form id='nBXuD'><ins id='nBXuD'></ins><ul id='nBXuD'></ul><sub id='nBXuD'></sub></form><legend id='nBXuD'></legend><bdo id='nBXuD'><pre id='nBXuD'><center id='nBXuD'></center></pre></bdo></b><th id='nBXuD'></th></span></q></dt></tr></i><div id='nBXuD'><tfoot id='nBXuD'></tfoot><dl id='nBXuD'><fieldset id='nBXuD'></fieldset></dl></div>

                        <small id='nBXuD'></small><noframes id='nBXuD'>

                        <tfoot id='nBXuD'></tfoot>