| Index: src/fast-codegen.h
|
| ===================================================================
|
| --- src/fast-codegen.h (revision 3181)
|
| +++ src/fast-codegen.h (working copy)
|
| @@ -39,7 +39,12 @@
|
| class FastCodeGenerator: public AstVisitor {
|
| public:
|
| FastCodeGenerator(MacroAssembler* masm, Handle<Script> script, bool is_eval)
|
| - : masm_(masm), function_(NULL), script_(script), is_eval_(is_eval) {
|
| + : masm_(masm),
|
| + function_(NULL),
|
| + script_(script),
|
| + is_eval_(is_eval),
|
| + true_label_(NULL),
|
| + false_label_(NULL) {
|
| }
|
|
|
| static Handle<Code> MakeCode(FunctionLiteral* fun,
|
| @@ -59,6 +64,10 @@
|
| // If destination is TOS, just overwrite TOS with source.
|
| void DropAndMove(Expression::Context destination, Register source);
|
|
|
| + // Test the JavaScript value in source as if in a test context, compile
|
| + // control flow to a pair of labels.
|
| + void TestAndBranch(Register source, Label* true_label, Label* false_label);
|
| +
|
| void VisitDeclarations(ZoneList<Declaration*>* declarations);
|
| Handle<JSFunction> BuildBoilerplate(FunctionLiteral* fun);
|
| void DeclareGlobals(Handle<FixedArray> pairs);
|
| @@ -81,6 +90,9 @@
|
| Handle<Script> script_;
|
| bool is_eval_;
|
|
|
| + Label* true_label_;
|
| + Label* false_label_;
|
| +
|
| DISALLOW_COPY_AND_ASSIGN(FastCodeGenerator);
|
| };
|
|
|
|
|