This is a list of currently deprecated features of Parrot. Every deprecation should have an associated RT ticket, but this is not the case yet [RT#41226].
The object system of Parrot is being overhauled. This touches some opcode and PIR syntax. So some deprecation can be found in pdd17_pmc.pod.
http://xrl.us/jc4u
IMC vs. PIR Two names enter One name leaves /me giggles -- Chip Salzenberg
Currently no C APIs are deprecated.
PGE::P6Regex is now a registered compiler, and should be used like so:
<@pmichaud> it's easy; instead of $P0 = find_global "PGE", "p6rule" one now does $P0 = compreg "PGE::P6Regex"
This syntax is also true for PGE::Glob and PGE::P5Regex
From http://www.parrotcode.org/docs/ops/var.html, the following ops are deprecated:
There are several variants of some of the above ops; all are deprecated, and are replaced by the ops {set,get}_[hll,root]_global. See also http://www.parrotcode.org/docs/ops/var.html.
For now this op will stay available as an experimental op [RT#41749].
From http://www.parrotcode.org/docs/ops/experimental.html, the following ops are deprecated:
They will be removed in the 0.5.0 release.
Type IDs will go away in 0.5.0.
The classname op is deprecated and will be removed in the 0.5.0 release. It's an exact duplicate of the string return variant of the typeof op.
classname
typeof
The experimental instantiate opcode is deprecated and will be removed in the 0.5.0 release.
instantiate
(The instantiate vtable function becomes core in 0.5.0, but is accessed via the "new" opcode for the PMCs that use it.)
PMC* subclass(PMC *name)
The subclass vtable method is deprecated and will be removed in the 0.5.0 release.
The PMC union struct is deprecated and will be removed once all core PMCs have been updated.
As of Parrot 0.4.16 all type names for .local other than string, num, int, and pmc are deprecated. Using float for num or a basic PMC name like Array for pmc will no longer be possible in Parrot 0.4.17. [RT#42769].
float
num
Array
pmc
Currently a sub can be tagged as a method using the method keyword, besides the more consistent :method. IMCC currently supports both, but will be updated to only accept :method. [RT#45399].
method
:method
.pcc_begin/end_return/yield
Currently you can write:
.pcc_begin_return .return 1 .return 2 .pcc_end_yield
It is not very clear whether this is a return or yield block. It's also possible to start a block with .pcc_begin_yield and end with .pcc_end_return. IMCC will be made more stricter, to only allow proper pairs: begin/end should match. [RT#45411].
.pcc_begin_yield
.pcc_end_return
.global
Although the .global directive was never implemented, this directive will be removed. [RT#45407].
.pcc_sub
IMCC allows for defining a sub using both the .pcc_sub and .sub keyword. In earlier days there was a semantic difference between the two, but not anymore. Therefore, the .pcc_sub directive is removed from PIR mode. It will still be possible to use it in PASM mode. [RT#45409].
.sub
Currently no compiler tools are deprecated.
Not yet deprecated, but it's recommended to use the new syntax and gradually change the old.
Instead of:
$P0 = new Integer
or
$P0 = new .Integer # better, but ...
we are moving to use:
$P0 = new 'Integer'
When the first argument of an opcode is OUT, then the assignment syntax will be allowed, as it is today.
OUT
In any other case (i.e. INOUT, IN), this will become a syntax error. For example:
INOUT
IN
$S0 = print $P0 = substr 1, 2, "x"
Will have to be:
print $S0 substr $P0, 1, 2, "x"
To install Parrot::Op, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Parrot::Op
CPAN shell
perl -MCPAN -e shell install Parrot::Op
For more information on module installation, please visit the detailed CPAN module installation guide.