Author: bernhard
Date: Mon Nov 10 07:13:43 2008
New Revision: 32486
Modified:
trunk/docs/memory_internals.pod
trunk/languages/pipp/src/pct/actions.pm
trunk/src/ops/core.ops
Log:
RT#60450: [PATCH] minor pod tweaks memory_internals.pod core.ops
Courtesy of Brad Bowman
Modified: trunk/docs/memory_internals.pod
==============================================================================
--- trunk/docs/memory_internals.pod (original)
+++ trunk/docs/memory_internals.pod Mon Nov 10 07:13:43 2008
@@ -24,14 +24,14 @@
=over 4
-=item* GC
+=item * GC
Garbage collector. A garbage collector is a system that finds memory objects
that are not being used by the system, and frees them automatically. Garbage
collection is broken into two distinct phases: the I<mark phase> that searches
for unreferenced objects, and the I<sweep phase> that frees all dead objects.
-=item* DOD
+=item * DOD
Dead object detection, a deprecated term that refers to the I<mark phase>
of the garbage collector.
Modified: trunk/languages/pipp/src/pct/actions.pm
==============================================================================
--- trunk/languages/pipp/src/pct/actions.pm (original)
+++ trunk/languages/pipp/src/pct/actions.pm Mon Nov 10 07:13:43 2008
@@ -19,12 +19,19 @@
class Pipp::Grammar::Actions;
+sub test_scope() {
+ our $?PIPP_SCOPE;
+ my $s := $?PIPP_SCOPE;
+ return $s;
+}
+
method TOP($/) {
my $past := PAST::Stmts.new( :node($/) );
for $<sea_or_code> {
$past.push( $($_) );
}
+ our $?PIPP_SCOPE := '____top';
make $past;
}
@@ -45,11 +52,14 @@
}
method code_short_tag($/) {
- my $past := PAST::Stmts.new( :node($/) );
+ #our $?PIPP_SCOPE := '___________code_short_tag';
+ my $past := PAST::Stmts.new( :node($/), :name( 'code_short_tag' ~
test_scope() ) );
for $<statement> {
$past.push( $($_) );
}
+ $past.name( 'code_short_tag_2_____' ~ test_scope() );
+
make $past;
}
@@ -77,6 +87,7 @@
}
method block($/) {
+ our $?PIPP_SCOPE := '___block';
my $past := PAST::Stmts.new( :node($/) );
for $<statement> {
$past.push( $($_) );
@@ -86,7 +97,15 @@
}
method statement($/,$key) {
- make $( $/{$key} );
+ our $?PIPP_SCOPE := '_____statement';
+ my $past;
+ if $key eq 'echo_statement' {
+ $past := $( $<echo_statement> );
+ }
+ else {
+ $past := $( $/{$key} );
+ }
+ make $past;
}
method inline_sea_short_tag($/) {
@@ -101,8 +120,9 @@
}
method echo_statement($/) {
+ #our $?PIPP_SCOPE := '________echo_statement';
my $past := $( $<arguments> );
- $past.name( 'echo' );
+ $past.name( 'echo' ~ '__scope:' ~ test_scope() );
make $past;
}
@@ -153,6 +173,7 @@
}
method arguments($/) {
+ # our $?PIPP_SCOPE := '________arguments';
my $past := PAST::Op.new(
:pasttype('call'),
:node($/)
@@ -201,6 +222,7 @@
}
method var($/,$key) {
+ # our $?PIPP_SCOPE := '________var';
make $( $/{$key} );
}
@@ -208,7 +230,7 @@
our $?PIPP_SCOPE;
make PAST::Var.new(
:scope( $?PIPP_SCOPE ?? $?PIPP_SCOPE !! 'package' ),
- :name(~$/),
+ :name(~$/ ~ 'xxxxx' ~ test_scope()),
:viviself('Undef'),
:lvalue(1),
);
@@ -257,6 +279,7 @@
# Handle the operator precedence table.
method expression($/, $key) {
+ # our $?PIPP_SCOPE := '________expression';
if ($key eq 'end') {
make $($<expr>);
}
Modified: trunk/src/ops/core.ops
==============================================================================
--- trunk/src/ops/core.ops (original)
+++ trunk/src/ops/core.ops Mon Nov 10 07:13:43 2008
@@ -541,7 +541,7 @@
For all of these opcodes the passed invar PMC constant is the string
representation of a FixedIntegerArray with one flag word per argument.
-The flags are documented currently in F<include/parrot/enum.h> only.
+The flags are documented currently in F<include/parrot/enums.h> only.
After this argument a variable amount of arguments must follow according
to the elements of the signature array.
@@ -784,6 +784,7 @@
Get a count of currently active exception handlers on the stack.
=item B<die>(in STR)
+
=item B<die>(in PMC)
Die with message $1