Q# 智能感知错误 [英] Q# Intellisense Errors
问题描述
我可以很好地构建我的 Q# 项目,但 VS 2017 (v. 15.9.4) 的智能感知错误代码 QS6103 为不存在具有该名称的命名空间".对于我下面显示的前两个打开"语句.我已经尝试过 SDK 和 Canon 的0.3.1811.1501"和0.3.1811.2802"版本.
I can build my Q# projects fine, but VS 2017 (v. 15.9.4) has the Intellisense errors code QS6103 of "No namespace with that name exists." for my first two "open" statements shown below. I have tried with both the "0.3.1811.1501" and "0.3.1811.2802" versions of the SDK and Canon.
namespace Quantum.QSharpApplication1
{
open Microsoft.Quantum.Primitive;
open Microsoft.Quantum.Canon;
operation HelloQ () : Unit {
Message("Hello quantum world!");
}
}
推荐答案
您安装了哪个版本的 .NET Core?(您可以使用 dotnet --version
进行检查)
What version of .NET Core do you have installed? (You can check using dotnet --version
)
我遇到了类似的问题,Q# IntelliSense 无法识别库命名空间,使用 .NET Core 2.1.500 和 2.1.403,但使用 2.1.402 它工作正常.不过我不得不卸载更高版本.
I ran into similar problems with Q# IntelliSense not recognizing library namespaces, with .NET Core 2.1.500 and 2.1.403, but with 2.1.402 it works fine. I had to uninstall the higher versions though.
这篇关于Q# 智能感知错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!