| 32 | using namespace solidity; |
| 33 | |
| 34 | Json HandlerBase::toRange(SourceLocation const& _location) const |
| 35 | { |
| 36 | if (!_location.hasText()) |
| 37 | return toJsonRange({}, {}); |
| 38 | |
| 39 | solAssert(_location.sourceName, ""); |
| 40 | langutil::CharStream const& stream = charStreamProvider().charStream(*_location.sourceName); |
| 41 | LineColumn start = stream.translatePositionToLineColumn(_location.start); |
| 42 | LineColumn end = stream.translatePositionToLineColumn(_location.end); |
| 43 | return toJsonRange(start, end); |
| 44 | } |
| 45 | |
| 46 | Json HandlerBase::toJson(SourceLocation const& _location) const |
| 47 | { |
nothing calls this directly
no test coverage detected