Rabbit-R1/switch port/smali/smali_classes3/kotlin/ranges/LongProgression.smali
2024-05-21 17:08:36 -04:00

447 lines
10 KiB
Smali

.class public Lkotlin/ranges/LongProgression;
.super Ljava/lang/Object;
.source "Progressions.kt"
# interfaces
.implements Ljava/lang/Iterable;
.implements Lkotlin/jvm/internal/markers/KMappedMarker;
# annotations
.annotation system Ldalvik/annotation/MemberClasses;
value = {
Lkotlin/ranges/LongProgression$Companion;
}
.end annotation
.annotation system Ldalvik/annotation/Signature;
value = {
"Ljava/lang/Object;",
"Ljava/lang/Iterable<",
"Ljava/lang/Long;",
">;",
"Lkotlin/jvm/internal/markers/KMappedMarker;"
}
.end annotation
.annotation runtime Lkotlin/Metadata;
d1 = {
"\u00002\n\u0002\u0018\u0002\n\u0002\u0010\u001c\n\u0002\u0010\t\n\u0002\u0008\u000b\n\u0002\u0010\u000b\n\u0000\n\u0002\u0010\u0000\n\u0000\n\u0002\u0010\u0008\n\u0002\u0008\u0002\n\u0002\u0018\u0002\n\u0000\n\u0002\u0010\u000e\n\u0002\u0008\u0002\u0008\u0016\u0018\u0000 \u00182\u0008\u0012\u0004\u0012\u00020\u00020\u0001:\u0001\u0018B\u001f\u0008\u0000\u0012\u0006\u0010\u0003\u001a\u00020\u0002\u0012\u0006\u0010\u0004\u001a\u00020\u0002\u0012\u0006\u0010\u0005\u001a\u00020\u0002\u00a2\u0006\u0002\u0010\u0006J\u0013\u0010\r\u001a\u00020\u000e2\u0008\u0010\u000f\u001a\u0004\u0018\u00010\u0010H\u0096\u0002J\u0008\u0010\u0011\u001a\u00020\u0012H\u0016J\u0008\u0010\u0013\u001a\u00020\u000eH\u0016J\t\u0010\u0014\u001a\u00020\u0015H\u0096\u0002J\u0008\u0010\u0016\u001a\u00020\u0017H\u0016R\u0011\u0010\u0007\u001a\u00020\u0002\u00a2\u0006\u0008\n\u0000\u001a\u0004\u0008\u0008\u0010\tR\u0011\u0010\n\u001a\u00020\u0002\u00a2\u0006\u0008\n\u0000\u001a\u0004\u0008\u000b\u0010\tR\u0011\u0010\u0005\u001a\u00020\u0002\u00a2\u0006\u0008\n\u0000\u001a\u0004\u0008\u000c\u0010\t\u00a8\u0006\u0019"
}
d2 = {
"Lkotlin/ranges/LongProgression;",
"",
"",
"start",
"endInclusive",
"step",
"(JJJ)V",
"first",
"getFirst",
"()J",
"last",
"getLast",
"getStep",
"equals",
"",
"other",
"",
"hashCode",
"",
"isEmpty",
"iterator",
"Lkotlin/collections/LongIterator;",
"toString",
"",
"Companion",
"kotlin-stdlib"
}
k = 0x1
mv = {
0x1,
0x9,
0x0
}
xi = 0x30
.end annotation
# static fields
.field public static final Companion:Lkotlin/ranges/LongProgression$Companion;
# instance fields
.field private final first:J
.field private final last:J
.field private final step:J
# direct methods
.method static constructor <clinit>()V
.locals 2
new-instance v0, Lkotlin/ranges/LongProgression$Companion;
const/4 v1, 0x0
invoke-direct {v0, v1}, Lkotlin/ranges/LongProgression$Companion;-><init>(Lkotlin/jvm/internal/DefaultConstructorMarker;)V
sput-object v0, Lkotlin/ranges/LongProgression;->Companion:Lkotlin/ranges/LongProgression$Companion;
return-void
.end method
.method public constructor <init>(JJJ)V
.locals 2
.line 139
invoke-direct {p0}, Ljava/lang/Object;-><init>()V
const-wide/16 v0, 0x0
cmp-long v0, p5, v0
if-eqz v0, :cond_1
const-wide/high16 v0, -0x8000000000000000L
cmp-long v0, p5, v0
if-eqz v0, :cond_0
iput-wide p1, p0, Lkotlin/ranges/LongProgression;->first:J
.line 159
invoke-static/range {p1 .. p6}, Lkotlin/internal/ProgressionUtilKt;->getProgressionLastElement(JJJ)J
move-result-wide p1
iput-wide p1, p0, Lkotlin/ranges/LongProgression;->last:J
iput-wide p5, p0, Lkotlin/ranges/LongProgression;->step:J
return-void
.line 148
:cond_0
new-instance p0, Ljava/lang/IllegalArgumentException;
const-string p1, "Step must be greater than Long.MIN_VALUE to avoid overflow on negation."
invoke-direct {p0, p1}, Ljava/lang/IllegalArgumentException;-><init>(Ljava/lang/String;)V
throw p0
.line 147
:cond_1
new-instance p0, Ljava/lang/IllegalArgumentException;
const-string p1, "Step must be non-zero."
invoke-direct {p0, p1}, Ljava/lang/IllegalArgumentException;-><init>(Ljava/lang/String;)V
throw p0
.end method
# virtual methods
.method public equals(Ljava/lang/Object;)Z
.locals 4
.line 177
instance-of v0, p1, Lkotlin/ranges/LongProgression;
if-eqz v0, :cond_2
invoke-virtual {p0}, Lkotlin/ranges/LongProgression;->isEmpty()Z
move-result v0
if-eqz v0, :cond_0
move-object v0, p1
check-cast v0, Lkotlin/ranges/LongProgression;
invoke-virtual {v0}, Lkotlin/ranges/LongProgression;->isEmpty()Z
move-result v0
if-nez v0, :cond_1
:cond_0
iget-wide v0, p0, Lkotlin/ranges/LongProgression;->first:J
.line 178
check-cast p1, Lkotlin/ranges/LongProgression;
iget-wide v2, p1, Lkotlin/ranges/LongProgression;->first:J
cmp-long v0, v0, v2
if-nez v0, :cond_2
iget-wide v0, p0, Lkotlin/ranges/LongProgression;->last:J
iget-wide v2, p1, Lkotlin/ranges/LongProgression;->last:J
cmp-long v0, v0, v2
if-nez v0, :cond_2
iget-wide v0, p0, Lkotlin/ranges/LongProgression;->step:J
iget-wide p0, p1, Lkotlin/ranges/LongProgression;->step:J
cmp-long p0, v0, p0
if-nez p0, :cond_2
:cond_1
const/4 p0, 0x1
goto :goto_0
:cond_2
const/4 p0, 0x0
:goto_0
return p0
.end method
.method public final getFirst()J
.locals 2
iget-wide v0, p0, Lkotlin/ranges/LongProgression;->first:J
return-wide v0
.end method
.method public final getLast()J
.locals 2
iget-wide v0, p0, Lkotlin/ranges/LongProgression;->last:J
return-wide v0
.end method
.method public final getStep()J
.locals 2
iget-wide v0, p0, Lkotlin/ranges/LongProgression;->step:J
return-wide v0
.end method
.method public hashCode()I
.locals 9
.line 181
invoke-virtual {p0}, Lkotlin/ranges/LongProgression;->isEmpty()Z
move-result v0
if-eqz v0, :cond_0
const/4 p0, -0x1
goto :goto_0
:cond_0
const/16 v0, 0x1f
int-to-long v0, v0
iget-wide v2, p0, Lkotlin/ranges/LongProgression;->first:J
const/16 v4, 0x20
ushr-long v5, v2, v4
xor-long/2addr v2, v5
mul-long/2addr v2, v0
iget-wide v5, p0, Lkotlin/ranges/LongProgression;->last:J
ushr-long v7, v5, v4
xor-long/2addr v5, v7
add-long/2addr v2, v5
mul-long/2addr v0, v2
iget-wide v2, p0, Lkotlin/ranges/LongProgression;->step:J
ushr-long v4, v2, v4
xor-long/2addr v2, v4
add-long/2addr v0, v2
long-to-int p0, v0
:goto_0
return p0
.end method
.method public isEmpty()Z
.locals 7
iget-wide v0, p0, Lkotlin/ranges/LongProgression;->step:J
const-wide/16 v2, 0x0
cmp-long v0, v0, v2
const/4 v1, 0x1
const/4 v2, 0x0
iget-wide v3, p0, Lkotlin/ranges/LongProgression;->first:J
iget-wide v5, p0, Lkotlin/ranges/LongProgression;->last:J
cmp-long p0, v3, v5
if-lez v0, :cond_0
if-lez p0, :cond_1
goto :goto_0
:cond_0
if-gez p0, :cond_1
goto :goto_0
:cond_1
move v1, v2
:goto_0
return v1
.end method
.method public bridge synthetic iterator()Ljava/util/Iterator;
.locals 0
.line 139
invoke-virtual {p0}, Lkotlin/ranges/LongProgression;->iterator()Lkotlin/collections/LongIterator;
move-result-object p0
check-cast p0, Ljava/util/Iterator;
return-object p0
.end method
.method public iterator()Lkotlin/collections/LongIterator;
.locals 8
.line 166
new-instance v7, Lkotlin/ranges/LongProgressionIterator;
iget-wide v1, p0, Lkotlin/ranges/LongProgression;->first:J
iget-wide v3, p0, Lkotlin/ranges/LongProgression;->last:J
iget-wide v5, p0, Lkotlin/ranges/LongProgression;->step:J
move-object v0, v7
invoke-direct/range {v0 .. v6}, Lkotlin/ranges/LongProgressionIterator;-><init>(JJJ)V
check-cast v7, Lkotlin/collections/LongIterator;
return-object v7
.end method
.method public toString()Ljava/lang/String;
.locals 4
iget-wide v0, p0, Lkotlin/ranges/LongProgression;->step:J
const-wide/16 v2, 0x0
cmp-long v0, v0, v2
const-string v1, " step "
if-lez v0, :cond_0
.line 183
new-instance v0, Ljava/lang/StringBuilder;
invoke-direct {v0}, Ljava/lang/StringBuilder;-><init>()V
iget-wide v2, p0, Lkotlin/ranges/LongProgression;->first:J
invoke-virtual {v0, v2, v3}, Ljava/lang/StringBuilder;->append(J)Ljava/lang/StringBuilder;
move-result-object v0
const-string v2, ".."
invoke-virtual {v0, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
move-result-object v0
iget-wide v2, p0, Lkotlin/ranges/LongProgression;->last:J
invoke-virtual {v0, v2, v3}, Ljava/lang/StringBuilder;->append(J)Ljava/lang/StringBuilder;
move-result-object v0
invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
move-result-object v0
iget-wide v1, p0, Lkotlin/ranges/LongProgression;->step:J
goto :goto_0
:cond_0
new-instance v0, Ljava/lang/StringBuilder;
invoke-direct {v0}, Ljava/lang/StringBuilder;-><init>()V
iget-wide v2, p0, Lkotlin/ranges/LongProgression;->first:J
invoke-virtual {v0, v2, v3}, Ljava/lang/StringBuilder;->append(J)Ljava/lang/StringBuilder;
move-result-object v0
const-string v2, " downTo "
invoke-virtual {v0, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
move-result-object v0
iget-wide v2, p0, Lkotlin/ranges/LongProgression;->last:J
invoke-virtual {v0, v2, v3}, Ljava/lang/StringBuilder;->append(J)Ljava/lang/StringBuilder;
move-result-object v0
invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
move-result-object v0
iget-wide v1, p0, Lkotlin/ranges/LongProgression;->step:J
neg-long v1, v1
:goto_0
invoke-virtual {v0, v1, v2}, Ljava/lang/StringBuilder;->append(J)Ljava/lang/StringBuilder;
move-result-object p0
invoke-virtual {p0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
move-result-object p0
return-object p0
.end method