试图列出一个清单:名字“Gee”;不存在
我正在尝试在 Genie 中列出一个列表,但似乎不起作用。编译代码:
[indent=2]
init
var l = new list of string
产生以下错误:
someone@someone-UBook:~/Documents$ valac helloworld.gs helloworld.gs:2.10-2.24: error: The name `Gee' does not exist in the context of `main'
var l = new list of int
^^^^^^^^^^^^^^^
helloworld.gs:2.8-2.24: error: var declaration not allowed with non-typed initializer
var l = new list of int
^^^^^^^^^^^^^^^^^
Compilation failed: 2 error(s), 0 warning(s)
我已经安装了 libgee2 (通过 sudo apt-get install libgee2)并且没有任何变化。有什么想法吗?
I'm trying to make a list in Genie and it doesn't seem to work. Compiling the code:
[indent=2]
init
var l = new list of string
produces these errors:
someone@someone-UBook:~/Documents$ valac helloworld.gs helloworld.gs:2.10-2.24: error: The name `Gee' does not exist in the context of `main'
var l = new list of int
^^^^^^^^^^^^^^^
helloworld.gs:2.8-2.24: error: var declaration not allowed with non-typed initializer
var l = new list of int
^^^^^^^^^^^^^^^^^
Compilation failed: 2 error(s), 0 warning(s)
I've installed libgee2 (via sudo apt-get install libgee2) and nothing changes. Any ideas?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您还需要安装 libgee 的开发包(apt-get install libgee-dev)并告诉 valac 使用它(将 --pkg gee-0.8 添加到您的 valac 参数中)。
You also need to install the development package for libgee (apt-get install libgee-dev) and tell valac to use it (add --pkg gee-0.8 to your valac arguments).