tqchen commented on code in PR #16183:
URL: https://github.com/apache/tvm/pull/16183#discussion_r1409804177


##########
include/tvm/runtime/packed_func.h:
##########
@@ -627,13 +645,54 @@ class TVMPODValue_ {
   template <typename TObjectRef>
   inline TObjectRef AsObjectRef() const;
 
+  std::optional<int64_t> TryAsInt() const {
+    // Helper function to reduce duplication in the variable integer
+    // conversions.  This is publicly exposed, as it can be useful in
+    // specializations of PackedFuncValueConverter.
+    if (auto opt = FromBoxed<int64_t>()) {

Review Comment:
   That means we do not need to have FromBoxed, since Boxed value do not occur 
in the ArgValue



-- 
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