Re: Problems compiling with jikes (escaping backslash)

From: Chuck Hill (chil..lobal-village.net)
Date: Wed Jun 04 2003 - 13:47:39 EDT

  • Next message: Chuck Hill: "Generating EOs from an EOModel"

    That builds fine for me with jikes 1.15. Check your source carefully.
    Look very carefully. Have you perhaps typed something like:

    int i = aString.lastIndexOf('\\");
    int i = aString.lastIndexOf("\\'');

    Note '' or ' instead of ". It is easy to miss if you are not looking for it.

    If you have copied and pasted this line, try deleted them (along with the
    ones before and after) and retyping them hand. You might have a funny
    character in there.

    Chuck

    At 12:20 PM 04/06/2003 +0200, Brook, James wrote:
    >I am using Project Wonder style ant builds to build my suite of WebObjects
    >applications on Mac OS X.
    >
    >Whenever I try to escape a backslash in a String, I get compiler errors.
    >
    >For example the line:
    >
    > int i = aString.lastIndexOf("\\");
    >
    >causes this error:
    >
    > Lexical: String constant not properly terminated.
    > Lexical: illegal token.
    > ...and various subsequent errors.
    >
    >I have searched all over the web and various lists and can find no
    >explanation. I can escape other characters (eg. \n, or unicode escapes).
    >
    >The code compiles fine when I use javac. Has anyone else seen this?
    >
    >
    >
    >James Brook
    >

    --
    

    Chuck Hill chil..lobal-village.net Global Village Consulting Inc. http://www.global-village.net



    This archive was generated by hypermail 2.0.0 : Wed Jun 04 2003 - 13:45:46 EDT