="idea">val number: NegativeInt = (-123).toNegativeInt()<br>    .getOrThrow()<br>val encoded: String = Json.encodeToString(number)<br>println(encoded) // -123<br>val decoded: NegativeInt = Json.decodeFromString(encoded)<br>println(decoded == number) // true</code></pre><span class="top-right-position"><span class="copy-icon"></span><div class="copy-popup-wrapper popup-to-left"><span class="copy-popup-icon"></span><span>Content copied to clipboard</span></div></span></div></details><h4 class="">Inheritors</h