Skip to content

Commit

Permalink
Change YamlException to inherit from SerializationException.
Browse files Browse the repository at this point in the history
Resolves #57.
  • Loading branch information
charleskorn committed Nov 3, 2020
1 parent 33194c6 commit e7eaf39
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/main/kotlin/com/charleskorn/kaml/YamlException.kt
Original file line number Diff line number Diff line change
Expand Up @@ -18,11 +18,13 @@

package com.charleskorn.kaml

import kotlinx.serialization.SerializationException

public open class YamlException(
override val message: String,
public val path: YamlPath,
override val cause: Throwable? = null
) : RuntimeException(message, cause) {
) : SerializationException(message, cause) {
public val location: Location = path.endLocation
public val line: Int = location.line
public val column: Int = location.column
Expand Down

0 comments on commit e7eaf39

Please sign in to comment.