[JS] Add a doc comment for SourceMapLocationRemapper

This commit is contained in:
Sergej Jaskiewicz
2022-05-24 16:06:52 +03:00
committed by Space
parent 0614c519af
commit 375c13cd7e
@@ -18,6 +18,11 @@ package org.jetbrains.kotlin.js.parser.sourcemaps
import org.jetbrains.kotlin.js.backend.ast.*
/**
* JS source map remapper takes parsed source maps
* together with JS AST with correct JS positioning information
* and converts the latter into Kotlin positioning information
*/
class SourceMapLocationRemapper(private val sourceMap: SourceMap, private val sourceMapPathMapper: (String) -> String = { it }) {
fun remap(node: JsNode) {
val listCollector = JsNodeFlatListCollector()
@@ -138,4 +143,4 @@ class SourceMapLocationRemapper(private val sourceMap: SourceMap, private val so
return first.startLine > second.startLine || (first.startLine == second.startLine && first.startChar >= second.startChar)
}
}
}
}