Win a copy of Design for the Mind this week in the Design forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

What is the differenca

 
Krupa Kumar
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Can some one explain the difference between the following two options?
1. This code does not compile
2. Compiles, but generates compiler error.
Regards
Krupa
 
Junilu Lacar
Bartender
Pie
Posts: 7465
50
Android Eclipse IDE IntelliJ IDE Java Linux Mac Scala Spring Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Are you sure about #2? If a compiler error is generated, the code couldn't have compiled successfully. Maybe you mean "but generates a runtime error (or exception)"
J.Lacar
[This message has been edited by JUNILU LACAR (edited March 03, 2001).]
 
Manfred Leonhardt
Ranch Hand
Posts: 1492
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I think the difference is:
1. No output *.class file is created
2. May be warnings (errors in java) but *.class will be created.
I think warnings in Java compilers are considered errors.
Some examples include deprecated method warnings, bad access modifiers ...
Regards,
Manfred.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic