This is the mail archive of the java-prs@gcc.gnu.org mailing list for the Java project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

libgcj/6131: Working with Sun's 1.4 jre



>Number:         6131
>Category:       libgcj
>Synopsis:       Working with Sun's 1.4 jre
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    unassigned
>State:          open
>Class:          support
>Submitter-Id:   net
>Arrival-Date:   Tue Apr 02 02:46:01 PST 2002
>Closed-Date:
>Last-Modified:
>Originator:     Paul Matthews
>Release:        2.96
>Organization:
>Environment:
Linux localhost.localdomain 2.4.3-20mdk #1 Sun Apr 15 23:03:10 CEST 2001 i686 unknown
>Description:
Really this is an "am I doing it right" question, followed 
by "does it work wiht a later version" question.

[cat]$rpm -qa | grep java
gcc-java-2.96-0.48mdk
[cat]$ rpm -qa | grep gcj
libgcj-2.96-2mdk
libgcj-devel-2.96-2mdk
 cat cat.java
import java.io.*;
import java.util.regex.*;
 
class cat
{
  public static void main( String args[] )
  {
    BufferedReader in = new BufferedReader(
                          new InputStreamReader(
                            System.in));
    BufferedWriter out = new BufferedWriter(
                           new OutputStreamWriter(
                             System.out));
    Pattern fs = Pattern.compile("\t");
    String record;
    String fields[];
    String field;
 
    try {
      while( true ) {
        record = in.readLine();
        if( record == null )
          break;
        field="";
        for(i=0;i<record.length();i++) {
        }
        fields = fs.split(record,0);
        out.write(record);
        out.newLine();
      }
      out.flush();
    }
    catch( IOException e ) {
    }
  }
}
export CLASSPATH=/opt/j2sdk1.4.0/jre/lib/rt.jar
[cat]$ gcj -o cat cat.java -lgcj
java/lang/String.java:0: bad value constant type 0, index 0
>How-To-Repeat:

>Fix:

>Release-Note:
>Audit-Trail:
>Unformatted:


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]