aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/at/hannibal2/skyhanni/utils/const/Unconst.kt
blob: 5a2f2ce21ca8dc63837bdf467ffe46260f597320 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
/**
 * This file contains safe dereferences for [Const.unsafeMutable]. By convention `unconst` wrappers should only available
 * for types without interior mutability.
 */

package at.hannibal2.skyhanni.utils.const

import net.minecraft.item.Item


inline val Const<String>.unconst: String get() = unsafeMutable
inline val Const<Int>.unconst: Int get() = unsafeMutable
inline val Const<Long>.unconst: Long get() = unsafeMutable
inline val Const<Item>.unconst: Item get() = unsafeMutable