2020-04-27 20:53:11 +00:00
|
|
|
.class public Lx/a0/o;
|
|
|
|
.super Lx/a0/n;
|
2020-03-14 04:13:36 +00:00
|
|
|
.source "StringNumberConversions.kt"
|
2019-12-06 03:29:40 +00:00
|
|
|
|
|
|
|
|
2020-03-14 04:13:36 +00:00
|
|
|
# direct methods
|
|
|
|
.method public constructor <init>()V
|
|
|
|
.locals 0
|
2019-12-06 03:29:40 +00:00
|
|
|
|
2020-04-27 20:53:11 +00:00
|
|
|
invoke-direct {p0}, Lx/a0/n;-><init>()V
|
2019-12-06 03:29:40 +00:00
|
|
|
|
2020-03-14 04:13:36 +00:00
|
|
|
return-void
|
|
|
|
.end method
|
2019-12-06 03:29:40 +00:00
|
|
|
|
2020-03-14 04:13:36 +00:00
|
|
|
.method public static final toIntOrNull(Ljava/lang/String;)Ljava/lang/Integer;
|
|
|
|
.locals 11
|
2019-12-06 03:29:40 +00:00
|
|
|
|
2020-03-14 04:13:36 +00:00
|
|
|
const/4 v0, 0x0
|
2019-12-06 03:29:40 +00:00
|
|
|
|
2020-03-14 04:13:36 +00:00
|
|
|
if-eqz p0, :cond_a
|
2019-12-06 03:29:40 +00:00
|
|
|
|
2020-03-14 04:13:36 +00:00
|
|
|
const/16 v1, 0xa
|
2020-03-10 23:21:53 +00:00
|
|
|
|
2020-05-07 22:12:04 +00:00
|
|
|
invoke-static {v1}, Le/o/a/j/a;->checkRadix(I)I
|
2020-03-10 23:21:53 +00:00
|
|
|
|
2020-03-14 04:13:36 +00:00
|
|
|
invoke-virtual {p0}, Ljava/lang/String;->length()I
|
2020-03-10 23:21:53 +00:00
|
|
|
|
2020-03-14 04:13:36 +00:00
|
|
|
move-result v2
|
2020-03-10 23:21:53 +00:00
|
|
|
|
2020-03-14 04:13:36 +00:00
|
|
|
if-nez v2, :cond_0
|
2020-03-10 23:21:53 +00:00
|
|
|
|
2020-03-14 04:13:36 +00:00
|
|
|
goto :goto_4
|
2020-03-10 23:21:53 +00:00
|
|
|
|
2020-03-14 04:13:36 +00:00
|
|
|
:cond_0
|
|
|
|
const/4 v3, 0x0
|
2020-03-10 23:21:53 +00:00
|
|
|
|
2020-03-14 04:13:36 +00:00
|
|
|
invoke-virtual {p0, v3}, Ljava/lang/String;->charAt(I)C
|
2020-03-10 23:21:53 +00:00
|
|
|
|
2020-03-14 04:13:36 +00:00
|
|
|
move-result v4
|
2020-03-10 23:21:53 +00:00
|
|
|
|
2020-03-14 04:13:36 +00:00
|
|
|
const/16 v5, 0x30
|
2020-03-10 23:21:53 +00:00
|
|
|
|
2020-03-14 04:13:36 +00:00
|
|
|
const v6, -0x7fffffff
|
2020-03-10 23:21:53 +00:00
|
|
|
|
2020-03-14 04:13:36 +00:00
|
|
|
const/4 v7, 0x1
|
2019-12-06 03:29:40 +00:00
|
|
|
|
2020-03-14 04:13:36 +00:00
|
|
|
if-ge v4, v5, :cond_3
|
2019-12-06 03:29:40 +00:00
|
|
|
|
2020-03-14 04:13:36 +00:00
|
|
|
if-ne v2, v7, :cond_1
|
2019-12-06 03:29:40 +00:00
|
|
|
|
2020-03-14 04:13:36 +00:00
|
|
|
goto :goto_4
|
2020-03-10 23:21:53 +00:00
|
|
|
|
2020-03-14 04:13:36 +00:00
|
|
|
:cond_1
|
|
|
|
const/16 v5, 0x2d
|
2020-03-10 23:21:53 +00:00
|
|
|
|
2020-03-14 04:13:36 +00:00
|
|
|
if-ne v4, v5, :cond_2
|
2020-03-10 23:21:53 +00:00
|
|
|
|
2020-03-14 04:13:36 +00:00
|
|
|
const/high16 v6, -0x80000000
|
2020-03-10 23:21:53 +00:00
|
|
|
|
2020-03-14 04:13:36 +00:00
|
|
|
const/4 v4, 0x1
|
2020-03-10 23:21:53 +00:00
|
|
|
|
2020-03-14 04:13:36 +00:00
|
|
|
goto :goto_1
|
2020-03-10 23:21:53 +00:00
|
|
|
|
2020-03-14 04:13:36 +00:00
|
|
|
:cond_2
|
|
|
|
const/16 v5, 0x2b
|
2020-03-10 23:21:53 +00:00
|
|
|
|
2020-03-14 04:13:36 +00:00
|
|
|
if-ne v4, v5, :cond_9
|
2020-03-10 23:21:53 +00:00
|
|
|
|
2020-03-14 04:13:36 +00:00
|
|
|
const/4 v4, 0x1
|
2020-03-10 23:21:53 +00:00
|
|
|
|
2020-03-14 02:12:46 +00:00
|
|
|
goto :goto_0
|
2020-03-10 23:21:53 +00:00
|
|
|
|
2020-03-14 04:13:36 +00:00
|
|
|
:cond_3
|
|
|
|
const/4 v4, 0x0
|
2020-03-10 23:21:53 +00:00
|
|
|
|
2020-03-14 04:13:36 +00:00
|
|
|
:goto_0
|
|
|
|
const/4 v7, 0x0
|
2020-03-10 23:21:53 +00:00
|
|
|
|
2020-03-14 04:13:36 +00:00
|
|
|
:goto_1
|
|
|
|
const v5, -0x38e38e3
|
2020-03-10 23:21:53 +00:00
|
|
|
|
2020-03-14 04:13:36 +00:00
|
|
|
const v8, -0x38e38e3
|
2020-03-10 23:21:53 +00:00
|
|
|
|
2020-03-14 04:13:36 +00:00
|
|
|
:goto_2
|
|
|
|
if-ge v4, v2, :cond_7
|
2020-03-10 23:21:53 +00:00
|
|
|
|
2020-03-14 04:13:36 +00:00
|
|
|
invoke-virtual {p0, v4}, Ljava/lang/String;->charAt(I)C
|
2020-03-10 23:21:53 +00:00
|
|
|
|
2020-03-14 04:13:36 +00:00
|
|
|
move-result v9
|
2020-03-10 23:21:53 +00:00
|
|
|
|
2020-05-07 22:12:04 +00:00
|
|
|
invoke-static {v9, v1}, Le/o/a/j/a;->digitOf(CI)I
|
2020-03-14 04:13:36 +00:00
|
|
|
|
|
|
|
move-result v9
|
|
|
|
|
|
|
|
if-gez v9, :cond_4
|
|
|
|
|
|
|
|
goto :goto_4
|
|
|
|
|
|
|
|
:cond_4
|
|
|
|
if-ge v3, v8, :cond_5
|
|
|
|
|
|
|
|
if-ne v8, v5, :cond_9
|
|
|
|
|
|
|
|
div-int/lit8 v8, v6, 0xa
|
|
|
|
|
|
|
|
if-ge v3, v8, :cond_5
|
|
|
|
|
|
|
|
goto :goto_4
|
|
|
|
|
|
|
|
:cond_5
|
|
|
|
mul-int/lit8 v3, v3, 0xa
|
|
|
|
|
|
|
|
add-int v10, v6, v9
|
|
|
|
|
|
|
|
if-ge v3, v10, :cond_6
|
|
|
|
|
|
|
|
goto :goto_4
|
|
|
|
|
|
|
|
:cond_6
|
|
|
|
sub-int/2addr v3, v9
|
|
|
|
|
|
|
|
add-int/lit8 v4, v4, 0x1
|
|
|
|
|
|
|
|
goto :goto_2
|
|
|
|
|
|
|
|
:cond_7
|
|
|
|
if-eqz v7, :cond_8
|
|
|
|
|
|
|
|
invoke-static {v3}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
|
|
|
|
|
|
|
|
move-result-object p0
|
|
|
|
|
|
|
|
goto :goto_3
|
|
|
|
|
|
|
|
:cond_8
|
|
|
|
neg-int p0, v3
|
|
|
|
|
|
|
|
invoke-static {p0}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
|
|
|
|
|
|
|
|
move-result-object p0
|
|
|
|
|
|
|
|
:goto_3
|
|
|
|
move-object v0, p0
|
|
|
|
|
|
|
|
:cond_9
|
|
|
|
:goto_4
|
2020-03-14 02:12:46 +00:00
|
|
|
return-object v0
|
2020-03-10 23:21:53 +00:00
|
|
|
|
2020-03-14 04:13:36 +00:00
|
|
|
:cond_a
|
|
|
|
const-string p0, "$this$toIntOrNull"
|
2020-03-10 23:21:53 +00:00
|
|
|
|
2020-04-27 20:53:11 +00:00
|
|
|
invoke-static {p0}, Lx/u/b/j;->a(Ljava/lang/String;)V
|
2020-03-10 23:21:53 +00:00
|
|
|
|
2020-03-14 02:12:46 +00:00
|
|
|
throw v0
|
2020-03-10 23:21:53 +00:00
|
|
|
.end method
|
2020-03-14 04:13:36 +00:00
|
|
|
|
|
|
|
.method public static final toLongOrNull(Ljava/lang/String;)Ljava/lang/Long;
|
|
|
|
.locals 18
|
|
|
|
|
|
|
|
move-object/from16 v0, p0
|
|
|
|
|
|
|
|
const/4 v1, 0x0
|
|
|
|
|
|
|
|
if-eqz v0, :cond_a
|
|
|
|
|
|
|
|
const/16 v2, 0xa
|
|
|
|
|
2020-05-07 22:12:04 +00:00
|
|
|
invoke-static {v2}, Le/o/a/j/a;->checkRadix(I)I
|
2020-03-14 04:13:36 +00:00
|
|
|
|
|
|
|
invoke-virtual/range {p0 .. p0}, Ljava/lang/String;->length()I
|
|
|
|
|
|
|
|
move-result v3
|
|
|
|
|
|
|
|
if-nez v3, :cond_0
|
|
|
|
|
|
|
|
goto/16 :goto_3
|
|
|
|
|
|
|
|
:cond_0
|
|
|
|
const/4 v4, 0x0
|
|
|
|
|
|
|
|
invoke-virtual {v0, v4}, Ljava/lang/String;->charAt(I)C
|
|
|
|
|
|
|
|
move-result v5
|
|
|
|
|
|
|
|
const/16 v6, 0x30
|
|
|
|
|
|
|
|
const-wide v7, -0x7fffffffffffffffL # -4.9E-324
|
|
|
|
|
|
|
|
const/4 v9, 0x1
|
|
|
|
|
|
|
|
if-ge v5, v6, :cond_3
|
|
|
|
|
|
|
|
if-ne v3, v9, :cond_1
|
|
|
|
|
|
|
|
goto :goto_3
|
|
|
|
|
|
|
|
:cond_1
|
|
|
|
const/16 v6, 0x2d
|
|
|
|
|
|
|
|
if-ne v5, v6, :cond_2
|
|
|
|
|
|
|
|
const-wide/high16 v7, -0x8000000000000000L
|
|
|
|
|
|
|
|
const/4 v4, 0x1
|
|
|
|
|
|
|
|
goto :goto_0
|
|
|
|
|
|
|
|
:cond_2
|
|
|
|
const/16 v6, 0x2b
|
|
|
|
|
|
|
|
if-ne v5, v6, :cond_9
|
|
|
|
|
|
|
|
goto :goto_0
|
|
|
|
|
|
|
|
:cond_3
|
|
|
|
const/4 v9, 0x0
|
|
|
|
|
|
|
|
:goto_0
|
|
|
|
const-wide/16 v5, 0x0
|
|
|
|
|
|
|
|
const-wide v10, -0x38e38e38e38e38eL # -2.772000429909333E291
|
|
|
|
|
|
|
|
move-wide v12, v10
|
|
|
|
|
|
|
|
:goto_1
|
|
|
|
if-ge v9, v3, :cond_7
|
|
|
|
|
|
|
|
invoke-virtual {v0, v9}, Ljava/lang/String;->charAt(I)C
|
|
|
|
|
|
|
|
move-result v14
|
|
|
|
|
2020-05-07 22:12:04 +00:00
|
|
|
invoke-static {v14, v2}, Le/o/a/j/a;->digitOf(CI)I
|
2020-03-14 04:13:36 +00:00
|
|
|
|
|
|
|
move-result v14
|
|
|
|
|
|
|
|
if-gez v14, :cond_4
|
|
|
|
|
|
|
|
goto :goto_3
|
|
|
|
|
|
|
|
:cond_4
|
|
|
|
cmp-long v15, v5, v12
|
|
|
|
|
|
|
|
if-gez v15, :cond_5
|
|
|
|
|
|
|
|
cmp-long v15, v12, v10
|
|
|
|
|
|
|
|
if-nez v15, :cond_9
|
|
|
|
|
|
|
|
int-to-long v12, v2
|
|
|
|
|
|
|
|
div-long v12, v7, v12
|
|
|
|
|
|
|
|
cmp-long v15, v5, v12
|
|
|
|
|
|
|
|
if-gez v15, :cond_5
|
|
|
|
|
|
|
|
goto :goto_3
|
|
|
|
|
|
|
|
:cond_5
|
|
|
|
int-to-long v10, v2
|
|
|
|
|
|
|
|
mul-long v5, v5, v10
|
|
|
|
|
|
|
|
int-to-long v10, v14
|
|
|
|
|
|
|
|
add-long v16, v7, v10
|
|
|
|
|
|
|
|
cmp-long v14, v5, v16
|
|
|
|
|
|
|
|
if-gez v14, :cond_6
|
|
|
|
|
|
|
|
goto :goto_3
|
|
|
|
|
|
|
|
:cond_6
|
|
|
|
sub-long/2addr v5, v10
|
|
|
|
|
|
|
|
add-int/lit8 v9, v9, 0x1
|
|
|
|
|
|
|
|
const-wide v10, -0x38e38e38e38e38eL # -2.772000429909333E291
|
|
|
|
|
|
|
|
goto :goto_1
|
|
|
|
|
|
|
|
:cond_7
|
|
|
|
if-eqz v4, :cond_8
|
|
|
|
|
|
|
|
invoke-static {v5, v6}, Ljava/lang/Long;->valueOf(J)Ljava/lang/Long;
|
|
|
|
|
|
|
|
move-result-object v0
|
|
|
|
|
|
|
|
goto :goto_2
|
|
|
|
|
|
|
|
:cond_8
|
|
|
|
neg-long v0, v5
|
|
|
|
|
|
|
|
invoke-static {v0, v1}, Ljava/lang/Long;->valueOf(J)Ljava/lang/Long;
|
|
|
|
|
|
|
|
move-result-object v0
|
|
|
|
|
|
|
|
:goto_2
|
|
|
|
move-object v1, v0
|
|
|
|
|
|
|
|
:cond_9
|
|
|
|
:goto_3
|
|
|
|
return-object v1
|
|
|
|
|
|
|
|
:cond_a
|
|
|
|
const-string v0, "$this$toLongOrNull"
|
|
|
|
|
2020-04-27 20:53:11 +00:00
|
|
|
invoke-static {v0}, Lx/u/b/j;->a(Ljava/lang/String;)V
|
2020-03-14 04:13:36 +00:00
|
|
|
|
|
|
|
throw v1
|
|
|
|
.end method
|