Skip to content
Commit 926fb685 authored by Mehdi Amini's avatar Mehdi Amini Committed by A. Unique TensorFlower
Browse files

Express ownership transfer in PassManager API through std::unique_ptr (NFC)

Since raw pointers are always passed around for IR construct without
implying any ownership transfer, it can be error prone to have implicit
ownership transferred the same way.
For example this code can seem harmless:

  Pass *pass = ....
  pm.addPass(pass);
  pm.addPass(pass);
  pm.run(module);

PiperOrigin-RevId: 263053082
parent 532c652d
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment