summaryrefslogtreecommitdiff
path: root/op.h
diff options
context:
space:
mode:
authorMalcolm Beattie <mbeattie@sable.ox.ac.uk>1997-10-29 12:43:36 +0000
committerMalcolm Beattie <mbeattie@sable.ox.ac.uk>1997-10-29 12:43:36 +0000
commitdb173bac9b6de7d701a38c2f8b62f2fce229ec77 (patch)
treefe1730ff818211017b2858e1bd7c7ebd08cd824c /op.h
parentf6d98b14fd224d7fe398ef16332eaa45bf13b92f (diff)
downloadperl-db173bac9b6de7d701a38c2f8b62f2fce229ec77.tar.gz
Move compiler OP class information into opcode.pl.
p4raw-id: //depot/perl@186
Diffstat (limited to 'op.h')
-rw-r--r--op.h19
1 files changed, 18 insertions, 1 deletions
diff --git a/op.h b/op.h
index f9dad977ef..ad208cfabb 100644
--- a/op.h
+++ b/op.h
@@ -271,7 +271,24 @@ struct loop {
#define OA_DANGEROUS 64
#define OA_DEFGV 128
-#define OASHIFT 8
+/* The next 4 bits encode op class information */
+#define OA_BASEOP (0 << 8)
+#define OA_UNOP (1 << 8)
+#define OA_BINOP (2 << 8)
+#define OA_LOGOP (3 << 8)
+#define OA_CONDOP (4 << 8)
+#define OA_LISTOP (5 << 8)
+#define OA_PMOP (6 << 8)
+#define OA_SVOP (7 << 8)
+#define OA_GVOP (8 << 8)
+#define OA_PVOP (9 << 8)
+#define OA_LOOP (10 << 8)
+#define OA_COP (11 << 8)
+#define OA_BASEOP_OR_UNOP (12 << 8)
+#define OA_FILESTATOP (13 << 8)
+#define OA_LOOPEXOP (14 << 8)
+
+#define OASHIFT 12
/* Remaining nybbles of opargs */
#define OA_SCALAR 1