public inbox for java-prs@sourceware.org
help / color / mirror / Atom feed
* [Bug java/40590] New: namespace namespace broken in CNI
@ 2009-06-29 16:11 aph at gcc dot gnu dot org
2009-06-29 16:12 ` [Bug java/40590] " aph at gcc dot gnu dot org
` (3 more replies)
0 siblings, 4 replies; 5+ messages in thread
From: aph at gcc dot gnu dot org @ 2009-06-29 16:11 UTC (permalink / raw)
To: java-prs
gcj does not mangle names correctly.
In particular, when a member name is a C++ keyword, "$" is appended to the
name. However, this is results in an illegal mangled name so it is not
possible to refer to the member from CNI code.
Also, the set of C++ keywords in gjavah is different from the set in gcj.
Also, types are not checked for C++ keywords, so javax.xml.namespace.* cannot
be referenced from CNI code.
--
Summary: namespace namespace broken in CNI
Product: gcc
Version: 4.4.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: java
AssignedTo: aph at gcc dot gnu dot org
ReportedBy: aph at gcc dot gnu dot org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40590
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug java/40590] namespace namespace broken in CNI
2009-06-29 16:11 [Bug java/40590] New: namespace namespace broken in CNI aph at gcc dot gnu dot org
@ 2009-06-29 16:12 ` aph at gcc dot gnu dot org
2009-06-29 16:26 ` aph at gcc dot gnu dot org
` (2 subsequent siblings)
3 siblings, 0 replies; 5+ messages in thread
From: aph at gcc dot gnu dot org @ 2009-06-29 16:12 UTC (permalink / raw)
To: java-prs
------- Comment #1 from aph at gcc dot gnu dot org 2009-06-29 16:12 -------
See the thread at http://gcc.gnu.org/ml/java/2009-06/msg00066.html
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40590
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug java/40590] namespace namespace broken in CNI
2009-06-29 16:11 [Bug java/40590] New: namespace namespace broken in CNI aph at gcc dot gnu dot org
2009-06-29 16:12 ` [Bug java/40590] " aph at gcc dot gnu dot org
@ 2009-06-29 16:26 ` aph at gcc dot gnu dot org
2009-06-29 17:51 ` aph at gcc dot gnu dot org
2009-06-30 9:59 ` aph at gcc dot gnu dot org
3 siblings, 0 replies; 5+ messages in thread
From: aph at gcc dot gnu dot org @ 2009-06-29 16:26 UTC (permalink / raw)
To: java-prs
------- Comment #2 from aph at gcc dot gnu dot org 2009-06-29 16:26 -------
Created an attachment (id=18093)
--> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=18093&action=view)
Test case
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40590
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug java/40590] namespace namespace broken in CNI
2009-06-29 16:11 [Bug java/40590] New: namespace namespace broken in CNI aph at gcc dot gnu dot org
2009-06-29 16:12 ` [Bug java/40590] " aph at gcc dot gnu dot org
2009-06-29 16:26 ` aph at gcc dot gnu dot org
@ 2009-06-29 17:51 ` aph at gcc dot gnu dot org
2009-06-30 9:59 ` aph at gcc dot gnu dot org
3 siblings, 0 replies; 5+ messages in thread
From: aph at gcc dot gnu dot org @ 2009-06-29 17:51 UTC (permalink / raw)
To: java-prs
------- Comment #3 from aph at gcc dot gnu dot org 2009-06-29 17:51 -------
Subject: Bug 40590
Author: aph
Date: Mon Jun 29 17:50:59 2009
New Revision: 149059
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=149059
Log:
2009-06-29 Andrew Haley <aph@redhat.com>
PR java/40590
* tools/gnu/classpath/tools/javah/FieldHelper.java (print):
Use printName().
* tools/gnu/classpath/tools/javah/MethodHelper.java (print):
Use printName().
* tools/gnu/classpath/tools/javah/CniStubPrinter.java (printDecl):
Use printName().
* tools/gnu/classpath/tools/javah/Keywords.java (words): Replace
with keywords list from gcc/java/mangle.c.
* tools/gnu/classpath/tools/javah/ClassWrapper.java (printMethods):
Don't pre-convert a C++ keyword.
(print(CniPrintStream)): Call CniPrintStream.printName().
(printContents): Likewise.
* tools/gnu/classpath/tools/javah/CniPrintStream.java
(getClassName): Don't call replaceAll("/", "::").
(print(Type)): Add ""::" befor name, " *" after. Use printName(), not
print.
(printName(PrintStream, String), printName(String), printlnName):
New methods.
(moveToPackage): Use printName().
2009-06-29 Andrew Haley <aph@redhat.com>
PR java/40590
* java-tree.h (cxx_keyword_p): New declaration.
* mangle_name.c (utf8_cmp): Move here from mangle.c.
(cxx_keywords): Likewise.
(cxx_keyword_p): Likewise.
(MANGLE_CXX_KEYWORDS): New macro.
(append_gpp_mangled_name): Use MANGLE_CXX_KEYWORDS.
(append_gpp_mangled_name): Likewise.
* mangle.c: Move code to mangle_name.c.
(mangle_member_name): Don't call cxx_keyword_p.
Modified:
trunk/gcc/java/ChangeLog
trunk/gcc/java/java-tree.h
trunk/gcc/java/mangle.c
trunk/gcc/java/mangle_name.c
trunk/libjava/classpath/ChangeLog
trunk/libjava/classpath/tools/classes/gnu/classpath/tools/javah/ClassWrapper.class
trunk/libjava/classpath/tools/classes/gnu/classpath/tools/javah/CniPrintStream.class
trunk/libjava/classpath/tools/classes/gnu/classpath/tools/javah/CniStubPrinter.class
trunk/libjava/classpath/tools/classes/gnu/classpath/tools/javah/FieldHelper.class
trunk/libjava/classpath/tools/classes/gnu/classpath/tools/javah/Keywords.class
trunk/libjava/classpath/tools/classes/gnu/classpath/tools/javah/MethodHelper.class
trunk/libjava/classpath/tools/gnu/classpath/tools/javah/ClassWrapper.java
trunk/libjava/classpath/tools/gnu/classpath/tools/javah/CniPrintStream.java
trunk/libjava/classpath/tools/gnu/classpath/tools/javah/CniStubPrinter.java
trunk/libjava/classpath/tools/gnu/classpath/tools/javah/FieldHelper.java
trunk/libjava/classpath/tools/gnu/classpath/tools/javah/Keywords.java
trunk/libjava/classpath/tools/gnu/classpath/tools/javah/MethodHelper.java
trunk/libjava/gnu/xml/stream/AttributeImpl.h
trunk/libjava/gnu/xml/stream/EndElementImpl.h
trunk/libjava/gnu/xml/stream/StartElementImpl.h
trunk/libjava/gnu/xml/stream/XIncludeFilter.h
trunk/libjava/gnu/xml/stream/XMLEventFactoryImpl.h
trunk/libjava/gnu/xml/stream/XMLEventImpl.h
trunk/libjava/gnu/xml/stream/XMLEventWriterImpl.h
trunk/libjava/gnu/xml/stream/XMLParser.h
trunk/libjava/gnu/xml/stream/XMLStreamWriterImpl.h
trunk/libjava/gnu/xml/transform/AbstractNumberNode.h
trunk/libjava/gnu/xml/transform/ApplyImportsNode.h
trunk/libjava/gnu/xml/transform/ApplyTemplatesNode.h
trunk/libjava/gnu/xml/transform/AttributeNode.h
trunk/libjava/gnu/xml/transform/Bindings.h
trunk/libjava/gnu/xml/transform/CallTemplateNode.h
trunk/libjava/gnu/xml/transform/ChooseNode.h
trunk/libjava/gnu/xml/transform/CommentNode.h
trunk/libjava/gnu/xml/transform/CopyNode.h
trunk/libjava/gnu/xml/transform/CopyOfNode.h
trunk/libjava/gnu/xml/transform/CurrentFunction.h
trunk/libjava/gnu/xml/transform/DocumentFunction.h
trunk/libjava/gnu/xml/transform/ElementAvailableFunction.h
trunk/libjava/gnu/xml/transform/ElementNode.h
trunk/libjava/gnu/xml/transform/ForEachNode.h
trunk/libjava/gnu/xml/transform/FormatNumberFunction.h
trunk/libjava/gnu/xml/transform/FunctionAvailableFunction.h
trunk/libjava/gnu/xml/transform/GenerateIdFunction.h
trunk/libjava/gnu/xml/transform/IfNode.h
trunk/libjava/gnu/xml/transform/Key.h
trunk/libjava/gnu/xml/transform/KeyFunction.h
trunk/libjava/gnu/xml/transform/LiteralNode.h
trunk/libjava/gnu/xml/transform/MessageNode.h
trunk/libjava/gnu/xml/transform/OtherwiseNode.h
trunk/libjava/gnu/xml/transform/ParameterNode.h
trunk/libjava/gnu/xml/transform/ProcessingInstructionNode.h
trunk/libjava/gnu/xml/transform/SortKey.h
trunk/libjava/gnu/xml/transform/Stylesheet.h
trunk/libjava/gnu/xml/transform/SystemPropertyFunction.h
trunk/libjava/gnu/xml/transform/Template.h
trunk/libjava/gnu/xml/transform/TemplateNode.h
trunk/libjava/gnu/xml/transform/TextNode.h
trunk/libjava/gnu/xml/transform/TransformerImpl.h
trunk/libjava/gnu/xml/transform/UnparsedEntityUriFunction.h
trunk/libjava/gnu/xml/transform/ValueOfNode.h
trunk/libjava/gnu/xml/transform/WhenNode.h
trunk/libjava/gnu/xml/transform/WithParam.h
trunk/libjava/gnu/xml/validation/datatype/AtomicSimpleType.h
trunk/libjava/gnu/xml/validation/datatype/ListSimpleType.h
trunk/libjava/gnu/xml/validation/datatype/SimpleType.h
trunk/libjava/gnu/xml/validation/datatype/Type.h
trunk/libjava/gnu/xml/validation/datatype/UnionSimpleType.h
trunk/libjava/gnu/xml/validation/xmlschema/AttributeDeclaration.h
trunk/libjava/gnu/xml/validation/xmlschema/ComplexType.h
trunk/libjava/gnu/xml/validation/xmlschema/ElementDeclaration.h
trunk/libjava/gnu/xml/validation/xmlschema/XMLSchemaBuilder.h
trunk/libjava/gnu/xml/xpath/AndExpr.h
trunk/libjava/gnu/xml/xpath/ArithmeticExpr.h
trunk/libjava/gnu/xml/xpath/BooleanFunction.h
trunk/libjava/gnu/xml/xpath/CeilingFunction.h
trunk/libjava/gnu/xml/xpath/ConcatFunction.h
trunk/libjava/gnu/xml/xpath/Constant.h
trunk/libjava/gnu/xml/xpath/ContainsFunction.h
trunk/libjava/gnu/xml/xpath/CountFunction.h
trunk/libjava/gnu/xml/xpath/EqualityExpr.h
trunk/libjava/gnu/xml/xpath/Expr.h
trunk/libjava/gnu/xml/xpath/FalseFunction.h
trunk/libjava/gnu/xml/xpath/FloorFunction.h
trunk/libjava/gnu/xml/xpath/FunctionCall.h
trunk/libjava/gnu/xml/xpath/IdFunction.h
trunk/libjava/gnu/xml/xpath/LangFunction.h
trunk/libjava/gnu/xml/xpath/LastFunction.h
trunk/libjava/gnu/xml/xpath/LocalNameFunction.h
trunk/libjava/gnu/xml/xpath/NameFunction.h
trunk/libjava/gnu/xml/xpath/NameTest.h
trunk/libjava/gnu/xml/xpath/NamespaceTest.h
trunk/libjava/gnu/xml/xpath/NamespaceUriFunction.h
trunk/libjava/gnu/xml/xpath/NegativeExpr.h
trunk/libjava/gnu/xml/xpath/NodeTypeTest.h
trunk/libjava/gnu/xml/xpath/NormalizeSpaceFunction.h
trunk/libjava/gnu/xml/xpath/NotFunction.h
trunk/libjava/gnu/xml/xpath/NumberFunction.h
trunk/libjava/gnu/xml/xpath/OrExpr.h
trunk/libjava/gnu/xml/xpath/ParenthesizedExpr.h
trunk/libjava/gnu/xml/xpath/PositionFunction.h
trunk/libjava/gnu/xml/xpath/Predicate.h
trunk/libjava/gnu/xml/xpath/RelationalExpr.h
trunk/libjava/gnu/xml/xpath/Root.h
trunk/libjava/gnu/xml/xpath/RoundFunction.h
trunk/libjava/gnu/xml/xpath/Selector.h
trunk/libjava/gnu/xml/xpath/StartsWithFunction.h
trunk/libjava/gnu/xml/xpath/Steps.h
trunk/libjava/gnu/xml/xpath/StringFunction.h
trunk/libjava/gnu/xml/xpath/StringLengthFunction.h
trunk/libjava/gnu/xml/xpath/SubstringAfterFunction.h
trunk/libjava/gnu/xml/xpath/SubstringBeforeFunction.h
trunk/libjava/gnu/xml/xpath/SubstringFunction.h
trunk/libjava/gnu/xml/xpath/SumFunction.h
trunk/libjava/gnu/xml/xpath/Test.h
trunk/libjava/gnu/xml/xpath/TranslateFunction.h
trunk/libjava/gnu/xml/xpath/TrueFunction.h
trunk/libjava/gnu/xml/xpath/UnionExpr.h
trunk/libjava/gnu/xml/xpath/VariableReference.h
trunk/libjava/gnu/xml/xpath/XPathImpl.h
trunk/libjava/gnu/xml/xpath/XPathParser.h
trunk/libjava/javax/xml/datatype/DatatypeConstants.h
trunk/libjava/javax/xml/datatype/Duration.h
trunk/libjava/javax/xml/datatype/XMLGregorianCalendar.h
trunk/libjava/javax/xml/namespace/NamespaceContext.h
trunk/libjava/javax/xml/namespace/QName.h
trunk/libjava/javax/xml/stream/XMLEventFactory.h
trunk/libjava/javax/xml/stream/XMLEventWriter.h
trunk/libjava/javax/xml/stream/XMLStreamReader.h
trunk/libjava/javax/xml/stream/XMLStreamWriter.h
trunk/libjava/javax/xml/stream/events/Attribute.h
trunk/libjava/javax/xml/stream/events/Characters.h
trunk/libjava/javax/xml/stream/events/Comment.h
trunk/libjava/javax/xml/stream/events/DTD.h
trunk/libjava/javax/xml/stream/events/EndDocument.h
trunk/libjava/javax/xml/stream/events/EndElement.h
trunk/libjava/javax/xml/stream/events/EntityDeclaration.h
trunk/libjava/javax/xml/stream/events/EntityReference.h
trunk/libjava/javax/xml/stream/events/Namespace.h
trunk/libjava/javax/xml/stream/events/NotationDeclaration.h
trunk/libjava/javax/xml/stream/events/ProcessingInstruction.h
trunk/libjava/javax/xml/stream/events/StartDocument.h
trunk/libjava/javax/xml/stream/events/StartElement.h
trunk/libjava/javax/xml/stream/events/XMLEvent.h
trunk/libjava/javax/xml/stream/util/ReaderDelegate.h
trunk/libjava/javax/xml/xpath/XPath.h
trunk/libjava/javax/xml/xpath/XPathConstants.h
trunk/libjava/javax/xml/xpath/XPathExpression.h
trunk/libjava/javax/xml/xpath/XPathFunctionResolver.h
trunk/libjava/javax/xml/xpath/XPathVariableResolver.h
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40590
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug java/40590] namespace namespace broken in CNI
2009-06-29 16:11 [Bug java/40590] New: namespace namespace broken in CNI aph at gcc dot gnu dot org
` (2 preceding siblings ...)
2009-06-29 17:51 ` aph at gcc dot gnu dot org
@ 2009-06-30 9:59 ` aph at gcc dot gnu dot org
3 siblings, 0 replies; 5+ messages in thread
From: aph at gcc dot gnu dot org @ 2009-06-30 9:59 UTC (permalink / raw)
To: java-prs
------- Comment #4 from aph at gcc dot gnu dot org 2009-06-30 09:59 -------
Fixed by commit.
--
aph at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |RESOLVED
Resolution| |FIXED
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40590
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2009-06-30 9:59 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-06-29 16:11 [Bug java/40590] New: namespace namespace broken in CNI aph at gcc dot gnu dot org
2009-06-29 16:12 ` [Bug java/40590] " aph at gcc dot gnu dot org
2009-06-29 16:26 ` aph at gcc dot gnu dot org
2009-06-29 17:51 ` aph at gcc dot gnu dot org
2009-06-30 9:59 ` aph at gcc dot gnu dot org
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).