tqchen commented on PR #12822:
URL: https://github.com/apache/tvm/pull/12822#issuecomment-1251313772

   Would be great to think about we really want to enable the case of 
`vector<With>`. With is originally designed to only as a sugar to enter a 
context and exit with RAII but not intended to put them into a vector.
   
   Specifically, the default constructor(that initialize optional as nullopt) 
can be confusing for people who intended to start and use it. Perhaps we can 
simply disable the copy constructor in this case and make move constructor 
available only if the underlying Context itself is movable.
   
   This way we would avoid the default copy constructors. Construction of 
moveable only value would be more tricky but doable through emplace. Finally, 
we can find alternatives when maintaining multiple such Constraint. E.g. a 
different constraint context that takes multiple such constraints.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to