Warning: file_get_contents(/data/phpspider/zhask/data//catemap/8/visual-studio-code/3.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Visual studio code 在Visual Studio代码项目中访问本地生成的DLL_Visual Studio Code_Roslyn_.net Core - Fatal编程技术网

Visual studio code 在Visual Studio代码项目中访问本地生成的DLL

Visual studio code 在Visual Studio代码项目中访问本地生成的DLL,visual-studio-code,roslyn,.net-core,Visual Studio Code,Roslyn,.net Core,所以我让roslyn在我的MacOSX上做了一个文件夹 dotnet/roslyn/Binaries/Debug/cscore 这是我得到的文件列表 CommonNetCoreReferences_DoNotUse.dll* CommonNetCoreReferences_DoNotUse.pdb* Microsoft.CodeAnalysis.CSharp.dll* Microsoft.CodeAnalysis.CSharp.pdb* Microsoft.CodeAnalysis.CSharp

所以我让roslyn在我的MacOSX上做了一个文件夹
dotnet/roslyn/Binaries/Debug/cscore

这是我得到的文件列表

CommonNetCoreReferences_DoNotUse.dll*
CommonNetCoreReferences_DoNotUse.pdb*
Microsoft.CodeAnalysis.CSharp.dll*
Microsoft.CodeAnalysis.CSharp.pdb*
Microsoft.CodeAnalysis.CSharp.xml*
Microsoft.CodeAnalysis.dll*
Microsoft.CodeAnalysis.pdb*
Microsoft.CodeAnalysis.xml*
Microsoft.DiaSymReader.Native.amd64.dll*
Microsoft.DiaSymReader.Native.x86.dll*
Microsoft.Win32.Primitives.dll*
Microsoft.Win32.Registry.dll*
System.AppContext.dll*
System.Collections.Concurrent.dll*
System.Collections.Immutable.dll*
System.Collections.dll*
System.ComponentModel.DataAnnotations.dll*
System.Console.dll*
System.Core.dll*
System.Diagnostics.Debug.dll*
System.Diagnostics.FileVersionInfo.dll*
System.Diagnostics.Process.dll*
System.Diagnostics.StackTrace.dll*
System.Diagnostics.Tools.dll*
System.Diagnostics.Tracing.dll*
System.Dynamic.Runtime.dll*
System.Globalization.Calendars.dll*
System.Globalization.Native.dylib*
System.Globalization.dll*
System.IO.Compression.Native.dylib*
System.IO.Compression.dll*
System.IO.FileSystem.Primitives.dll*
System.IO.FileSystem.Watcher.dll*
System.IO.FileSystem.dll*
System.IO.Pipes.dll*
System.IO.dll*
System.Linq.Expressions.dll*
System.Linq.dll*
System.Native.a*
System.Native.dylib*
System.Net.Http.Native.dylib*
System.Net.NameResolution.dll*
System.Net.Primitives.dll*
System.Net.Sockets.dll*
System.Net.dll*
System.Numerics.dll*
System.ObjectModel.dll*
System.Private.CoreLib.dll*
System.Private.CoreLib.ni.dll*
System.Private.Uri.dll*
System.Reflection.Emit.ILGeneration.dll*
System.Reflection.Emit.Lightweight.dll*
System.Reflection.Emit.dll*
System.Reflection.Extensions.dll*
System.Reflection.Metadata.dll*
System.Reflection.Primitives.dll*
System.Reflection.TypeExtensions.dll*
System.Reflection.dll*
System.Resources.ResourceManager.dll*
System.Runtime.Extensions.dll*
System.Runtime.Handles.dll*
System.Runtime.InteropServices.RuntimeInformation.dll*
System.Runtime.InteropServices.dll*
System.Runtime.Loader.dll*
System.Runtime.Numerics.dll*
System.Runtime.Serialization.dll*
System.Runtime.dll*
System.Security.Claims.dll*
System.Security.Cryptography.Algorithms.dll*
System.Security.Cryptography.Cng.dll*
System.Security.Cryptography.Csp.dll*
System.Security.Cryptography.Encoding.dll*
System.Security.Cryptography.Native.dylib*
System.Security.Cryptography.OpenSsl.dll*
System.Security.Cryptography.Primitives.dll*
System.Security.Cryptography.X509Certificates.dll*
System.Security.Principal.Windows.dll*
System.Security.Principal.dll*
System.ServiceModel.Web.dll*
System.ServiceModel.dll*
System.Text.Encoding.CodePages.dll*
System.Text.Encoding.Extensions.dll*
System.Text.Encoding.dll*
System.Text.RegularExpressions.dll*
System.Threading.Overlapped.dll*
System.Threading.Tasks.Extensions.dll*
System.Threading.Tasks.Parallel.dll*
System.Threading.Tasks.dll*
System.Threading.Thread.dll*
System.Threading.ThreadPool.dll*
System.Threading.dll*
System.Windows.dll*
System.Xml.Linq.dll*
System.Xml.ReaderWriter.dll*
System.Xml.Serialization.dll*
System.Xml.XDocument.dll*
System.Xml.XPath.XDocument.dll*
System.Xml.XPath.dll*
System.Xml.XmlDocument.dll*
System.Xml.dll*
System.dll*
corerun*
csc*
csc.cmd
csc.exe*
csc.exe.config*
csc.pdb*
csc.xml*
libclrjit.dylib*
libcoreclr.dylib*
libdbgshim.dylib*
libmscordaccore.dylib*
libmscordbi.dylib*
libsos.dylib*
mscorlib.dll*
mscorlib.ni.dll*
pbcopy
sosdocsunix.txt*
现在如何在VisualStudio代码中使用它?
如何引用本地DLL?

.Net核心项目可以通过两种方式引用依赖项:

  • NuGet软件包
  • 项目间参考
  • 值得注意的是,缺少直接引用程序集

    这意味着您有两个选择:

  • 构建Roslyn NuGet包,将它们放入目录中,并使用.Net核心项目的NuGet.Config将该目录配置为包源。然后正常引用包
  • 使用global.json将相关的Roslyn项目作为解决方案的一部分,然后使用
    “target”:“project”
    将其引用为项目,而不是在project.json中指定包的版本

  • .Net核心项目可以通过两种方式引用依赖项:

  • NuGet软件包
  • 项目间参考
  • 值得注意的是,缺少直接引用程序集

    这意味着您有两个选择:

  • 构建Roslyn NuGet包,将它们放入目录中,并使用.Net核心项目的NuGet.Config将该目录配置为包源。然后正常引用包
  • 使用global.json将相关的Roslyn项目作为解决方案的一部分,然后使用
    “target”:“project”
    将其引用为项目,而不是在project.json中指定包的版本

  • 为了确保我理解正确,您想使用VS代码编写一个.Net核心项目,该代码将一些Roslyn DLL引用为库?是的。您完全正确为了确保我理解正确,您想使用VS代码编写一个.Net核心项目,将一些Roslyn DLL引用为库?是的。你说得很对。因此,缺少直接引用。有没有MS说过的链接?好的。因此,缺少直接引用。MS声明的任何链接?