From: <ha...@us...> - 2008-11-02 03:55:27
|
Revision: 10202 http://jmol.svn.sourceforge.net/jmol/?rev=10202&view=rev Author: hansonr Date: 2008-11-02 03:55:17 +0000 (Sun, 02 Nov 2008) Log Message: ----------- # new feature: Jmol math simple array definitions using brackets: x = [3,4,5,6] Modified Paths: -------------- trunk/Jmol/src/org/jmol/viewer/Eval.java Modified: trunk/Jmol/src/org/jmol/viewer/Eval.java =================================================================== --- trunk/Jmol/src/org/jmol/viewer/Eval.java 2008-11-01 22:21:53 UTC (rev 10201) +++ trunk/Jmol/src/org/jmol/viewer/Eval.java 2008-11-02 03:55:17 UTC (rev 10202) @@ -11980,6 +11980,10 @@ return true; case Token.leftsquare: // {....}[n][m] isLeftOp = true; + if (!wasX) { + squareCount++; + op = newOp = Token.tokenArray; + } break; case Token.minus: if (wasX) @@ -12031,13 +12035,6 @@ xStack[xPt] = Token.selectItem(xStack[xPt]); break; } - if (op.tok == Token.comma && oStack[oPt].tok == Token.leftsquare) { - // [x,y,z] - oStack[oPt] = Token.tokenArray; - newOp = xStack[xPt]; - xStack[xPt] = Token.tokenArray; - break; - } if (op.tok == Token.rightsquare && oStack[oPt].tok == Token.array) { break; } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |