[svn:parrot] r38863 - in branches/pmc_pct: . compilers/vtdumper compilers/vtdumper/src compilers/vtdumper/src/parser compilers/vtdumper/t config/gen config/gen/makefiles
cotto at svn.parrot.org
cotto at svn.parrot.org
Sun May 17 04:05:54 UTC 2009
Author: cotto
Date: Sun May 17 04:05:43 2009
New Revision: 38863
URL: https://trac.parrot.org/parrot/changeset/38863
Log:
[vtdumper] start work on a PCT-based vtable.tbl parser/dumper
Added:
branches/pmc_pct/compilers/vtdumper/
branches/pmc_pct/compilers/vtdumper/src/
branches/pmc_pct/compilers/vtdumper/src/parser/
branches/pmc_pct/compilers/vtdumper/src/parser/actions.pm
branches/pmc_pct/compilers/vtdumper/src/parser/grammar.pg
branches/pmc_pct/compilers/vtdumper/t/
branches/pmc_pct/compilers/vtdumper/t/vtable.tbl
branches/pmc_pct/compilers/vtdumper/vtdumper.pir
branches/pmc_pct/config/gen/makefiles/vtdumper.in
Modified:
branches/pmc_pct/MANIFEST
branches/pmc_pct/config/gen/makefiles.pm
branches/pmc_pct/config/gen/makefiles/root.in
Modified: branches/pmc_pct/MANIFEST
==============================================================================
--- branches/pmc_pct/MANIFEST Sun May 17 03:06:17 2009 (r38862)
+++ branches/pmc_pct/MANIFEST Sun May 17 04:05:43 2009 (r38863)
@@ -1,7 +1,7 @@
# ex: set ro:
# $Id$
#
-# generated by tools/dev/mk_manifest_and_skip.pl Fri May 15 21:43:28 2009 UT
+# generated by tools/dev/mk_manifest_and_skip.pl Sun May 17 03:53:15 2009 UT
#
# See tools/dev/install_files.pl for documentation on the
# format of this file.
@@ -258,6 +258,10 @@
compilers/tge/TGE/Rule.pir [tge]
compilers/tge/TGE/Tree.pir [tge]
compilers/tge/tgc.pir [tge]
+compilers/vtdumper/src/parser/actions.pm [vtdumper]
+compilers/vtdumper/src/parser/grammar.pg [vtdumper]
+compilers/vtdumper/t/vtable.tbl [test]
+compilers/vtdumper/vtdumper.pir [vtdumper]
config/auto/alignptrs.pm []
config/auto/alignptrs/test_c.in []
config/auto/arch.pm []
@@ -388,6 +392,7 @@
config/gen/makefiles/pmcc.in []
config/gen/makefiles/root.in []
config/gen/makefiles/tge.in []
+config/gen/makefiles/vtdumper.in []
config/gen/opengl.pm []
config/gen/parrot_include.pm []
config/gen/platform.pm []
Added: branches/pmc_pct/compilers/vtdumper/src/parser/actions.pm
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ branches/pmc_pct/compilers/vtdumper/src/parser/actions.pm Sun May 17 04:05:43 2009 (r38863)
@@ -0,0 +1,16 @@
+# Copyright (C) 2009, Parrot Foundation.
+# $Id$
+
+class PMC::Grammar::Actions;
+
+method TOP($/) {
+ #say("TOP");
+ make $( $<pmc> );
+}
+
+
+# Local Variables:
+# mode: pir
+# fill-column: 100
+# End:
+# vim: expandtab shiftwidth=4:
Added: branches/pmc_pct/compilers/vtdumper/src/parser/grammar.pg
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ branches/pmc_pct/compilers/vtdumper/src/parser/grammar.pg Sun May 17 04:05:43 2009 (r38863)
@@ -0,0 +1,58 @@
+# Copyright (C) 2009, Parrot Foundation.
+# $Id$
+
+grammar VTable::Grammar is PCT::Grammar;
+
+token TOP {
+ <vtable_or_section>
+ [ $ || <panic: 'Syntax error'> ]
+ {*}
+}
+
+rule vtable_or_section {
+ [ <section> | <vtable_func> ]
+}
+
+rule section {
+ '[' <identifier> ']' <attribute>?
+ {{ say "found a section" }}
+}
+
+rule attribute {
+ ':' <identifier>
+ {{ say "found an attribute" }}
+}
+
+
+rule vtable_func {
+ <type> <identifier> '(' <args> ')' <attribute>?
+ {{ say "found a vtable function" }}
+}
+
+rule type {
+ [ 'struct' | 'union' ]? <identifier> '*'*
+ {{ say "found a type" }}
+}
+
+rule args {
+ [ <arg> [ ',' <args> ]
+ |
+ ]
+ {{ say "found args" }}
+}
+
+rule arg {
+ <type> <identifier>
+ {{ say "found an arg" }}
+}
+
+token identifier {
+ <.ident>
+}
+
+token ws {
+ [ '#' \N* \n
+ | \s+
+ ]*
+}
+
Added: branches/pmc_pct/compilers/vtdumper/t/vtable.tbl
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ branches/pmc_pct/compilers/vtdumper/t/vtable.tbl Sun May 17 04:05:43 2009 (r38863)
@@ -0,0 +1,366 @@
+# $Id: vtable.tbl 37201 2009-03-08 12:07:48Z fperrad $
+# [MAIN] #default section name
+
+# MMD_EQ ... MMD_STRCMP must be in one block
+# see src/multidispatch.c
+
+# INPLACE MMD variant must always be normal op + 1
+
+void init()
+# init must be first for JITed vtable meths
+void init_pmc(PMC* initializer)
+PMC* instantiate(PMC* sig)
+PMC* instantiate_str(STRING* rep, INTVAL flags)
+void morph(PMC* type) :write
+void mark()
+void destroy()
+PMC* get_namespace()
+
+# XXX FIXME should this be marked as writing?
+PMC* getprop(STRING* key)
+void setprop(STRING* key, PMC* value)
+void delprop(STRING* key)
+PMC* getprops()
+
+INTVAL type()
+INTVAL type_keyed(PMC* key)
+
+STRING* name()
+
+PMC* clone()
+PMC* clone_pmc(PMC* args)
+
+PMC* find_method(STRING* method_name)
+
+[FETCH]
+INTVAL get_integer()
+INTVAL get_integer_keyed(PMC* key)
+INTVAL get_integer_keyed_int(INTVAL key)
+INTVAL get_integer_keyed_str(STRING* key)
+
+FLOATVAL get_number()
+FLOATVAL get_number_keyed(PMC* key)
+FLOATVAL get_number_keyed_int(INTVAL key)
+FLOATVAL get_number_keyed_str(STRING* key)
+
+PMC* get_bignum()
+
+STRING* get_string()
+STRING* get_repr()
+STRING* get_string_keyed(PMC* key)
+STRING* get_string_keyed_int(INTVAL key)
+STRING* get_string_keyed_str(STRING* key)
+
+INTVAL get_bool()
+
+PMC* get_pmc()
+PMC* get_pmc_keyed(PMC* key)
+PMC* get_pmc_keyed_int(INTVAL key)
+PMC* get_pmc_keyed_str(STRING* key)
+PMC* slice(PMC* key, INTVAL flag)
+
+void* get_pointer()
+void* get_pointer_keyed(PMC* key)
+void* get_pointer_keyed_int(INTVAL key)
+void* get_pointer_keyed_str(STRING* key)
+
+[STORE] :write
+void set_integer_native(INTVAL value)
+void set_integer_same(PMC* value)
+void set_integer_keyed(PMC* key, INTVAL value)
+void set_integer_keyed_int(INTVAL key, INTVAL value)
+void set_integer_keyed_str(STRING* key, INTVAL value)
+
+void set_number_native(FLOATVAL value)
+void set_number_same(PMC* value)
+void set_number_keyed(PMC* key, FLOATVAL value)
+void set_number_keyed_int(INTVAL key, FLOATVAL value)
+void set_number_keyed_str(STRING* key, FLOATVAL value)
+
+void set_bignum_int(INTVAL value)
+void set_bignum_num(FLOATVAL value)
+void set_bignum_str(STRING* value)
+
+void set_string_native(STRING* value)
+void assign_string_native(STRING* value)
+void set_string_same(PMC* value)
+void set_string_keyed(PMC* key, STRING* value)
+void set_string_keyed_int(INTVAL key, STRING* value)
+void set_string_keyed_str(STRING* key, STRING* value)
+
+void set_bool(INTVAL value)
+
+void set_pmc(PMC* value)
+void assign_pmc(PMC* value)
+void set_pmc_keyed(PMC* key, PMC* value)
+void set_pmc_keyed_int(INTVAL key, PMC* value)
+void set_pmc_keyed_str(STRING* key, PMC* value)
+
+void set_pointer(void* value)
+void set_pointer_keyed(PMC* key, void* value)
+void set_pointer_keyed_int(INTVAL key, void* value)
+void set_pointer_keyed_str(STRING* key, void* value)
+
+[FETCHSIZE]
+INTVAL elements()
+
+[POP] :write
+INTVAL pop_integer()
+FLOATVAL pop_float()
+STRING* pop_string()
+PMC* pop_pmc()
+
+[PUSH] :write
+void push_integer(INTVAL value)
+void push_float(FLOATVAL value)
+void push_string(STRING* value)
+void push_pmc(PMC* value)
+
+[SHIFT] :write
+INTVAL shift_integer()
+FLOATVAL shift_float()
+STRING* shift_string()
+PMC* shift_pmc()
+
+[UNSHIFT] :write
+void unshift_integer(INTVAL value)
+void unshift_float(FLOATVAL value)
+void unshift_string(STRING* value)
+void unshift_pmc(PMC* value)
+
+## void splice ???
+
+[SPLICE] :write
+void splice(PMC* value, INTVAL offset, INTVAL count)
+
+# XXX marking writing here?
+[MATH]
+PMC* add(PMC* value, PMC* dest)
+PMC* add_int(INTVAL value, PMC* dest)
+PMC* add_float(FLOATVAL value, PMC* dest)
+
+void i_add(PMC* value) :write
+void i_add_int(INTVAL value) :write
+void i_add_float(FLOATVAL value) :write
+
+PMC* subtract(PMC* value, PMC* dest)
+PMC* subtract_int(INTVAL value, PMC* dest)
+PMC* subtract_float(FLOATVAL value, PMC* dest)
+
+void i_subtract(PMC* value) :write
+void i_subtract_int(INTVAL value) :write
+void i_subtract_float(FLOATVAL value) :write
+
+PMC* multiply(PMC* value, PMC* dest)
+PMC* multiply_int(INTVAL value, PMC* dest)
+PMC* multiply_float(FLOATVAL value, PMC* dest)
+
+void i_multiply(PMC* value) :write
+void i_multiply_int(INTVAL value) :write
+void i_multiply_float(FLOATVAL value) :write
+
+PMC* divide(PMC* value, PMC* dest)
+PMC* divide_int(INTVAL value, PMC* dest)
+PMC* divide_float(FLOATVAL value, PMC* dest)
+
+void i_divide(PMC* value) :write
+void i_divide_int(INTVAL value) :write
+void i_divide_float(FLOATVAL value) :write
+
+PMC* floor_divide(PMC* value, PMC* dest)
+PMC* floor_divide_int(INTVAL value, PMC* dest)
+PMC* floor_divide_float(FLOATVAL value, PMC* dest)
+
+void i_floor_divide(PMC* value) :write
+void i_floor_divide_int(INTVAL value) :write
+void i_floor_divide_float(FLOATVAL value) :write
+
+PMC* modulus(PMC* value, PMC* dest)
+PMC* modulus_int(INTVAL value, PMC* dest)
+PMC* modulus_float(FLOATVAL value, PMC* dest)
+
+void i_modulus(PMC* value) :write
+void i_modulus_int(INTVAL value) :write
+void i_modulus_float(FLOATVAL value) :write
+
+PMC* pow(PMC* value, PMC* dest)
+PMC* pow_int(INTVAL value, PMC* dest)
+PMC* pow_float(FLOATVAL value, PMC* dest)
+
+void i_pow(PMC* value) :write
+void i_pow_int(INTVAL value) :write
+void i_pow_float(FLOATVAL value) :write
+
+void increment() :write
+void decrement() :write
+
+PMC* absolute(PMC* dest)
+void i_absolute() :write
+
+PMC* neg(PMC* dest)
+void i_neg() :write
+
+[BITWISE]
+PMC* bitwise_or(PMC* value, PMC* dest)
+PMC* bitwise_or_int(INTVAL value, PMC* dest)
+
+void i_bitwise_or(PMC* value) :write
+void i_bitwise_or_int(INTVAL value) :write
+
+PMC* bitwise_and(PMC* value, PMC* dest)
+PMC* bitwise_and_int(INTVAL value, PMC* dest)
+
+void i_bitwise_and(PMC* value) :write
+void i_bitwise_and_int(INTVAL value) :write
+
+PMC* bitwise_xor(PMC* value, PMC* dest)
+PMC* bitwise_xor_int(INTVAL value, PMC* dest)
+
+void i_bitwise_xor(PMC* value) :write
+void i_bitwise_xor_int(INTVAL value) :write
+
+PMC* bitwise_ors(PMC* value, PMC* dest)
+PMC* bitwise_ors_str(STRING* value, PMC* dest)
+
+void i_bitwise_ors(PMC* value) :write
+void i_bitwise_ors_str(STRING* value) :write
+
+PMC* bitwise_ands(PMC* value, PMC* dest)
+PMC* bitwise_ands_str(STRING* value, PMC* dest)
+
+void i_bitwise_ands(PMC* value) :write
+void i_bitwise_ands_str(STRING* value) :write
+
+PMC* bitwise_xors(PMC* value, PMC* dest)
+PMC* bitwise_xors_str(STRING* value, PMC* dest)
+
+void i_bitwise_xors(PMC* value) :write
+void i_bitwise_xors_str(STRING* value) :write
+
+PMC* bitwise_not(PMC* dest)
+void i_bitwise_not() :write
+
+PMC* bitwise_nots(PMC* dest)
+void i_bitwise_nots() :write
+
+PMC* bitwise_shl(PMC* value, PMC* dest)
+PMC* bitwise_shl_int(INTVAL value, PMC* dest)
+
+void i_bitwise_shl(PMC* value) :write
+void i_bitwise_shl_int(INTVAL value) :write
+
+PMC* bitwise_shr(PMC* value, PMC* dest)
+PMC* bitwise_shr_int(INTVAL value, PMC* dest)
+
+void i_bitwise_shr(PMC* value) :write
+void i_bitwise_shr_int(INTVAL value) :write
+
+PMC* bitwise_lsr(PMC* value, PMC* dest)
+PMC* bitwise_lsr_int(INTVAL value, PMC* dest)
+
+void i_bitwise_lsr(PMC* value) :write
+void i_bitwise_lsr_int(INTVAL value) :write
+
+[CMP]
+INTVAL is_equal(PMC* value)
+INTVAL is_equal_num(PMC* value)
+INTVAL is_equal_string(PMC* value)
+
+INTVAL is_same(PMC* value)
+
+INTVAL cmp(PMC* value)
+INTVAL cmp_num(PMC* value)
+INTVAL cmp_string(PMC* value)
+PMC* cmp_pmc(PMC* value)
+
+PMC* logical_or(PMC* value, PMC* dest)
+
+PMC* logical_and(PMC* value, PMC* dest)
+
+PMC* logical_xor(PMC* value, PMC* dest)
+
+PMC* logical_not(PMC* dest)
+void i_logical_not() :write
+
+
+[STRING]
+PMC* concatenate(PMC* value, PMC* dest)
+PMC* concatenate_str(STRING* value, PMC* dest)
+
+void i_concatenate(PMC* value) :write
+void i_concatenate_str(STRING* value) :write
+
+PMC* repeat(PMC* value, PMC* dest)
+PMC* repeat_int(INTVAL value, PMC* dest)
+
+void i_repeat(PMC* value) :write
+void i_repeat_int(INTVAL value) :write
+
+void substr(INTVAL offset, INTVAL length, PMC* dest)
+STRING* substr_str(INTVAL offset, INTVAL length)
+
+[EXISTS]
+INTVAL exists_keyed(PMC* key)
+INTVAL exists_keyed_int(INTVAL key)
+INTVAL exists_keyed_str(STRING* key)
+
+[MAIN]
+INTVAL defined()
+INTVAL defined_keyed(PMC* key)
+INTVAL defined_keyed_int(INTVAL key)
+INTVAL defined_keyed_str(STRING* key)
+
+[DELETE] :write
+void delete_keyed(PMC* key)
+void delete_keyed_int(INTVAL key)
+void delete_keyed_str(STRING* key)
+
+[MAIN]
+PMC* nextkey_keyed(PMC* key, INTVAL what)
+PMC* nextkey_keyed_int(INTVAL key, INTVAL what)
+PMC* nextkey_keyed_str(STRING* key, INTVAL what)
+PMC* get_iter()
+
+opcode_t* invoke(void* next)
+
+INTVAL can(STRING* method)
+
+INTVAL does_pmc(PMC* role)
+INTVAL does(STRING* role)
+
+INTVAL isa_pmc(PMC* _class)
+INTVAL isa(STRING* _class)
+
+PMC* get_attr_str(STRING* idx)
+PMC* get_attr_keyed(PMC* key, STRING* idx)
+void set_attr_str(STRING* idx, PMC* value) :write
+void set_attr_keyed(PMC* key, STRING* idx, PMC* value) :write
+
+PMC* get_class()
+
+void add_parent(PMC* parent) :write
+void remove_parent(PMC* parent) :write
+
+void add_role(PMC* role) :write
+void remove_role(PMC* role) :write
+
+void add_attribute(STRING* name, PMC* type) :write
+void remove_attribute(STRING* name) :write
+
+void add_method(STRING* method_name, PMC* sub_pmc) :write
+void remove_method(STRING* method_name) :write
+
+void add_vtable_override(STRING* vtable_name, PMC* sub_pmc) :write
+void remove_vtable_override(STRING* vtable_name) :write
+
+PMC* inspect()
+PMC* inspect_str(STRING* what)
+
+void freeze(visit_info* info)
+void thaw (visit_info* info) :write
+void thawfinish (visit_info* info) :write
+void visit (visit_info* info)
+
+void share()
+
+PMC* share_ro()
Added: branches/pmc_pct/compilers/vtdumper/vtdumper.pir
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ branches/pmc_pct/compilers/vtdumper/vtdumper.pir Sun May 17 04:05:43 2009 (r38863)
@@ -0,0 +1,81 @@
+# Copyright (C) 2009, Parrot Foundation.
+# $Id$
+
+.namespace [ 'VTable';'Compiler' ]
+
+.sub '__onload' :load :init
+ load_bytecode 'PCT.pbc'
+ load_bytecode 'compilers/nqp/nqp.pbc'
+
+ .local pmc p6meta
+ p6meta = new 'P6metaclass'
+
+ p6meta.'new_class'('VTable::Compiler', 'parent'=>'PCT::HLLCompiler')
+
+ # Register grammar and action
+ $P0 = new [ 'VTable';'Compiler' ]
+ $P0.'language'('VTable')
+ $P0.'parsegrammar'('VTable::Grammar')
+ $P0.'parseactions'('VTable::Grammar::Actions')
+
+ #these stages aren't currently used, although generate_files exits before
+ #they can be called anyway
+ $P0.'removestage'('post')
+ $P0.'removestage'('pir')
+ $P0.'removestage'('evalpmc')
+
+ #add an extra stage to generate the c, h and dump files
+ #$P0.'addstage'('generate_dump', 'after'=>'past')
+
+.end
+
+
+.sub 'generate_dump' :method
+ .param pmc past
+ .param pmc adverbs :slurpy :named
+
+ exit 0
+.end
+
+
+.sub 'write_file'
+ .param string name
+ .param string contents
+
+ .local pmc fh
+ fh = new ['FileHandle']
+ fh.'open'(name, 'w')
+ print fh, contents
+ fh.'close'()
+ print "wrote output to "
+ say name
+ .return ()
+
+ cant_write:
+ .local pmc ex
+ .local string msg
+ .get_results (ex)
+ msg = ex
+ print "ERROR: couldn't open "
+ print name
+ print " for writing: "
+ say ex
+ .return ()
+
+.end
+
+
+.sub 'main' :main
+ .param pmc args
+ $P0 = compreg 'VTable'
+ .tailcall $P0.'command_line'(args, 'encoding'=>'utf8', 'transcode'=>'ascii')
+.end
+
+.include 'src/parser/gen_grammar.pir'
+.include 'src/parser/gen_actions.pir'
+
+# Local Variables:
+# mode: pir
+# fill-column: 100
+# End:
+# vim: expandtab shiftwidth=4 ft=pir:
Modified: branches/pmc_pct/config/gen/makefiles.pm
==============================================================================
--- branches/pmc_pct/config/gen/makefiles.pm Sun May 17 03:06:17 2009 (r38862)
+++ branches/pmc_pct/config/gen/makefiles.pm Sun May 17 04:05:43 2009 (r38863)
@@ -50,6 +50,8 @@
{ SOURCE => 'config/gen/makefiles/json.in' },
'compilers/pmcc/Makefile' =>
{ SOURCE => 'config/gen/makefiles/pmcc.in' },
+ 'compilers/vtdumper/Makefile' =>
+ { SOURCE => 'config/gen/makefiles/vtdumper.in' },
'compilers/pirc/Makefile' =>
{ SOURCE => 'config/gen/makefiles/pirc.in' },
'src/dynpmc/Makefile' =>
Modified: branches/pmc_pct/config/gen/makefiles/root.in
==============================================================================
--- branches/pmc_pct/config/gen/makefiles/root.in Sun May 17 03:06:17 2009 (r38862)
+++ branches/pmc_pct/config/gen/makefiles/root.in Sun May 17 04:05:43 2009 (r38863)
@@ -153,6 +153,7 @@
compilers/pge/Makefile \
compilers/tge/Makefile \
compilers/pmcc/Makefile \
+ compilers/vtdumper/Makefile \
editor/Makefile \
ext/Makefile \
src/dynoplibs/Makefile
@@ -1410,6 +1411,7 @@
$(MAKE) compilers/nqp
$(MAKE) compilers/json
$(MAKE) compilers/pmcc
+ $(MAKE) compilers/vtdumper
compilers-clean :
$(MAKE) compilers/pct clean
@@ -1419,6 +1421,7 @@
$(MAKE) compilers/json clean
$(MAKE) compilers/pirc clean
$(MAKE) compilers/pmcc clean
+ $(MAKE) compilers/vtdumper clean
###############################################################################
#
Added: branches/pmc_pct/config/gen/makefiles/vtdumper.in
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ branches/pmc_pct/config/gen/makefiles/vtdumper.in Sun May 17 04:05:43 2009 (r38863)
@@ -0,0 +1,79 @@
+# Copyright (C) 2007-2009, Parrot Foundation.
+# $Id$
+
+# Setup some commands
+PERL := @perl@
+RM_F := @rm_f@
+PARROT := ../../parrot at exe@
+
+BUILD_DIR := @build_dir@
+NQP := $(BUILD_DIR)/compilers/nqp/nqp.pbc
+PCT := $(BUILD_DIR)/runtime/parrot/library/PCT.pbc
+PARROT_LIBRARY := @build_dir@/runtime/parrot/library
+PGE_LIBRARY := @build_dir@/runtime/parrot/library/PGE
+
+all: vtdumper.pbc
+
+SOURCES := \
+ vtdumper.pir \
+ src/parser/gen_grammar.pir \
+ src/parser/gen_actions.pir \
+
+# the default target
+vtdumper.pbc: $(PARROT) $(PGE_LIBRARY)/Perl6Grammar.pir $(SOURCES)
+ $(PARROT) $(PARROT_ARGS) $(PGE_LIBRARY)/Perl6Grammar.pir \
+ --output=src/parser/gen_grammar.pir src/parser/grammar.pg
+ $(PARROT) -o vtdumper.pbc vtdumper.pir
+
+src/parser/gen_grammar.pir: $(PERL6GRAMMAR) src/parser/grammar.pg
+ $(PARROT) $(PARROT_ARGS) $(PERL6GRAMMAR) \
+ --output=src/parser/gen_grammar.pir \
+ src/parser/grammar.pg
+
+src/parser/gen_actions.pir: $(NQP) $(PCT) src/parser/actions.pm
+ $(PARROT) $(PARROT_ARGS) $(NQP) --output=src/parser/gen_actions.pir \
+ --target=pir src/parser/actions.pm
+
+# This is a listing of all targets, that are meant to be called by users
+help:
+ @echo ""
+ @echo "Following targets are available for the user:"
+ @echo ""
+ @echo " all: vtdumper.pbc"
+ @echo " This is the default."
+ @echo "Testing:"
+ @echo " test: Run the test suite."
+ @echo " testclean: Clean up test results."
+ @echo ""
+ @echo "Cleaning:"
+ @echo " clean: Basic cleaning up."
+ @echo " realclean: Removes also files generated by 'Configure.pl'"
+ @echo " distclean: Removes also anything built, in theory"
+ @echo ""
+ @echo "Misc:"
+ @echo " help: Print this help message."
+ @echo ""
+
+test: all
+ $(PERL) t/harness t
+
+# this target has nothing to do
+testclean:
+
+CLEANUPS := \
+ pmc.pbc \
+ src/parser/gen_grammar.pir \
+ src/parser/gen_actions.pir \
+
+clean:
+ $(RM_F) $(CLEANUPS)
+
+realclean: clean
+ $(RM_F) Makefile
+
+distclean: realclean
+
+# Local variables:
+# mode: makefile
+# End:
+# vim: ft=make:
More information about the parrot-commits
mailing list