[antlr-interest] Problem with special characters in String_Literal of java.g

Jörg Rech joerg.rech at gmail.com
Fri Jul 1 15:11:53 PDT 2005


Hi,
  I encountered the following error when parsing motif_de.java (see 
below) from the java libraries:

motif_de.java:9:64: unexpected char: 'u'

I guess that STRING_LITERAL cannot parse the special character "\u00FC" 
even if it is defined in ESC.

Any ideas?
Joerg
----
motif_de.java:
----

package com.sun.java.swing.plaf.motif.resources;

import java.util.ListResourceBundle;

public final class motif_de extends ListResourceBundle {
    private static final Object[][] contents = {
        { "FileChooser.acceptAllFileFilterText", "*" },
        { "FileChooser.cancelButtonText", "Abbrechen" },
        { "FileChooser.cancelButtonToolTipText", "Dialogfeld f\u00FCr 
Dateiauswahl abbrechen" },
        { "FileChooser.enterFileNameLabelText", "Filternamen eingeben:" },
        { "FileChooser.filesLabelText", "Dateien" },
        { "FileChooser.filterLabelText", "Filter" },
        { "FileChooser.foldersLabelText", "Ordner" },
        { "FileChooser.helpButtonText", "Hilfe" },
        { "FileChooser.helpButtonToolTipText", "Hilfe f\u00FCr 
Dateiauswahl" },
        { "FileChooser.openButtonText", "OK" },
        { "FileChooser.openButtonToolTipText", "Ausgew\u00E4hlte Datei 
\u00F6ffnen" },
        { "FileChooser.openDialogTitleText", "\u00D6ffnen" },
        { "FileChooser.pathLabelText", "Pfad- oder Ordnernamen eingeben:" },
        { "FileChooser.saveButtonText", "Speichern" },
        { "FileChooser.saveButtonToolTipText", "Ausgew\u00E4hlte Datei 
speichern" },
        { "FileChooser.saveDialogTitleText", "Speichern" },
        { "FileChooser.updateButtonText", "Aktualisieren" },
        { "FileChooser.updateButtonToolTipText", "Verzeichnisliste 
aktualisieren" },

    };

    protected final Object[][] getContents() {
         return contents;
    }
}


-- 
Joerg Rech
Computer Scientist        Web:   http://www.joerg-rech.de
Tel.: (+49|0) 631/10653   email: joerg.rech at gmail.com



More information about the antlr-interest mailing list