This is the mail archive of the
kawa@sourceware.org
mailing list for the Kawa project.
Incompatibility between the Android runtime and Kawa-generated field names
- From: Kay Zheng <l04m33 at gmail dot com>
- To: Kawa mailing list <kawa at sourceware dot org>
- Date: Thu, 31 Aug 2017 00:10:05 +0800
- Subject: Incompatibility between the Android runtime and Kawa-generated field names
- Authentication-results: sourceware.org; auth=none
Hi folks,
I built a simple Android app against Kawa's master branch. I've been
able to generate the APK, but the ART (Android runtime) kept
complaining about this when trying to launch the app:
08-30 17:57:28.998 15990 15990 W art : Failure to verify dex
file '/data/app/com.theerrorlog.superbapp-1/base.apk': Invalid field
name: '1+'
It turned out that some class files in Kawa's standard library
contained fields with exotic names such as '1+', '1-',
'%provide%srfi-41', which seemed to be legal JVM names, but treated as
illegal by the ART.
And I noticed that the 2.4 branch used a different naming scheme that
"translates" these exotic names into names with "escape sequences".
For example '1+' will be renamed to '$N1$Pl', making the translated
names all legal ART names too.
So what's the reason for abandoning the "escaping" naming scheme? Can
I remedy the incompatibility issue in some way?
Regards,
Kay Z.