(use: string)
| 418 | |
| 419 | describe('a deduced argument', () => { |
| 420 | const deduced = (use: string): Promise<CodeGraph> => indexed({ |
| 421 | 'txn.h': TXN, |
| 422 | 'run.cc': lines( |
| 423 | '#include "txn.h"', |
| 424 | 'template <typename T> void ByValue(T x) { T::Make(); }', |
| 425 | 'template <typename T> void ByRef(const T& x) { T::Make(); }', |
| 426 | 'template <typename T> void ByPointer(T* x) { T::Make(); }', |
| 427 | 'template <typename T> void ByHolder(std::vector<T>* x) { T::Make(); }', |
| 428 | use, |
| 429 | ), |
| 430 | }); |
| 431 | |
| 432 | it('reads the type of a declared argument, whole', async () => { |
| 433 | const cg = await deduced('void Run() { PlainTxn p; ByValue(p); ByRef(p); }'); |
no test coverage detected