From 7f05c09adb418841a663df3b5b5902425752a325 Mon Sep 17 00:00:00 2001 From: AJ Date: Sun, 7 Apr 2024 18:29:47 -0700 Subject: [PATCH] Remove fastutil dependency --- build.gradle.kts | 5 ----- src/jvmMain/kotlin/CommonDefsImplJvm.kt | 6 ++---- 2 files changed, 2 insertions(+), 9 deletions(-) diff --git a/build.gradle.kts b/build.gradle.kts index 0be36f0..076f1f7 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -103,11 +103,6 @@ kotlin { val nativeTest by creating { dependsOn(fileBasedTest) } - val jvmMain by getting { - dependencies { - api("it.unimi.dsi:fastutil-core:8.5.12") - } - } val nativeSourceSets = listOf( "linuxX64", "linuxArm64", diff --git a/src/jvmMain/kotlin/CommonDefsImplJvm.kt b/src/jvmMain/kotlin/CommonDefsImplJvm.kt index b7341e7..59e55ef 100644 --- a/src/jvmMain/kotlin/CommonDefsImplJvm.kt +++ b/src/jvmMain/kotlin/CommonDefsImplJvm.kt @@ -1,15 +1,13 @@ package org.intellij.markdown.html -import it.unimi.dsi.fastutil.ints.IntArrayList -import it.unimi.dsi.fastutil.ints.IntStack +import org.intellij.markdown.lexer.Stack import java.net.URLEncoder -import java.util.Stack actual class BitSet actual constructor(size: Int): java.util.BitSet(size){ actual val size = size() } -actual typealias IntStack = IntArrayList +actual class IntStack: Stack() private const val PUNCTUATION_MASK: Int = (1 shl Character.DASH_PUNCTUATION.toInt()) or (1 shl Character.START_PUNCTUATION.toInt()) or