This week's book giveaway is in the Clojure forum.
We're giving away four copies of Clojure in Action and have Amit Rathore and Francis Avila on-line!
See this thread for details.
Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Inner Class Error

 
Betty Reynolds
Ranch Hand
Posts: 111
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Can anyone tell me why the compiler does not like the last sysout statement in the code below?
 
Jesper Ottosson
Ranch Hand
Posts: 51
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
because it's not enclosed in any method
 
Betty Reynolds
Ranch Hand
Posts: 111
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm already aware that if you put the sysout statement in a block or a method that it will compile, so maybe I should rephrase the question. Are the only statements allowed outside of blocks/methods declarations and assignments? If not, what other statements are allowed?
Please disregard this post. I think I now understand the class coding constraints.
[This message has been edited by Betty Reynolds (edited March 26, 2000).]
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic