Commit 953fc1b
[api-xml-adjuster] Outer<X>.Inner<Y> class name parsing. (#109)
Fixes: https://bugzilla.xamarin.com/show_bug.cgi?id=46344
`Xamarin.Android.Tools.ApiXmlAdjuster.JavaTypeName.Parse()` would
throw an `ArgumentOutOfRangeException` when encountering generic
nested types on generic types.
Given the following valid Java code:
// Java
class GenericOuter<TOuter> {
public class GenericInner<TInner> {
}
}
class Gapp {
public static void main (String[] args) {
GenericOuter<Integer>.GenericInner<String> v = null;
}
}
Then the following would fail:
JavaTypeName.Parse("GenericOuter<Integer>.GenericInner<String>")
System.ArgumentOutOfRangeException: Length cannot be less than zero.
Parameter name: length
...
Fix `JavaTypeName.Parse()` to support parsing nested generic types
on generic types.1 parent 5398f24 commit 953fc1b
1 file changed
+17
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
55 | 55 | | |
56 | 56 | | |
57 | 57 | | |
58 | | - | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
59 | 74 | | |
60 | 75 | | |
61 | | - | |
| 76 | + | |
62 | 77 | | |
63 | 78 | | |
64 | 79 | | |
| |||
0 commit comments