tvm-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From GitBox <...@apache.org>
Subject [GitHub] [incubator-tvm] zhiics commented on a change in pull request #5314: [RUNTIME][IR] Allow non-nullable ObjectRef, introduce Optional<T>.
Date Sun, 12 Apr 2020 23:58:37 GMT
zhiics commented on a change in pull request #5314: [RUNTIME][IR] Allow non-nullable ObjectRef,
introduce Optional<T>.
URL: https://github.com/apache/incubator-tvm/pull/5314#discussion_r407260426
 
 

 ##########
 File path: include/tvm/ir/attrs.h
 ##########
 @@ -85,6 +85,8 @@ namespace tvm {
  */
 template<typename TObjectRef>
 inline TObjectRef NullValue() {
+  static_assert(TObjectRef::_type_is_nullable,
+                "Can only value for nullable types");
 
 Review comment:
   Please rephrase this error message. 

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

Mime
View raw message