Skip to content

Commit 2b827c9

Browse files
committed
[FFI][REFACTOR] Cleanup namespace (apache#18280)
* [FFI][REFACTOR] Cleanup namespace This PR cleansup the namespace to ensure all ffi classes are accessed through ffi:: namespace. It will helps to cleanup the ffi package before isolation. * fix hexagon
1 parent 3e147ba commit 2b827c9

File tree

8 files changed

+0
-18
lines changed

8 files changed

+0
-18
lines changed

include/tvm/ffi/cast.h

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -73,8 +73,5 @@ inline ObjectPtr<BaseType> GetObjectPtr(ObjectType* ptr) {
7373
return details::ObjectUnsafe::ObjectPtrFromUnowned<BaseType>(ptr);
7474
}
7575
} // namespace ffi
76-
77-
using ffi::GetObjectPtr;
78-
using ffi::GetRef;
7976
} // namespace tvm
8077
#endif // TVM_FFI_CAST_H_

include/tvm/ffi/container/array.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1140,7 +1140,5 @@ inline constexpr bool type_contains_v<Array<T>, Array<U>> = type_contains_v<T, U
11401140
} // namespace details
11411141

11421142
} // namespace ffi
1143-
1144-
using ffi::Array;
11451143
} // namespace tvm
11461144
#endif // TVM_FFI_CONTAINER_ARRAY_H_

include/tvm/ffi/container/map.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1755,7 +1755,5 @@ inline constexpr bool type_contains_v<Map<K, V>, Map<KU, VU>> =
17551755
} // namespace details
17561756

17571757
} // namespace ffi
1758-
1759-
using ffi::Map;
17601758
} // namespace tvm
17611759
#endif // TVM_FFI_CONTAINER_MAP_H_

include/tvm/ffi/container/variant.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -298,7 +298,5 @@ template <typename... V, typename T>
298298
inline constexpr bool type_contains_v<Variant<V...>, T> = (type_contains_v<V, T> || ...);
299299
} // namespace details
300300
} // namespace ffi
301-
302-
using ffi::Variant;
303301
} // namespace tvm
304302
#endif // TVM_FFI_CONTAINER_VARIANT_H_

include/tvm/ffi/dtype.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,8 +38,6 @@ namespace ffi {
3838
* \brief Extension code beyond the DLDataType.
3939
*
4040
* This class is always consistent with the DLPack.
41-
*
42-
* TODO(tvm-team): update to latest DLPack types.
4341
*/
4442
enum DLExtDataTypeCode { kDLExtCustomBegin = 129 };
4543

include/tvm/ffi/memory.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -225,7 +225,5 @@ inline ObjectPtr<ArrayType> make_inplace_array_object(size_t num_elems, Args&&..
225225
}
226226

227227
} // namespace ffi
228-
229-
using ffi::make_object;
230228
} // namespace tvm
231229
#endif // TVM_FFI_MEMORY_H_

include/tvm/ffi/optional.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -410,7 +410,5 @@ class Optional<T, std::enable_if_t<use_ptr_based_optional_v<T>>> : public Object
410410
}
411411
};
412412
} // namespace ffi
413-
414-
using ffi::Optional;
415413
} // namespace tvm
416414
#endif // TVM_FFI_OPTIONAL_H_

include/tvm/ffi/string.h

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -993,9 +993,6 @@ inline std::ostream& operator<<(std::ostream& out, const String& input) {
993993
}
994994
/// \endcond
995995
} // namespace ffi
996-
997-
using ffi::Bytes;
998-
using ffi::String;
999996
} // namespace tvm
1000997

1001998
/// \cond Doxygen_Suppress

0 commit comments

Comments
 (0)