Deprecation in Parrot
This is a list of currently deprecated features of Parrot. Every deprecation has an associated RT ticket. Each item indicates the last release it's guaranteed to appear in. Items marked with a release of ??? are still deprecated, but a firm deadline for their removal has not yet been established.
When deprecated items are removed, all usage of the feature in the repository should be updated or removed; including documentation.
PMC syntax
METHOD
[post 0.5.2]The current
METHOD
syntax will be deleted and the currentPCCMETHOD
syntax will replace it under the nameMETHOD
. See RT #48565.PCCINVOKE
[post 0.5.2]The syntax for passing named arguments to
PCCINVOKE
will change from :named['key'] to :named('key') to better match PDD 3. See RT #42292.
vtable entries
get_attr
[post 0.5.2]See RT #48583.
set_attr
[post 0.5.2]See RT #48585.
type_keyed
[post 0.5.2]See RT #48577.
type_keyed_int
[post 0.5.2]See RT #48579.
type_keyed_str
[post 0.5.2]See RT #48581.
get_bool_keyed
[post 0.5.2]See RT #48571.
get_bool_keyed_int
[post 0.5.2]See RT #48573.
get_bool_keyed_str
[post 0.5.2]See RT #48575.
type
[post 0.5.2]See RT #48567.
subtype
[post 0.5.2]See RT #48569.
new_from_string
[post 0.5.0]See RT #47011.
pmc_namespace
[post 0.5.1]See RT# 48144. Replaced by
get_namespace
.DYNSELF
[post 0.5.2]Replaced by
SELF
. (Old behavior ofSELF
changes toSTATICSELF
.)
opcodes
getattribute_p_p_i
,setattribute_p_p_i
[post 0.5.1]See RT # 48729. These were already deprecated, but not fully removed.
classoffset
[post 0.5.1]See RT # 48727. This was already deprecated, but not fully removed.
pioctl
[post 0.5.1]See RT #48589.
store_global
[post 0.5.0]See RT #48016. Replace usage with set_[hll,root]_global variants.
find_global
[post 0.5.0]See RT #48018. Replace usage with get_[hll,root]_global variants.
new
(out PMC, in INT, in STR) [post 0.5.0]See RT #47011.
getclass
[post 0.5.0]See RT #47972. Future use should use the
get_class
opcode.get_mro
[post 0.5.0]See RT #47976.
getfd
[post 0.5.1]See RT #48310.
Class Features
Integer Type IDs [post 0.5.0]
See RT #48024. Instead of
$P0 = new Integer
or$P0 = new .Integer
, use the following syntax, which works for both PMCs and objects.$P0 = new 'Integer'
PMC union struct [post 0.5.0]
See RT #48014. This will be removed once all core PMCs have been updated.
Exceptions
Keyed access to exception attributes [post 0.5.1]
See RT #48012. Attributes on exception objects will no longer be accessible by integer or string key, use
getattribute
andsetattribute
instead.
PIR syntax
<.namespace <identifier
>> syntax [post 0.5.1]See RT #48737.
Use of
::
in identifiers [post 0.5.1]See RT #48735.
.namespace [ "a" .. "b" ]
[post 0.5.0]See RT #4671.
vtable name .constants and __vtable overrides [post 0.5.2]
See RT #48877.
Assignment syntax with opcodes [post ???]
See RT #36283. When the first argument of an opcode is
OUT
, then the assignment syntax will be allowed, as it is today.In any other case (i.e.
INOUT
,IN
), this will become a syntax error. For example:$S0 = print $P0 = substr 1, 2, "x"
Will have to be:
print $S0 substr $P0, 1, 2, "x"
Parrot Compiler tools
pgc.pir [post 0.5.0]
See RT #48026. The pgc.pir compiler for P6 grammars (pre-2007 regex syntax) is deprecated. Switch to using the new PGE::Perl6Grammar.pir compiler instead, and the Perl6Regex syntax.
PGE::P6Regex [post 0.5.0]
See RT #48028. In early 2007 there were a number of changes made to the Perl 6 regular expression syntax (as given by Synopsis 5). The new syntax is implemented via the PGE::Perl6Regex compiler, and the PGE::P6Regex compiler is now deprecated in favor of the new syntax.
compilers/PAST-pm [post 0.5.1]
See RT #48030. The compiler tools in compilers/PAST-pm/ and runtime/parrot/library/Parrot/HLLCompiler.pir are deprecated in favor of the new versions in the Parrot Compiler Toolkit ( compilers/pct/ ). In particular, the PAST representation in PCT follows the specification given by pdd26 .