@@ -560,6 +560,15 @@ export class OCaml implements basis.ILanguage {
560560 4 : { name : Scope . PUNCTUATION_EQUALS ( ) } ,
561561 } ,
562562 patterns : [
563+ {
564+ begin : lastWords ( Token . REC ) ,
565+ end : alt ( capture ( this . identLower ( ) ) , lookAhead ( complement ( Class . space , Class . alpha ) ) ) ,
566+ endCaptures : {
567+ 0 : { name : Scope . NAME_FUNCTION ( ) } ,
568+ } ,
569+ patterns : [ include ( this . bindTermArgs ) ] ,
570+ } ,
571+ include ( this . bindTermArgs ) ,
563572 {
564573 begin : alt ( this . lastOps ( "!" ) , lastWords ( Token . AND , Token . EXTERNAL , Token . LET , Token . METHOD , Token . VAL ) ) ,
565574 end : alt (
@@ -579,15 +588,6 @@ export class OCaml implements basis.ILanguage {
579588 } ,
580589 patterns : [ include ( this . attributeIdentifier ) , include ( this . comment ) ] ,
581590 } ,
582- {
583- begin : lastWords ( Token . REC ) ,
584- end : alt ( capture ( this . identLower ( ) ) , lookAhead ( complement ( Class . space , Class . alpha ) ) ) ,
585- endCaptures : {
586- 0 : { name : Scope . NAME_FUNCTION ( ) } ,
587- } ,
588- patterns : [ include ( this . bindTermArgs ) ] ,
589- } ,
590- include ( this . bindTermArgs ) ,
591591 ] ,
592592 } ,
593593 {
@@ -960,7 +960,7 @@ export class OCaml implements basis.ILanguage {
960960 endCaptures : {
961961 0 : { name : Scope . STYLE_DELIMITER ( ) } ,
962962 } ,
963- patterns : [ include ( this . comment ) , include ( this . pragma ) , include ( this . bindTerm ) ] ,
963+ patterns : [ include ( this . pragma ) , include ( this . bindTerm ) , include ( this . comment ) ] ,
964964 } ;
965965 }
966966
0 commit comments