aspose file tools*
The moose likes Programmer Certification (SCJP/OCPJP) and the fly likes Forward reference Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Certification » Programmer Certification (SCJP/OCPJP)
Bookmark "Forward reference" Watch "Forward reference" New topic
Author

Forward reference

Michael Angstadt
Ranch Hand

Joined: Jun 17, 2009
Posts: 274

YES THIS MAKES TOTAL SENSE. GO SUN.


SCJP 6 || SCWCD 5
Henry Wong
author
Sheriff

Joined: Sep 28, 2004
Posts: 18977
    
  40

Michael Angstadt wrote:YES THIS MAKES TOTAL SENSE. GO SUN.


Yea. The compiler is not very good in this regard. It can be tricked easily by using a reference.

Henry


Books: Java Threads, 3rd Edition, Jini in a Nutshell, and Java Gems (contributor)
Michael Angstadt
Ranch Hand

Joined: Jun 17, 2009
Posts: 274

It just seems like it would make more sense just to not allow a field to be used at all until it is declared. But who knows.
Jesper de Jong
Java Cowboy
Saloon Keeper

Joined: Aug 16, 2005
Posts: 14338
    
  22

The Java programming language was originally designed to be appealing to C++ programmers, and so it inherited large parts of its syntax and semantics from C++, where it probably works in a similar way.


Java Beginners FAQ - JavaRanch SCJP FAQ - The Java Tutorial - Java SE 8 API documentation
Ninad Kulkarni
Ranch Hand

Joined: Aug 31, 2007
Posts: 802

Hi Michael,
You can find forward reference in JLS. See JLS


SCJP 5.0 - JavaRanch FAQ - Java Beginners FAQ - SCJP FAQ - SCJP Mock Tests - Tutorial - JavaSE7 - JavaEE6 -Generics FAQ - JLS - JVM Spec - Java FAQs - Smart Questions
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Forward reference