OSDN Git Service

Fix ordering of fields with the same name.
authorVladimir Marko <vmarko@google.com>
Mon, 17 Nov 2014 15:13:34 +0000 (15:13 +0000)
committerVladimir Marko <vmarko@google.com>
Mon, 17 Nov 2014 18:05:59 +0000 (18:05 +0000)
commit7a7c1db21782fb922d3ffc5c576117812624ea58
tree87cd009dff8386d4fd699bf2eb435bd1b38e86b5
parent1c18d5d0141ffa76b0838fb99615186dcbefc50e
Fix ordering of fields with the same name.

While the Java language doesn't allow multiple fields with
the same name in a single class (excluding fields from super
classes), the bytecode specification permits it and tools
such as proguard actually generate them. Define the order of
these fields by their dex file index and relax the check of
field ordering to permit identical names.

Bug: 18211592
Change-Id: I1dee9b2b669a6ea180a2d3a41030efb2aed53950
runtime/class_linker.cc
runtime/oat.cc
test/800-smali/expected.txt
test/800-smali/smali/sameFieldNames.smali [new file with mode: 0644]
test/800-smali/src/Main.java