package crs

  1. Overview
  2. Docs
A tool for managing inline review comments embedded in source code

Install

dune-project
 Dependency

Authors

Maintainers

Sources

crs-0.0.20260307.tbz
sha256=77f77c61e908a6716fa876f5648f662ffaf7e24be4a7889fd6b53121592311bb
sha512=5fc6252650571c4127ebb1e61fecf78c5d4ce35e2832dff47125cda1448e07ea6d4da5e3a9a28643e3491d3594b0ee8857214241f98bd0296ada2c35ea8daa4b

doc/src/crs.reviewdog/related_location.ml.html

Source file related_location.ml

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
(****************************************************************************)
(*  ocaml-reviewdog - A reviewdog diagnostics json serializer for OCaml     *)
(*  SPDX-FileCopyrightText: 2025 Mathieu Barbin <mathieu.barbin@gmail.com>  *)
(*  SPDX-License-Identifier: MIT                                            *)
(****************************************************************************)

type t =
  { message : string option
  ; location : Location.t
  }

let to_json { message; location } : Yojson.Basic.t =
  `Assoc
    (List.concat
       [ (match message with
          | None -> []
          | Some m -> [ "message", `String m ])
       ; [ "location", Location.to_json location ]
       ])
;;