Commit 7685421
committed
Factor out the productions for functor parameters.
Functor parameters can occur in three contexts:
(1) in functor bindings:
module M (X : S) (Y : T) = ...
(2) in anonymous functor expressionms:
functor (X : S) (Y : T) -> ...
(3) in signature expressions
module type T = functor (X : S) (Y : T) -> ...
This patch simplifies the grammar by using common productions
(functor_arg, functor_args) to handle all three contexts, and by
combining the productions for named and unnamed parameters.
As a side effect, unnamed functor arguments are now available in
functor bindings:
module M (_ : S) (_ : T) = ...1 parent eeae918 commit 7685421
1 file changed
+14
-29
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
535 | 535 | | |
536 | 536 | | |
537 | 537 | | |
538 | | - | |
| 538 | + | |
539 | 539 | | |
540 | 540 | | |
541 | | - | |
| 541 | + | |
542 | 542 | | |
543 | | - | |
544 | | - | |
545 | 543 | | |
546 | 544 | | |
547 | | - | |
548 | | - | |
| 545 | + | |
| 546 | + | |
| 547 | + | |
| 548 | + | |
| 549 | + | |
| 550 | + | |
| 551 | + | |
549 | 552 | | |
550 | | - | |
| 553 | + | |
551 | 554 | | |
552 | 555 | | |
553 | 556 | | |
| |||
558 | 561 | | |
559 | 562 | | |
560 | 563 | | |
561 | | - | |
| 564 | + | |
562 | 565 | | |
563 | 566 | | |
564 | 567 | | |
| |||
663 | 666 | | |
664 | 667 | | |
665 | 668 | | |
666 | | - | |
667 | | - | |
668 | | - | |
669 | | - | |
| 669 | + | |
| 670 | + | |
670 | 671 | | |
671 | 672 | | |
672 | 673 | | |
| |||
679 | 680 | | |
680 | 681 | | |
681 | 682 | | |
682 | | - | |
683 | | - | |
684 | | - | |
685 | | - | |
686 | | - | |
687 | | - | |
688 | | - | |
689 | | - | |
690 | | - | |
691 | | - | |
692 | | - | |
693 | | - | |
694 | | - | |
695 | | - | |
696 | | - | |
697 | | - | |
698 | 683 | | |
699 | 684 | | |
700 | 685 | | |
701 | 686 | | |
702 | 687 | | |
703 | 688 | | |
704 | 689 | | |
705 | | - | |
| 690 | + | |
706 | 691 | | |
707 | 692 | | |
708 | 693 | | |
| |||
0 commit comments