Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7194639
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 28, 20262026-05-28T20:24:48+00:00 2026-05-28T20:24:48+00:00

I want to export only the pdl() function from PDL to avoid namespace collision

  • 0

I want to export only the pdl() function from PDL to avoid namespace collision with other automatically exported functions such as max, median, sum, intersect etc. However, when I tried

use PDL qw(pdl);

it doesn’t work as the aforementioned functions still get exported (and I get warnings on functions being redefined).

On the other hand, if I do

use PDL qw();

The collision doesn’t happen. But when I try to use the pdl() function in the program via PDL::pdl(), it fails with this error message:

Can't call method "new" on unblessed reference at Basic/Core/Core.pm.PL (i.e. PDL::Core.pm) line 934.

Also, I tried inside the script

{
     require PDL;
     pdl();
}

I get the same error message.

Can someone advice on how I can export pdl() only? Thx!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-28T20:24:49+00:00Added an answer on May 28, 2026 at 8:24 pm

    SYNOPSIS
    use PDL; # Is equivalent to the following:

       use PDL::Core;
       use PDL::Ops;
       use PDL::Primitive;
       use PDL::Ufunc;
       use PDL::Basic;
       use PDL::Slices;
       use PDL::Bad;
       use PDL::MatrixOps;
       use PDL::Math;
       use PDL::Version;
       use PDL::IO::Misc;
       use PDL::IO::FITS;
       use PDL::IO::Pic;
       use PDL::Lvalue;
    

    I guess if you only import PDL::Core, you’ll get only the functions in this module.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm writing a C/C++ DLL and want to export certain functions which I've done
I'm using SQL Server 2005 and I want to export all records from my
So I want to export the data from one list into another so I
I want to export, checkout, or whatever you call it from the index, HEAD,
I want to export only changes (files and folders - tree) between HEAD and
I can see why someone would want to export by ordinal only (i.e. using
Is there a way in C++ to create an anonymous namespace, and only export
I want to export my BPMN diagrams from Visio 2010 Premium to BPMN 2.0
I want to write several functions that are only different in the types of
When I right click on the database I want to export data from, I

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.