Bug 15911 - dbus-java: CreateInterface don't check for Java keywords
Summary: dbus-java: CreateInterface don't check for Java keywords
Status: RESOLVED FIXED
Alias: None
Product: dbus
Classification: Unclassified
Component: java (show other bugs)
Version: unspecified
Hardware: Other All
: medium normal
Assignee: Matthew Johnson
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-05-12 10:02 UTC by Sveinung Kvilhaugsvik
Modified: 2008-05-31 12:09 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments
Testcase taken from the Telepathy spec. (LGPL) (538 bytes, text/xml)
2008-05-12 10:02 UTC, Sveinung Kvilhaugsvik
Details

Description Sveinung Kvilhaugsvik 2008-05-12 10:02:09 UTC
Created attachment 16485 [details]
Testcase taken from the Telepathy spec. (LGPL)

CreateInterface doesn't check for Java keywords in variable names when it generates interfaces. Because of this, it will generate Java code that use reserved keywords like "new" as variable names if that is what the input calls them. The generated code will then have errors, since "new" is a reserved keyword.

Fast hack to workaround the problem: cat Generated.java | sed -e "s/new/theNew/g" > Generated.java
Comment 1 Matthew Johnson 2008-05-31 12:09:26 UTC
I've added name mangling for reserved words to CreateInterface. It'll be in the next release.

Thanks,
Matt


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.