X-Git-Url: https://www.ginac.de/ginac.git//ginac.git?p=ginac.git;a=blobdiff_plain;f=ginac%2Ftensor.cpp;h=3de3a959043b22d3ac35897f904624462c98d7cd;hp=c215237d85f9d1225913b7fff4f87e59e0bc8134;hb=d2de9f5307c47adb2df13359002d987653c38a6a;hpb=690cd58cc13ad5052eb5851c573984965d0c40c1 diff --git a/ginac/tensor.cpp b/ginac/tensor.cpp index c215237d..3de3a959 100644 --- a/ginac/tensor.cpp +++ b/ginac/tensor.cpp @@ -3,7 +3,7 @@ * Implementation of GiNaC's special tensors. */ /* - * GiNaC Copyright (C) 1999-2006 Johannes Gutenberg University Mainz, Germany + * GiNaC Copyright (C) 1999-2007 Johannes Gutenberg University Mainz, Germany * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -395,6 +395,8 @@ bool tensor::replace_contr_index(exvector::iterator self, exvector::iterator oth again: if (self_idx->is_symbolic()) { for (size_t i=1; inops(); i++) { + if (! is_a(other->op(i))) + continue; const idx &other_idx = ex_to(other->op(i)); if (is_dummy_pair(*self_idx, other_idx)) {