Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-4331339

jdb restores function stack after set or eval

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Duplicate
    • Icon: P3 P3
    • None
    • 1.3.0
    • core-svc
    • generic
    • generic

      Any time user want to evaluate variable or change value, jdb will restore functions stack.

      class FunctionStack {

          static int amountOfCalls;

          FunctionStack (int _amountOfCalls) {
              amountOfCalls = _amountOfCalls;
          }

          int MakeStack(int stLevel) {
              if (stLevel < amountOfCalls)
                  this.MakeStack(++stLevel);
              System.out.println("Level: " + stLevel);
              return stLevel;
          }
          
          public static void main(String args[]) {
              FunctionStack fs = new FunctionStack(20);
              fs.MakeStack(0);
          }
      }

      To reproduce:

      stop at FunctionStack:14
      run FunctionStack
      where
      up
      up
      up
      up
      where
      eval stLevel
      where

            Unassigned Unassigned
            avolkovorcl Alexei Volkov (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: