Closed Bug 61579 Opened 24 years ago Closed 22 years ago

context.decompileScript doesn't work.

Categories

(Rhino Graveyard :: Core, defect, P3)

defect

Tracking

(Not tracked)

VERIFIED DUPLICATE of bug 114583

People

(Reporter: mike+mozilla, Assigned: beard)

Details

ysageev@yahoo.com
Subject: Rhino question

Hi Norris,

I am messing around with Rhino right now and am trying
to get context.decompileScript() to return something
more meaningful.  Right now it just returns:

 function () {
    [native code]
 }


The actual script that is read in is:

function g() {
        'Goodbye world';
}

'Hello World'; 

--Yair



And from a later message:

The code is very simple:

...
File scriptFile = new File(fullName);
FileReader reader = new FileReader(scriptFile);
Context cx = Context.enter();
//cx.setOptomizationLevel(9); or -1 
_compiledScript  = cx.compileReader(null, reader,
_name, 0, null);
cx.exit();
...


Also, I tried running the code with the JIT disabled,
and that didn't help.
Reassigning Mike's Rhino bugs to Patrick, as per recent meeting - 
Assignee: mike+mozilla → beard
In the Rhino shell, on the tip, entering a function, and then evaluation the 
function's name does return the full source code of the function. So, it should 
work. What exactly is your code trying to do?
This is the same as already fixed bug 114583: previously it was necessary to
evaluate a script before decompile can be called.

*** This bug has been marked as a duplicate of 114583 ***
Status: NEW → RESOLVED
Closed: 22 years ago
Resolution: --- → DUPLICATE
Marking Verified -
Status: RESOLVED → VERIFIED
Targeting as resolved against 1.5R4
Target Milestone: --- → 1.5R4
You need to log in before you can comment on or make changes to this bug.