| 22 | } |
| 23 | |
| 24 | Matrix * create_matrix(size_t rows, size_t cols) |
| 25 | { |
| 26 | Matrix * p = new Matrix{rows, cols}; |
| 27 | p->pData = new float[p->rows * p->cols]{1.f, 2.f, 3.f}; |
| 28 | //you should check if the memory is allocated successfully |
| 29 | return p; |
| 30 | } |
| 31 | |
| 32 | bool matrix_add(const Matrix & matA, const Matrix & matB, Matrix & matC) |
| 33 | { |
nothing calls this directly
no outgoing calls
no test coverage detected