// utility functions
-/** Return the tensor object handled by an ex. Deprecated: use ex_to<tensor>().
- * This is unsafe: you need to check the type first. */
-inline const tensor &ex_to_tensor(const ex &e)
-{
- return static_cast<const tensor &>(*e.bp);
-}
-
/** Create a delta tensor with specified indices. The indices must be of class
* idx or a subclass. The delta tensor is always symmetric and its trace is
* the dimension of the index space.