Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

add introspection method get_multisig

git-svn-id: https://svn.parrot.org/parrot/trunk@11963 d31e2699-5ff4-0310-a27c-f18f2fbe73fe
  • Loading branch information...
commit 1415cdab25851975b9a2440579a133eb239b29c4 1 parent 0626ae0
Leopold Toetsch authored
Showing with 22 additions and 0 deletions.
  1. +14 −0 src/pmc/nci.pmc
  2. +8 −0 src/pmc/sub.pmc
View
14 src/pmc/nci.pmc
@@ -28,6 +28,20 @@ pmclass NCI need_ext {
/*
+=item C<METHOD PMC* get_multisig()>
+
+Return the MMD signature PMC, if any or a Null PMC.
+
+=cut
+
+*/
+
+ METHOD PMC* get_multisig() {
+ return PMC_pmc_val(SELF) ? PMC_pmc_val(SELF) : PMCNULL;
+ }
+
+/*
+
=item C<void init()>
Initializes the NCI with a C<NULL> function pointer.
View
8 src/pmc/sub.pmc
@@ -525,6 +525,10 @@ Return amount of used registers for register kinds "I", "S", "P", "N".
Return the LexInfo PMC, if any or a Null PMC.
+=item C<METHOD PMC* get_multisig()>
+
+Return the MMD signature PMC, if any or a Null PMC.
+
=cut
*/
@@ -565,6 +569,10 @@ Return the LexInfo PMC, if any or a Null PMC.
return sub->outer_sub ? sub->outer_sub : PMCNULL;
}
+ METHOD PMC* get_multisig() {
+ struct Parrot_sub * sub = PMC_sub(SELF);
+ return sub->multi_signature ? sub->multi_signature : PMCNULL;
+ }
}
/*

0 comments on commit 1415cda

Please sign in to comment.
Something went wrong with that request. Please try again.