Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

eliminate deprecated .meth_call PIR form

this is simply an outdated alias for .call
  • Loading branch information...
commit 9bdc32db4ab2135ad76ec27d46369e767ac17062 1 parent 0994a6b
@plobsing plobsing authored
View
1  compilers/imcc/imcc.l
@@ -308,7 +308,6 @@ SP [ ]
".begin_call" return PCC_BEGIN;
".end_call" return PCC_END;
".call" return PCC_CALL;
-".meth_call" return METH_CALL;
".invocant" return INVOCANT;
<emit,INITIAL>".pcc_sub" return PCC_SUB;
".begin_return" return PCC_BEGIN_RETURN;
View
21 compilers/imcc/imcc.y
@@ -1011,7 +1011,7 @@ do_loadlib(PARROT_INTERP, ARGIN(const char *lib))
%token <t> POW SHIFT_RIGHT_U LOG_AND LOG_OR
%token <t> COMMA ESUB DOTDOT
%token <t> PCC_BEGIN PCC_END PCC_CALL PCC_SUB PCC_BEGIN_RETURN PCC_END_RETURN
-%token <t> PCC_BEGIN_YIELD PCC_END_YIELD METH_CALL INVOCANT
+%token <t> PCC_BEGIN_YIELD PCC_END_YIELD INVOCANT
%token <t> MAIN LOAD INIT IMMEDIATE POSTCOMP METHOD ANON OUTER NEED_LEX
%token <t> MULTI VTABLE_METHOD LOADLIB SUB_INSTANCE_OF SUBID
%token <t> NS_ENTRY
@@ -1579,25 +1579,6 @@ pcc_call:
{
add_pcc_sub(IMCC_INFO(interp)->cur_call, $2);
}
- | METH_CALL target '\n'
- {
- add_pcc_sub(IMCC_INFO(interp)->cur_call, $2);
- }
- | METH_CALL STRINGC '\n'
- {
- add_pcc_sub(IMCC_INFO(interp)->cur_call, mk_const(interp, $2, 'S'));
- }
- | METH_CALL target COMMA var '\n'
- {
- add_pcc_sub(IMCC_INFO(interp)->cur_call, $2);
- add_pcc_cc(IMCC_INFO(interp)->cur_call, $4);
- }
- | METH_CALL STRINGC COMMA var '\n'
- {
- add_pcc_sub(IMCC_INFO(interp)->cur_call, mk_const(interp, $2, 'S'));
- add_pcc_cc(IMCC_INFO(interp)->cur_call, $4);
- }
- ;
pcc_args:
View
3,784 compilers/imcc/imclexer.c
1,888 additions, 1,896 deletions not shown
View
2,013 compilers/imcc/imcparser.c
986 additions, 1,027 deletions not shown
View
156 compilers/imcc/imcparser.h
@@ -126,45 +126,44 @@
PCC_END_RETURN = 332,
PCC_BEGIN_YIELD = 333,
PCC_END_YIELD = 334,
- METH_CALL = 335,
- INVOCANT = 336,
- MAIN = 337,
- LOAD = 338,
- INIT = 339,
- IMMEDIATE = 340,
- POSTCOMP = 341,
- METHOD = 342,
- ANON = 343,
- OUTER = 344,
- NEED_LEX = 345,
- MULTI = 346,
- VTABLE_METHOD = 347,
- LOADLIB = 348,
- SUB_INSTANCE_OF = 349,
- SUBID = 350,
- NS_ENTRY = 351,
- UNIQUE_REG = 352,
- LABEL = 353,
- EMIT = 354,
- EOM = 355,
- IREG = 356,
- NREG = 357,
- SREG = 358,
- PREG = 359,
- IDENTIFIER = 360,
- REG = 361,
- MACRO = 362,
- ENDM = 363,
- STRINGC = 364,
- INTC = 365,
- FLOATC = 366,
- USTRINGC = 367,
- PARROT_OP = 368,
- VAR = 369,
- LINECOMMENT = 370,
- FILECOMMENT = 371,
- DOT = 372,
- CONCAT = 373
+ INVOCANT = 335,
+ MAIN = 336,
+ LOAD = 337,
+ INIT = 338,
+ IMMEDIATE = 339,
+ POSTCOMP = 340,
+ METHOD = 341,
+ ANON = 342,
+ OUTER = 343,
+ NEED_LEX = 344,
+ MULTI = 345,
+ VTABLE_METHOD = 346,
+ LOADLIB = 347,
+ SUB_INSTANCE_OF = 348,
+ SUBID = 349,
+ NS_ENTRY = 350,
+ UNIQUE_REG = 351,
+ LABEL = 352,
+ EMIT = 353,
+ EOM = 354,
+ IREG = 355,
+ NREG = 356,
+ SREG = 357,
+ PREG = 358,
+ IDENTIFIER = 359,
+ REG = 360,
+ MACRO = 361,
+ ENDM = 362,
+ STRINGC = 363,
+ INTC = 364,
+ FLOATC = 365,
+ USTRINGC = 366,
+ PARROT_OP = 367,
+ VAR = 368,
+ LINECOMMENT = 369,
+ FILECOMMENT = 370,
+ DOT = 371,
+ CONCAT = 372
};
#endif
/* Tokens. */
@@ -245,45 +244,44 @@
#define PCC_END_RETURN 332
#define PCC_BEGIN_YIELD 333
#define PCC_END_YIELD 334
-#define METH_CALL 335
-#define INVOCANT 336
-#define MAIN 337
-#define LOAD 338
-#define INIT 339
-#define IMMEDIATE 340
-#define POSTCOMP 341
-#define METHOD 342
-#define ANON 343
-#define OUTER 344
-#define NEED_LEX 345
-#define MULTI 346
-#define VTABLE_METHOD 347
-#define LOADLIB 348
-#define SUB_INSTANCE_OF 349
-#define SUBID 350
-#define NS_ENTRY 351
-#define UNIQUE_REG 352
-#define LABEL 353
-#define EMIT 354
-#define EOM 355
-#define IREG 356
-#define NREG 357
-#define SREG 358
-#define PREG 359
-#define IDENTIFIER 360
-#define REG 361
-#define MACRO 362
-#define ENDM 363
-#define STRINGC 364
-#define INTC 365
-#define FLOATC 366
-#define USTRINGC 367
-#define PARROT_OP 368
-#define VAR 369
-#define LINECOMMENT 370
-#define FILECOMMENT 371
-#define DOT 372
-#define CONCAT 373
+#define INVOCANT 335
+#define MAIN 336
+#define LOAD 337
+#define INIT 338
+#define IMMEDIATE 339
+#define POSTCOMP 340
+#define METHOD 341
+#define ANON 342
+#define OUTER 343
+#define NEED_LEX 344
+#define MULTI 345
+#define VTABLE_METHOD 346
+#define LOADLIB 347
+#define SUB_INSTANCE_OF 348
+#define SUBID 349
+#define NS_ENTRY 350
+#define UNIQUE_REG 351
+#define LABEL 352
+#define EMIT 353
+#define EOM 354
+#define IREG 355
+#define NREG 356
+#define SREG 357
+#define PREG 358
+#define IDENTIFIER 359
+#define REG 360
+#define MACRO 361
+#define ENDM 362
+#define STRINGC 363
+#define INTC 364
+#define FLOATC 365
+#define USTRINGC 366
+#define PARROT_OP 367
+#define VAR 368
+#define LINECOMMENT 369
+#define FILECOMMENT 370
+#define DOT 371
+#define CONCAT 372
@@ -304,7 +302,7 @@ typedef union YYSTYPE
/* Line 1685 of yacc.c */
-#line 297 "compilers/imcc/imcparser.h"
+#line 295 "compilers/imcc/imcparser.h"
} YYSTYPE;
# define YYSTYPE_IS_TRIVIAL 1
# define yystype YYSTYPE /* obsolescent; will be withdrawn */
View
9 docs/book/draft/ch11_directive_reference.pod
@@ -116,15 +116,6 @@ X<.macro directive>
Define a named macro with a list of parameters. The macro is called as
.R<NAME>(R<arg1>,R<arg2>,...). Always paired with C<.endm>.
-=head3 .meth_call
-
-X<.meth_call directive>
-
- .meth_call R<SUB>
- .meth_call R<SUB>, R<RETCONT>
-
-Create a method call.
-
=head3 .namespace
X<.namespace directive>
View
11 docs/pdds/pdd19_pir.pod
@@ -623,12 +623,7 @@ outside of a loop and the call is done inside a loop.
=item .invocant
Directive to specify the object for a method call. Use it in combination
-with C<.meth_call>.
-
-=item .meth_call
-
-Directive to do a method call. It calls the specified method on the object
-that was specified with the C<.invocant> directive.
+with C<.call> to call methods.
=item .set_return <var> [:<modifier>]*
@@ -1342,7 +1337,7 @@ subroutine declaration contains "method".
=head3 Calling Methods
The syntax is very similar to subroutine calls. The call is done with
-C<.meth_call> which must immediately be preceded by the C<.invocant>:
+C<.call> immediately preceded by C<.invocant>:
=begin PIR_FRAGMENT_TODO
@@ -1355,7 +1350,7 @@ C<.meth_call> which must immediately be preceded by the C<.invocant>:
.set_arg y
.set_arg z
.invocant obj
- .meth_call "method" [, $P1 ] # r = obj."method"(x, y, z)
+ .call "method" [, $P1 ] # r = obj."method"(x, y, z)
.local int r # optional - new result var
.get_result r
.end_call
View
2  editor/pir-mode.el
@@ -228,7 +228,7 @@ newline or semicolon after an end keyword."
(defvar pir-dotted-directives
'(".HLL" ".arg" ".const" ".constant" ".emit" ".end" ".endm"
".endnamespace" ".eom" ".get_results" ".global" ".globalconst"
- ".include" ".invocant" ".lex" ".line" ".loadlib" ".macro" ".meth_call"
+ ".include" ".invocant" ".lex" ".line" ".loadlib" ".macro"
".namespace" ".nci_call" ".pcc_begin" ".pcc_begin_return"
".pcc_begin_yield" ".pcc_call" ".pcc_end" ".pcc_end_return"
".pcc_end_yield" ".pcc_sub" ".result" ".return" ".sub"
Please sign in to comment.
Something went wrong with that request. Please try again.