MCPcopy Create free account
hub / github.com/PHPantom-dev/phpantom_lsp / symbol_info_variadic_param

Function symbol_info_variadic_param

tests/unit/phpdoc_internals.rs:1270–1288  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

1268
1269#[test]
1270fn symbol_info_variadic_param() {
1271 let content = concat!(
1272 "<?php\n",
1273 "/**\n",
1274 " * @\n",
1275 " */\n",
1276 "function merge(array ...$arrays): array {}\n",
1277 );
1278 let pos = Position {
1279 line: 2,
1280 character: 4,
1281 };
1282 let info = extract_symbol_info(content, pos);
1283 assert_eq!(info.params.len(), 1);
1284 assert_eq!(
1285 info.params[0],
1286 (Some(PhpType::parse("array")), "$arrays".to_string())
1287 );
1288}
1289
1290#[test]
1291fn symbol_info_reference_param() {

Callers

nothing calls this directly

Calls 1

extract_symbol_infoFunction · 0.85

Tested by

no test coverage detected