/[escript]/branches/arrayview_from_1695_trunk/escript/src/DataArrayView.cpp
ViewVC logotype

Diff of /branches/arrayview_from_1695_trunk/escript/src/DataArrayView.cpp

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 757 by woo409, Mon Jun 26 13:12:56 2006 UTC revision 856 by gross, Tue Sep 26 01:00:36 2006 UTC
# Line 661  DataArrayView::toString(const string& su Line 661  DataArrayView::toString(const string& su
661        break;        break;
662      case 1:      case 1:
663        for (int i=0;i<getShape()[0];i++) {        for (int i=0;i<getShape()[0];i++) {
664      temp << "(" << i << ") " << finalSuffix << (*this)(i);      temp << finalSuffix << "(" << i << ") " << (*this)(i);
665      if (i!=(getShape()[0]-1)) {      if (i!=(getShape()[0]-1)) {
666        temp << endl;        temp << endl;
667      }      }
# Line 670  DataArrayView::toString(const string& su Line 670  DataArrayView::toString(const string& su
670      case 2:      case 2:
671        for (int i=0;i<getShape()[0];i++) {        for (int i=0;i<getShape()[0];i++) {
672      for (int j=0;j<getShape()[1];j++) {      for (int j=0;j<getShape()[1];j++) {
673        temp << "(" << i << "," << j << ") " << finalSuffix << (*this)(i,j);        temp << finalSuffix << "(" << i << "," << j << ") " << (*this)(i,j);
674        if (!(i==(getShape()[0]-1) && j==(getShape()[1]-1))) {        if (!(i==(getShape()[0]-1) && j==(getShape()[1]-1))) {
675          temp << endl;          temp << endl;
676        }        }
# Line 681  DataArrayView::toString(const string& su Line 681  DataArrayView::toString(const string& su
681        for (int i=0;i<getShape()[0];i++) {        for (int i=0;i<getShape()[0];i++) {
682      for (int j=0;j<getShape()[1];j++) {      for (int j=0;j<getShape()[1];j++) {
683        for (int k=0;k<getShape()[2];k++) {        for (int k=0;k<getShape()[2];k++) {
684          temp << "(" << i << "," << j << "," << k << ") " << finalSuffix << (*this)(i,j,k);          temp << finalSuffix << "(" << i << "," << j << "," << k << ") " << (*this)(i,j,k);
685          if (!(i==(getShape()[0]-1) && j==(getShape()[1]-1) && k==(getShape()[2]-1))) {          if (!(i==(getShape()[0]-1) && j==(getShape()[1]-1) && k==(getShape()[2]-1))) {
686            temp << endl;            temp << endl;
687          }          }
# Line 694  DataArrayView::toString(const string& su Line 694  DataArrayView::toString(const string& su
694      for (int j=0;j<getShape()[1];j++) {      for (int j=0;j<getShape()[1];j++) {
695        for (int k=0;k<getShape()[2];k++) {        for (int k=0;k<getShape()[2];k++) {
696          for (int l=0;l<getShape()[3];l++) {          for (int l=0;l<getShape()[3];l++) {
697            temp << "(" << i << "," << j << "," << k << "," << l << ") " << finalSuffix << (*this)(i,j,k,l);            temp << finalSuffix << "(" << i << "," << j << "," << k << "," << l << ") " << (*this)(i,j,k,l);
698            if (!(i==(getShape()[0]-1) && j==(getShape()[1]-1) && k==(getShape()[2]-1) && l==(getShape()[3]-1))) {            if (!(i==(getShape()[0]-1) && j==(getShape()[1]-1) && k==(getShape()[2]-1) && l==(getShape()[3]-1))) {
699              temp << endl;              temp << endl;
700            }            }

Legend:
Removed from v.757  
changed lines
  Added in v.856

  ViewVC Help
Powered by ViewVC 1.1.26