Mercurial > projects > ldc
comparison dmd/statement.h @ 875:330f999ade44
Merged DMD 1.038
author | Tomas Lindquist Olsen <tomas.l.olsen@gmail.com> |
---|---|
date | Tue, 06 Jan 2009 16:33:51 +0100 |
parents | a58784e0f035 |
children | 545f54041d91 |
comparison
equal
deleted
inserted
replaced
874:2ddee23bd70e | 875:330f999ade44 |
---|---|
146 virtual Statement *semantic(Scope *sc); | 146 virtual Statement *semantic(Scope *sc); |
147 Statement *semanticScope(Scope *sc, Statement *sbreak, Statement *scontinue); | 147 Statement *semanticScope(Scope *sc, Statement *sbreak, Statement *scontinue); |
148 virtual int hasBreak(); | 148 virtual int hasBreak(); |
149 virtual int hasContinue(); | 149 virtual int hasContinue(); |
150 virtual int usesEH(); | 150 virtual int usesEH(); |
151 virtual int fallOffEnd(); | |
152 virtual int blockExit(); | 151 virtual int blockExit(); |
153 virtual int comeFrom(); | 152 virtual int comeFrom(); |
154 virtual void scopeCode(Statement **sentry, Statement **sexit, Statement **sfinally); | 153 virtual void scopeCode(Statement **sentry, Statement **sexit, Statement **sfinally); |
155 virtual Statements *flatten(Scope *sc); | 154 virtual Statements *flatten(Scope *sc); |
156 virtual Expression *interpret(InterState *istate); | 155 virtual Expression *interpret(InterState *istate); |
177 ExpStatement(Loc loc, Expression *exp); | 176 ExpStatement(Loc loc, Expression *exp); |
178 Statement *syntaxCopy(); | 177 Statement *syntaxCopy(); |
179 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); | 178 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); |
180 Statement *semantic(Scope *sc); | 179 Statement *semantic(Scope *sc); |
181 Expression *interpret(InterState *istate); | 180 Expression *interpret(InterState *istate); |
182 int fallOffEnd(); | |
183 int blockExit(); | 181 int blockExit(); |
184 | 182 |
185 int inlineCost(InlineCostState *ics); | 183 int inlineCost(InlineCostState *ics); |
186 Expression *doInline(InlineDoState *ids); | 184 Expression *doInline(InlineDoState *ids); |
187 Statement *inlineScan(InlineScanState *iss); | 185 Statement *inlineScan(InlineScanState *iss); |
223 virtual Statement *syntaxCopy(); | 221 virtual Statement *syntaxCopy(); |
224 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); | 222 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); |
225 virtual Statement *semantic(Scope *sc); | 223 virtual Statement *semantic(Scope *sc); |
226 int usesEH(); | 224 int usesEH(); |
227 int blockExit(); | 225 int blockExit(); |
228 int fallOffEnd(); | |
229 int comeFrom(); | 226 int comeFrom(); |
230 virtual Statements *flatten(Scope *sc); | 227 virtual Statements *flatten(Scope *sc); |
231 ReturnStatement *isReturnStatement(); | 228 ReturnStatement *isReturnStatement(); |
232 Expression *interpret(InterState *istate); | 229 Expression *interpret(InterState *istate); |
233 | 230 |
253 Statement *semantic(Scope *sc); | 250 Statement *semantic(Scope *sc); |
254 int hasBreak(); | 251 int hasBreak(); |
255 int hasContinue(); | 252 int hasContinue(); |
256 int usesEH(); | 253 int usesEH(); |
257 int blockExit(); | 254 int blockExit(); |
258 int fallOffEnd(); | |
259 int comeFrom(); | 255 int comeFrom(); |
260 Expression *interpret(InterState *istate); | 256 Expression *interpret(InterState *istate); |
261 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); | 257 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); |
262 | 258 |
263 int inlineCost(InlineCostState *ics); | 259 int inlineCost(InlineCostState *ics); |
278 Statement *semantic(Scope *sc); | 274 Statement *semantic(Scope *sc); |
279 int hasBreak(); | 275 int hasBreak(); |
280 int hasContinue(); | 276 int hasContinue(); |
281 int usesEH(); | 277 int usesEH(); |
282 int blockExit(); | 278 int blockExit(); |
283 int fallOffEnd(); | |
284 int comeFrom(); | 279 int comeFrom(); |
285 Expression *interpret(InterState *istate); | 280 Expression *interpret(InterState *istate); |
286 | 281 |
287 Statement *inlineScan(InlineScanState *iss); | 282 Statement *inlineScan(InlineScanState *iss); |
288 | 283 |
300 Statement *semantic(Scope *sc); | 295 Statement *semantic(Scope *sc); |
301 int hasBreak(); | 296 int hasBreak(); |
302 int hasContinue(); | 297 int hasContinue(); |
303 int usesEH(); | 298 int usesEH(); |
304 int blockExit(); | 299 int blockExit(); |
305 int fallOffEnd(); | |
306 int comeFrom(); | 300 int comeFrom(); |
307 Expression *interpret(InterState *istate); | 301 Expression *interpret(InterState *istate); |
308 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); | 302 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); |
309 | 303 |
310 Statement *inlineScan(InlineScanState *iss); | 304 Statement *inlineScan(InlineScanState *iss); |
323 Statement *semantic(Scope *sc); | 317 Statement *semantic(Scope *sc); |
324 int hasBreak(); | 318 int hasBreak(); |
325 int hasContinue(); | 319 int hasContinue(); |
326 int usesEH(); | 320 int usesEH(); |
327 int blockExit(); | 321 int blockExit(); |
328 int fallOffEnd(); | |
329 int comeFrom(); | 322 int comeFrom(); |
330 Expression *interpret(InterState *istate); | 323 Expression *interpret(InterState *istate); |
331 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); | 324 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); |
332 | 325 |
333 Statement *inlineScan(InlineScanState *iss); | 326 Statement *inlineScan(InlineScanState *iss); |
349 void scopeCode(Statement **sentry, Statement **sexit, Statement **sfinally); | 342 void scopeCode(Statement **sentry, Statement **sexit, Statement **sfinally); |
350 int hasBreak(); | 343 int hasBreak(); |
351 int hasContinue(); | 344 int hasContinue(); |
352 int usesEH(); | 345 int usesEH(); |
353 int blockExit(); | 346 int blockExit(); |
354 int fallOffEnd(); | |
355 int comeFrom(); | 347 int comeFrom(); |
356 Expression *interpret(InterState *istate); | 348 Expression *interpret(InterState *istate); |
357 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); | 349 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); |
358 | 350 |
359 Statement *inlineScan(InlineScanState *iss); | 351 Statement *inlineScan(InlineScanState *iss); |
382 Statement *semantic(Scope *sc); | 374 Statement *semantic(Scope *sc); |
383 int hasBreak(); | 375 int hasBreak(); |
384 int hasContinue(); | 376 int hasContinue(); |
385 int usesEH(); | 377 int usesEH(); |
386 int blockExit(); | 378 int blockExit(); |
387 int fallOffEnd(); | |
388 int comeFrom(); | 379 int comeFrom(); |
389 Expression *interpret(InterState *istate); | 380 Expression *interpret(InterState *istate); |
390 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); | 381 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); |
391 | 382 |
392 Statement *inlineScan(InlineScanState *iss); | 383 Statement *inlineScan(InlineScanState *iss); |
411 Statement *semantic(Scope *sc); | 402 Statement *semantic(Scope *sc); |
412 int hasBreak(); | 403 int hasBreak(); |
413 int hasContinue(); | 404 int hasContinue(); |
414 int usesEH(); | 405 int usesEH(); |
415 int blockExit(); | 406 int blockExit(); |
416 int fallOffEnd(); | |
417 int comeFrom(); | 407 int comeFrom(); |
418 Expression *interpret(InterState *istate); | 408 Expression *interpret(InterState *istate); |
419 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); | 409 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); |
420 | 410 |
421 Statement *inlineScan(InlineScanState *iss); | 411 Statement *inlineScan(InlineScanState *iss); |
438 Statement *semantic(Scope *sc); | 428 Statement *semantic(Scope *sc); |
439 Expression *interpret(InterState *istate); | 429 Expression *interpret(InterState *istate); |
440 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); | 430 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); |
441 int usesEH(); | 431 int usesEH(); |
442 int blockExit(); | 432 int blockExit(); |
443 int fallOffEnd(); | |
444 IfStatement *isIfStatement() { return this; } | 433 IfStatement *isIfStatement() { return this; } |
445 | 434 |
446 int inlineCost(InlineCostState *ics); | 435 int inlineCost(InlineCostState *ics); |
447 Expression *doInline(InlineDoState *ids); | 436 Expression *doInline(InlineDoState *ids); |
448 Statement *inlineScan(InlineScanState *iss); | 437 Statement *inlineScan(InlineScanState *iss); |
475 PragmaStatement(Loc loc, Identifier *ident, Expressions *args, Statement *body); | 464 PragmaStatement(Loc loc, Identifier *ident, Expressions *args, Statement *body); |
476 Statement *syntaxCopy(); | 465 Statement *syntaxCopy(); |
477 Statement *semantic(Scope *sc); | 466 Statement *semantic(Scope *sc); |
478 int usesEH(); | 467 int usesEH(); |
479 int blockExit(); | 468 int blockExit(); |
480 int fallOffEnd(); | |
481 | 469 |
482 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); | 470 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); |
483 }; | 471 }; |
484 | 472 |
485 struct StaticAssertStatement : Statement | 473 struct StaticAssertStatement : Statement |
509 Statement *syntaxCopy(); | 497 Statement *syntaxCopy(); |
510 Statement *semantic(Scope *sc); | 498 Statement *semantic(Scope *sc); |
511 int hasBreak(); | 499 int hasBreak(); |
512 int usesEH(); | 500 int usesEH(); |
513 int blockExit(); | 501 int blockExit(); |
514 int fallOffEnd(); | |
515 Expression *interpret(InterState *istate); | 502 Expression *interpret(InterState *istate); |
516 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); | 503 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); |
517 | 504 |
518 Statement *inlineScan(InlineScanState *iss); | 505 Statement *inlineScan(InlineScanState *iss); |
519 | 506 |
531 Statement *syntaxCopy(); | 518 Statement *syntaxCopy(); |
532 Statement *semantic(Scope *sc); | 519 Statement *semantic(Scope *sc); |
533 int compare(Object *obj); | 520 int compare(Object *obj); |
534 int usesEH(); | 521 int usesEH(); |
535 int blockExit(); | 522 int blockExit(); |
536 int fallOffEnd(); | |
537 int comeFrom(); | 523 int comeFrom(); |
538 Expression *interpret(InterState *istate); | 524 Expression *interpret(InterState *istate); |
539 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); | 525 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); |
540 | 526 |
541 Statement *inlineScan(InlineScanState *iss); | 527 Statement *inlineScan(InlineScanState *iss); |
559 DefaultStatement(Loc loc, Statement *s); | 545 DefaultStatement(Loc loc, Statement *s); |
560 Statement *syntaxCopy(); | 546 Statement *syntaxCopy(); |
561 Statement *semantic(Scope *sc); | 547 Statement *semantic(Scope *sc); |
562 int usesEH(); | 548 int usesEH(); |
563 int blockExit(); | 549 int blockExit(); |
564 int fallOffEnd(); | |
565 int comeFrom(); | 550 int comeFrom(); |
566 Expression *interpret(InterState *istate); | 551 Expression *interpret(InterState *istate); |
567 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); | 552 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); |
568 | 553 |
569 Statement *inlineScan(InlineScanState *iss); | 554 Statement *inlineScan(InlineScanState *iss); |
582 GotoDefaultStatement(Loc loc); | 567 GotoDefaultStatement(Loc loc); |
583 Statement *syntaxCopy(); | 568 Statement *syntaxCopy(); |
584 Statement *semantic(Scope *sc); | 569 Statement *semantic(Scope *sc); |
585 Expression *interpret(InterState *istate); | 570 Expression *interpret(InterState *istate); |
586 int blockExit(); | 571 int blockExit(); |
587 int fallOffEnd(); | |
588 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); | 572 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); |
589 | 573 |
590 void toIR(IRState *irs); | 574 void toIR(IRState *irs); |
591 }; | 575 }; |
592 | 576 |
600 GotoCaseStatement(Loc loc, Expression *exp); | 584 GotoCaseStatement(Loc loc, Expression *exp); |
601 Statement *syntaxCopy(); | 585 Statement *syntaxCopy(); |
602 Statement *semantic(Scope *sc); | 586 Statement *semantic(Scope *sc); |
603 Expression *interpret(InterState *istate); | 587 Expression *interpret(InterState *istate); |
604 int blockExit(); | 588 int blockExit(); |
605 int fallOffEnd(); | |
606 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); | 589 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); |
607 | 590 |
608 void toIR(IRState *irs); | 591 void toIR(IRState *irs); |
609 }; | 592 }; |
610 | 593 |
611 struct SwitchErrorStatement : Statement | 594 struct SwitchErrorStatement : Statement |
612 { | 595 { |
613 SwitchErrorStatement(Loc loc); | 596 SwitchErrorStatement(Loc loc); |
614 int blockExit(); | 597 int blockExit(); |
615 int fallOffEnd(); | |
616 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); | 598 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); |
617 | 599 |
618 void toIR(IRState *irs); | 600 void toIR(IRState *irs); |
619 }; | 601 }; |
620 | 602 |
626 ReturnStatement(Loc loc, Expression *exp); | 608 ReturnStatement(Loc loc, Expression *exp); |
627 Statement *syntaxCopy(); | 609 Statement *syntaxCopy(); |
628 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); | 610 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); |
629 Statement *semantic(Scope *sc); | 611 Statement *semantic(Scope *sc); |
630 int blockExit(); | 612 int blockExit(); |
631 int fallOffEnd(); | |
632 Expression *interpret(InterState *istate); | 613 Expression *interpret(InterState *istate); |
633 | 614 |
634 int inlineCost(InlineCostState *ics); | 615 int inlineCost(InlineCostState *ics); |
635 Expression *doInline(InlineDoState *ids); | 616 Expression *doInline(InlineDoState *ids); |
636 Statement *inlineScan(InlineScanState *iss); | 617 Statement *inlineScan(InlineScanState *iss); |
648 BreakStatement(Loc loc, Identifier *ident); | 629 BreakStatement(Loc loc, Identifier *ident); |
649 Statement *syntaxCopy(); | 630 Statement *syntaxCopy(); |
650 Statement *semantic(Scope *sc); | 631 Statement *semantic(Scope *sc); |
651 Expression *interpret(InterState *istate); | 632 Expression *interpret(InterState *istate); |
652 int blockExit(); | 633 int blockExit(); |
653 int fallOffEnd(); | |
654 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); | 634 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); |
655 | 635 |
656 void toIR(IRState *irs); | 636 void toIR(IRState *irs); |
657 | 637 |
658 // LDC: only set if ident is set: label statement to jump to | 638 // LDC: only set if ident is set: label statement to jump to |
667 ContinueStatement(Loc loc, Identifier *ident); | 647 ContinueStatement(Loc loc, Identifier *ident); |
668 Statement *syntaxCopy(); | 648 Statement *syntaxCopy(); |
669 Statement *semantic(Scope *sc); | 649 Statement *semantic(Scope *sc); |
670 Expression *interpret(InterState *istate); | 650 Expression *interpret(InterState *istate); |
671 int blockExit(); | 651 int blockExit(); |
672 int fallOffEnd(); | |
673 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); | 652 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); |
674 | 653 |
675 void toIR(IRState *irs); | 654 void toIR(IRState *irs); |
676 | 655 |
677 // LDC: only set if ident is set: label statement to jump to | 656 // LDC: only set if ident is set: label statement to jump to |
689 Statement *semantic(Scope *sc); | 668 Statement *semantic(Scope *sc); |
690 int hasBreak(); | 669 int hasBreak(); |
691 int hasContinue(); | 670 int hasContinue(); |
692 int usesEH(); | 671 int usesEH(); |
693 int blockExit(); | 672 int blockExit(); |
694 int fallOffEnd(); | |
695 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); | 673 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); |
696 | 674 |
697 Statement *inlineScan(InlineScanState *iss); | 675 Statement *inlineScan(InlineScanState *iss); |
698 | 676 |
699 // Back end | 677 // Back end |
713 Statement *syntaxCopy(); | 691 Statement *syntaxCopy(); |
714 Statement *semantic(Scope *sc); | 692 Statement *semantic(Scope *sc); |
715 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); | 693 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); |
716 int usesEH(); | 694 int usesEH(); |
717 int blockExit(); | 695 int blockExit(); |
718 int fallOffEnd(); | |
719 | 696 |
720 Statement *inlineScan(InlineScanState *iss); | 697 Statement *inlineScan(InlineScanState *iss); |
721 | 698 |
722 void toIR(IRState *irs); | 699 void toIR(IRState *irs); |
723 }; | 700 }; |
731 Statement *syntaxCopy(); | 708 Statement *syntaxCopy(); |
732 Statement *semantic(Scope *sc); | 709 Statement *semantic(Scope *sc); |
733 int hasBreak(); | 710 int hasBreak(); |
734 int usesEH(); | 711 int usesEH(); |
735 int blockExit(); | 712 int blockExit(); |
736 int fallOffEnd(); | |
737 | 713 |
738 Statement *inlineScan(InlineScanState *iss); | 714 Statement *inlineScan(InlineScanState *iss); |
739 | 715 |
740 void toIR(IRState *irs); | 716 void toIR(IRState *irs); |
741 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); | 717 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); |
769 Statement *semantic(Scope *sc); | 745 Statement *semantic(Scope *sc); |
770 int hasBreak(); | 746 int hasBreak(); |
771 int hasContinue(); | 747 int hasContinue(); |
772 int usesEH(); | 748 int usesEH(); |
773 int blockExit(); | 749 int blockExit(); |
774 int fallOffEnd(); | |
775 | 750 |
776 Statement *inlineScan(InlineScanState *iss); | 751 Statement *inlineScan(InlineScanState *iss); |
777 | 752 |
778 void toIR(IRState *irs); | 753 void toIR(IRState *irs); |
779 }; | 754 }; |
801 ThrowStatement(Loc loc, Expression *exp); | 776 ThrowStatement(Loc loc, Expression *exp); |
802 Statement *syntaxCopy(); | 777 Statement *syntaxCopy(); |
803 Statement *semantic(Scope *sc); | 778 Statement *semantic(Scope *sc); |
804 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); | 779 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); |
805 int blockExit(); | 780 int blockExit(); |
806 int fallOffEnd(); | |
807 | 781 |
808 Statement *inlineScan(InlineScanState *iss); | 782 Statement *inlineScan(InlineScanState *iss); |
809 | 783 |
810 void toIR(IRState *irs); | 784 void toIR(IRState *irs); |
811 }; | 785 }; |
818 VolatileStatement(Loc loc, Statement *statement); | 792 VolatileStatement(Loc loc, Statement *statement); |
819 Statement *syntaxCopy(); | 793 Statement *syntaxCopy(); |
820 Statement *semantic(Scope *sc); | 794 Statement *semantic(Scope *sc); |
821 Statements *flatten(Scope *sc); | 795 Statements *flatten(Scope *sc); |
822 int blockExit(); | 796 int blockExit(); |
823 int fallOffEnd(); | |
824 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); | 797 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); |
825 | 798 |
826 Statement *inlineScan(InlineScanState *iss); | 799 Statement *inlineScan(InlineScanState *iss); |
827 | 800 |
828 void toIR(IRState *irs); | 801 void toIR(IRState *irs); |
837 | 810 |
838 GotoStatement(Loc loc, Identifier *ident); | 811 GotoStatement(Loc loc, Identifier *ident); |
839 Statement *syntaxCopy(); | 812 Statement *syntaxCopy(); |
840 Statement *semantic(Scope *sc); | 813 Statement *semantic(Scope *sc); |
841 int blockExit(); | 814 int blockExit(); |
842 int fallOffEnd(); | |
843 Expression *interpret(InterState *istate); | 815 Expression *interpret(InterState *istate); |
844 | 816 |
845 void toIR(IRState *irs); | 817 void toIR(IRState *irs); |
846 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); | 818 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); |
847 GotoStatement *isGotoStatement() { return this; } | 819 GotoStatement *isGotoStatement() { return this; } |
860 Statement *syntaxCopy(); | 832 Statement *syntaxCopy(); |
861 Statement *semantic(Scope *sc); | 833 Statement *semantic(Scope *sc); |
862 Statements *flatten(Scope *sc); | 834 Statements *flatten(Scope *sc); |
863 int usesEH(); | 835 int usesEH(); |
864 int blockExit(); | 836 int blockExit(); |
865 int fallOffEnd(); | |
866 int comeFrom(); | 837 int comeFrom(); |
867 Expression *interpret(InterState *istate); | 838 Expression *interpret(InterState *istate); |
868 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); | 839 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); |
869 | 840 |
870 Statement *inlineScan(InlineScanState *iss); | 841 Statement *inlineScan(InlineScanState *iss); |