[svn:parrot] r48947 - in trunk: . docs include/parrot lib/Parrot src

NotFound at svn.parrot.org NotFound at svn.parrot.org
Sun Sep 12 00:32:05 UTC 2010


Author: NotFound
Date: Sun Sep 12 00:32:05 2010
New Revision: 48947
URL: https://trac.parrot.org/parrot/changeset/48947

Log:
remove deprecated function Parrot_get_runtime_prefix, TT #1191

Modified:
   trunk/DEPRECATED.pod
   trunk/docs/embed.pod
   trunk/include/parrot/library.h
   trunk/lib/Parrot/Test.pm
   trunk/src/library.c

Modified: trunk/DEPRECATED.pod
==============================================================================
--- trunk/DEPRECATED.pod	Sun Sep 12 00:26:36 2010	(r48946)
+++ trunk/DEPRECATED.pod	Sun Sep 12 00:32:05 2010	(r48947)
@@ -391,12 +391,6 @@
 
 L<https://trac.parrot.org/parrot/ticket/1628>
 
-=item Parrot_get_runtime_prefix [eligible in 2.7]
-
-Use Parrot_get_runtime_path instead.
-
-L<https://trac.parrot.org/parrot/ticket/1191>
-
 =item Parrot_getpid [experimental]
 
 Get process id, experimental.

Modified: trunk/docs/embed.pod
==============================================================================
--- trunk/docs/embed.pod	Sun Sep 12 00:26:36 2010	(r48946)
+++ trunk/docs/embed.pod	Sun Sep 12 00:32:05 2010	(r48947)
@@ -775,8 +775,6 @@
 
 =item C<Parrot_get_runtime_path>
 
-=item C<Parrot_get_runtime_prefix>
-
 =item C<Parrot_get_strreg>
 
 =item C<Parrot_get_vtable>

Modified: trunk/include/parrot/library.h
==============================================================================
--- trunk/include/parrot/library.h	Sun Sep 12 00:26:36 2010	(r48946)
+++ trunk/include/parrot/library.h	Sun Sep 12 00:32:05 2010	(r48947)
@@ -46,12 +46,6 @@
         __attribute__nonnull__(1);
 
 PARROT_EXPORT
-PARROT_MALLOC
-PARROT_CANNOT_RETURN_NULL
-char* Parrot_get_runtime_prefix(PARROT_INTERP)
-        __attribute__nonnull__(1);
-
-PARROT_EXPORT
 void Parrot_lib_add_path(PARROT_INTERP,
     ARGIN(STRING *path_str),
     enum_lib_paths which)
@@ -104,8 +98,6 @@
 
 #define ASSERT_ARGS_Parrot_get_runtime_path __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
        PARROT_ASSERT_ARG(interp))
-#define ASSERT_ARGS_Parrot_get_runtime_prefix __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
-       PARROT_ASSERT_ARG(interp))
 #define ASSERT_ARGS_Parrot_lib_add_path __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
        PARROT_ASSERT_ARG(interp) \
     , PARROT_ASSERT_ARG(path_str))

Modified: trunk/lib/Parrot/Test.pm
==============================================================================
--- trunk/lib/Parrot/Test.pm	Sun Sep 12 00:26:36 2010	(r48946)
+++ trunk/lib/Parrot/Test.pm	Sun Sep 12 00:32:05 2010	(r48947)
@@ -298,7 +298,6 @@
 Memoize::memoize('path_to_parrot');
 
 # Tell parrot it's being tested--disables searching of installed libraries.
-# (see Parrot_get_runtime_prefix in src/library.c).
 $ENV{PARROT_TEST} = 1 unless defined $ENV{PARROT_TEST};
 
 my $builder = Test::Builder->new();

Modified: trunk/src/library.c
==============================================================================
--- trunk/src/library.c	Sun Sep 12 00:26:36 2010	(r48946)
+++ trunk/src/library.c	Sun Sep 12 00:32:05 2010	(r48947)
@@ -784,46 +784,6 @@
 
 /*
 
-=item C<char* Parrot_get_runtime_prefix(PARROT_INTERP)>
-
-Return a malloced C-string for the runtime prefix.  The calling function
-must free it.
-
-This function is deprecated, use Parrot_get_runtime_path instead.
-See TT #1191
-
-=cut
-
-*/
-
-PARROT_EXPORT
-PARROT_MALLOC
-PARROT_CANNOT_RETURN_NULL
-char*
-Parrot_get_runtime_prefix(PARROT_INTERP)
-{
-    ASSERT_ARGS(Parrot_get_runtime_prefix)
-    char * const env = Parrot_getenv(interp, CONST_STRING(interp, "PARROT_RUNTIME"));
-
-    Parrot_warn_deprecated(interp, "Parrot_get_runtime_prefix is deprecated TT #1191");
-    if (env)
-        return env;
-    else {
-        PMC    * const config_hash =
-            VTABLE_get_pmc_keyed_int(interp, interp->iglobals, (INTVAL) IGLOBALS_CONFIG_HASH);
-
-        if (VTABLE_elements(interp, config_hash)) {
-            STRING * const key = CONST_STRING(interp, "prefix");
-            STRING * const s   = VTABLE_get_string_keyed_str(interp, config_hash, key);
-            return Parrot_str_to_cstring(interp, s);
-        }
-        else
-            return mem_sys_strdup(".");
-    }
-}
-
-/*
-
 =item C<STRING * Parrot_get_runtime_path(PARROT_INTERP)>
 
 Return a string for the runtime prefix.


More information about the parrot-commits mailing list