INFO: Problems with AV false positives are fixed in 25.0.0, now we sign our code and also use MSI installer type.
If you are looking for the decompiler itself, visit https://github.com/jindrapetrik/jpexs-decompiler
NEW : We have got a new blog where we post some interesting SWF internals info.
List of issues#2081 error on compile with object literal
Author:
3plus4i
3plus4iDate created:
Type: question
Visibility: Everybody
Assigned to:
State: closed 

> What steps will reproduce the problem?
I can't say for sure what actually causes the error, but what I tried to do was assigning
an object literal inside other curly brackets. When I try to save I get the error in the
attached image.
> What is the expected output? What do you see instead?
Not sure what to write here. An object declaration that should work. Unless I mad another
mistake, but the brackets do match up and the highlighting in the editor also recognizes
them correctly.
> What version of the product are you using? Is it "nightly build"? Which operating system
do you have?
18.5.0 Linux
> Please provide any additional information below. If the problem is related to a SWF
file, attach it here, otherwise we can't help you.
I'll also add the class initializer in which the error occurred
scr159.png (27 KiB)
Stats class initializer.as (1 KiB)I think this is correct version:
this.dungeons[i] = {entered: 0, failed: 0};
State: new→opened
Type: bug→question
Type: bug→question
Huh, I'll try that. Using the constructor worked as well, but I've learned that a literal
is executed faster. Not that it would matter in this specific case.
Yeah, it works. Why does the compiler replace the for loop with a while loop though, isn't
that significantly slower? I only did some shallow research on efficient coding though.
the for loop is just while loop with some init / precontinue parts, the p-code is
equivalent,
it cannot be distinguished while decompiling. It is not slower.
FFDec decompiles loops as fors only when there is continue/break logic that it can't be
any other variant.
I see, so I don't need to worry about that part. I actually tested the code now to see
whether it runs as well, and the for loop doesn't seem to be executed at all. I used the
constructor with the number of elements, can I not iterate over an array while it's
elements are empty? Trying to research that now.
I am not sure I understand.
Could you provide a sample code of what you trying to do again?
Also, I don't want to be a teacher of ActionScript,
I guess some basic knowledge of AS should be required to use FFDec.
I am only interested if I can fix some bugs in FFDec...
Makes sense. I should find a community for such questions and talking.
State: opened→closed
