# mod.ts
export function foo(bar: A | B): bar is A {}

# diagnostics
error[missing-jsdoc]: exported symbol is missing JSDoc documentation
 --> /mod.ts:1:1
  | 
1 | export function foo(bar: A | B): bar is A {}
  | ^

# output.txt
Defined in file:///mod.ts:0:1

function foo(bar: A | B): bar is A


# output.json
{
  "symbols": [
    {
      "name": "foo",
      "declarations": [
        {
          "location": {
            "filename": "file:///mod.ts",
            "line": 0,
            "col": 0,
            "byteIndex": 0
          },
          "declarationKind": "export",
          "kind": "function",
          "def": {
            "params": [
              {
                "kind": "identifier",
                "name": "bar",
                "optional": false,
                "tsType": {
                  "kind": "union",
                  "value": [
                    {
                      "repr": "A",
                      "kind": "typeRef",
                      "value": {
                        "typeName": "A"
                      }
                    },
                    {
                      "repr": "B",
                      "kind": "typeRef",
                      "value": {
                        "typeName": "B"
                      }
                    }
                  ]
                }
              }
            ],
            "returnType": {
              "repr": "bar is A",
              "kind": "typePredicate",
              "value": {
                "param": {
                  "type": "identifier",
                  "name": "bar"
                },
                "type": {
                  "repr": "A",
                  "kind": "typeRef",
                  "value": {
                    "typeName": "A"
                  }
                }
              }
            },
            "hasBody": true
          }
        }
      ]
    }
  ]
}
