Re: [Vala] "Hello World", what is my mistake?
- From: Carlos Zuniga <carlos zun gmail com>
- To: vala-list gnome org
- Subject: Re: [Vala] "Hello World", what is my mistake?
- Date: Wed, 25 Apr 2012 20:29:16 -0500
On Wed, Apr 25, 2012 at 7:54 PM, live(vmars316) <vmars316 live com> wrote:
Greets,
I am compiling the hello.gs example @ https://live.gnome.org/Genie#Hello_World
Code:
init
print "Hello_World"
Pls, what am i doing wrong?
See error msg below:
C:\vala-0.12\vmVala>hello.gs.bat 1>hello.gs.bat.out.txt
hello.gs:2.9-2.13: error: syntax error, expected declaration but got `print' wi
th previous end of line
print "Hello_World"
^^^^^
Yes, Last line of code is “new line” symbol.
Can anyone give me an example of simple *.gs code that works?
Thanks...Vernon
Hi,
Are you using actual tabs for indentation? by default vala uses only
tabs. If you want spaces, try putting [indent=4] on the first line of
your file, meaning 4 spaces for indentation.
--
Carlos
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]