public static Stella_Object expandBquoteTree(Stella_Object tree) {
    if (Stella_Object.safePrimaryType(tree) == Stella.SGT_STELLA_CONS) {
      { Cons tree000 = ((Cons)(tree));

        { Cons expandedtree = Cons.cons(Stella.SYM_STELLA_LIST$, Stella.NIL);
          Cons cursor = tree000;
          Stella_Object term = cursor.value;

          while ((!(cursor == Stella.NIL)) &&
              (!((term == Stella.SYM_STELLA_a) ||
              (term == Stella.SYM_STELLA_aa)))) {
            expandedtree = Cons.cons(Stella_Object.expandBquoteTree(term), expandedtree);
            cursor = cursor.rest;
            term = cursor.value;
          }
          if (cursor == Stella.NIL) {
            return (Cons.cons(Stella.SYM_STELLA_NIL, expandedtree).reverse());
          }
          else if (term == Stella.SYM_STELLA_a) {
            cursor = cursor.rest;
            if (cursor == Stella.NIL) {
              { Object old$PrintreadablyP$000 = Stella.$PRINTREADABLYp$.get();

                try {
                  Native.setBooleanSpecial(Stella.$PRINTREADABLYp$, true);
                  Stella.signalTranslationError();
                  if (!(Stella.suppressWarningsP())) {
                    Stella.printErrorContext(">> ERROR: ", Stella.STANDARD_ERROR);
                    {
                      Stella.STANDARD_ERROR.nativeStream.println();
                      Stella.STANDARD_ERROR.nativeStream.println(" Illegal bquote tree -- missing term after '&'..");
                    }
;
                  }

                } finally {
                  Stella.$PRINTREADABLYp$.set(old$PrintreadablyP$000);
                }
              }
            }
            return (Cons.cons(Stella_Object.expandBquoteTree(cursor.rest), Cons.cons(cursor.value, expandedtree)).reverse());
          }
          else {
            cursor = cursor.rest;
            if (cursor == Stella.NIL) {
              { Object old$PrintreadablyP$001 = Stella.$PRINTREADABLYp$.get();

                try {
                  Native.setBooleanSpecial(Stella.$PRINTREADABLYp$, true);
                  Stella.signalTranslationError();
                  if (!(Stella.suppressWarningsP())) {
                    Stella.printErrorContext(">> ERROR: ", Stella.STANDARD_ERROR);
                    {
                      Stella.STANDARD_ERROR.nativeStream.println();
                      Stella.STANDARD_ERROR.nativeStream.println(" Illegal bquote tree -- missing term after '&&'.");
                    }
;
                  }

                } finally {
                  Stella.$PRINTREADABLYp$.set(old$PrintreadablyP$001);
                }
              }
            }
            return (Cons.cons(Cons.consList(Cons.cons(Stella.SYM_STELLA_CONCATENATE, Cons.cons(cursor.value, Cons.cons(Stella_Object.expandBquoteTree(cursor.rest), Stella.NIL)))), expandedtree).reverse());
          }
        }
      }
    }
    else {
      return (Stella_Object.bquotify(tree));
    }
  }