| 4771 | } |
| 4772 | |
| 4773 | void BeginSwitch(const char* pos) |
| 4774 | { |
| 4775 | CodeInfo::lastKnownStartPos = pos; |
| 4776 | assert(CodeInfo::nodeList.size() >= 1); |
| 4777 | assert(cycleDepth.size() != 0); |
| 4778 | cycleDepth.back()++; |
| 4779 | |
| 4780 | BeginBlock(); |
| 4781 | |
| 4782 | TypeInfo *type = CodeInfo::nodeList.back()->typeInfo; |
| 4783 | if(type->type == TypeInfo::TYPE_COMPLEX && type != typeObject && type != typeTypeid) |
| 4784 | { |
| 4785 | AddInplaceVariable(pos); |
| 4786 | CodeInfo::nodeList.push_back(new NodeDereference()); |
| 4787 | CodeInfo::nodeList.push_back(new NodeSwitchExpr(true)); |
| 4788 | }else{ |
| 4789 | CodeInfo::nodeList.push_back(new NodeSwitchExpr()); |
| 4790 | } |
| 4791 | } |
| 4792 | |
| 4793 | void AddCaseNode(const char* pos) |
| 4794 | { |
no test coverage detected