1 # RUN: clangd -lit-test < %s | FileCheck %s
2 {"jsonrpc":"2.0","id":0,"method":"initialize","params":{}}
4 {"jsonrpc":"2.0","method":"textDocument/didOpen","params":{"textDocument":{
5 "uri":"test:///main.cpp",
8 "text":"int foo(int bar);\nint x = foo(42);\nint y = foo(42);"
11 {"jsonrpc":"2.0","id":1,"method":"clangd/inlayHints","params":{
12 "textDocument":{"uri":"test:///main.cpp"},
14 "start": {"line":1,"character":0},
15 "end": {"line":2,"character":0}
19 # CHECK-NEXT: "jsonrpc": "2.0",
20 # CHECK-NEXT: "result": [
22 # CHECK-NEXT: "kind": "parameter",
23 # CHECK-NEXT: "label": "bar: ",
24 # CHECK-NEXT: "position": {
25 # CHECK-NEXT: "character": 12,
26 # CHECK-NEXT: "line": 1
28 # CHECK-NEXT: "range": {
29 # CHECK-NEXT: "end": {
30 # CHECK-NEXT: "character": 14,
31 # CHECK-NEXT: "line": 1
33 # CHECK-NEXT: "start": {
34 # CHECK-NEXT: "character": 12,
35 # CHECK-NEXT: "line": 1
42 {"jsonrpc":"2.0","id":2,"method":"textDocument/inlayHint","params":{
43 "textDocument":{"uri":"test:///main.cpp"},
45 "start": {"line":1,"character":0},
46 "end": {"line":2,"character":0}
50 # CHECK-NEXT: "jsonrpc": "2.0",
51 # CHECK-NEXT: "result": [
53 # CHECK-NEXT: "kind": 2,
54 # CHECK-NEXT: "label": "bar:",
55 # CHECK-NEXT: "paddingLeft": false,
56 # CHECK-NEXT: "paddingRight": true,
57 # CHECK-NEXT: "position": {
58 # CHECK-NEXT: "character": 12,
59 # CHECK-NEXT: "line": 1
65 {"jsonrpc":"2.0","id":100,"method":"shutdown"}
67 {"jsonrpc":"2.0","method":"exit"}