commit | f08cbfefb876faf50966e5554484c1a35eded73c | [log] [tgz] |
---|---|---|
author | Aiden Benner <abenner@google.com> | Wed Oct 24 02:50:57 2018 |
committer | Commit Bot <commit-bot@chromium.org> | Wed Oct 24 02:50:57 2018 |
tree | d59f45cf69e0cdcf47f2f0c3c156cf0fc1981a99 | |
parent | 86d36046b14227b3da84850dfec9dc8fae34440a [diff] |
Add array support and type exceptions to generated native method object casting Even though String is an object (and so being casted to jobject across the jni boundary would make sense), the JNI spec gives special treatment for java string types and they're casted to jstrings instead of jobjects. This change makes sure Strings stay as Strings in the native method declaration. Previously all non-primitive types would be casted to objects. Also fixed a bug where void was being cast to object (this happened because void is non-primitive). Also adds better array support. Arrays with a primitive component type will stay as primitive arrays but arrays with a non-primitive component type will be casted to an object array. Change-Id: If795bcddf7a38f051d0c6fb515e1dd320dd3f30d Bug: 898261 Reviewed-on: https://chromium-review.googlesource.com/c/1297083 Commit-Queue: Aiden Benner <abenner@google.com> Reviewed-by: agrieve <agrieve@chromium.org> Reviewed-by: Eric Stevenson <estevenson@chromium.org> Cr-Commit-Position: refs/heads/master@{#602230}
Chromium is an open-source browser project that aims to build a safer, faster, and more stable way for all users to experience the web.
The project's web site is https://www.chromium.org.
Documentation in the source is rooted in docs/README.md.
Learn how to Get Around the Chromium Source Code Directory Structure .