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 6953259
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T14:27:20+00:00 2026-05-27T14:27:20+00:00

Ok, in hindsight this does seem to be a silly problem I got myself

  • 0

Ok, in hindsight this does seem to be a silly problem I got myself into and shouldn’t have done in the first place.

I have a class Debug with a function called trace inside it which puts a TextField on the stage and outputs the text.

Now I am trying to get the Debug.trace() function to do a “normal” debug trace as well from within side itself.

of course this causes a recursive loop.

I am trying to figure out how I can access the top level separately. I tried using namespaces such as AS3::trace but to no luck.

I know a solution is to rename my function to stop the conflict, but I would like that to be a last resort. So people suggesting a DIFFERENT solution would be helpful.

It is being used in quite alot of places throughout my entire code so replacing it everywhere is going to be a ballache.

Thank you for any “different” solutions to the one above.

  • 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-27T14:27:21+00:00Added an answer on May 27, 2026 at 2:27 pm

    Since trace() is a Top Level function and you’re ‘overriding’ it in your Debug class I don’t think it’s possible to call it in another way.

    A possible workaround could be to create a private class beneath your public Debug class. In there you could place a static method you could call which does the actual trace() like so:

    public class Debug
    {
        static public function trace(value:*) : void
        {
    
            /* your textfield code */
    
            DebugTrace.debugTrace(value);
        }
    }
    
    class DebugTrace
    {
        public static function debugTrace(value:*) : void
        {
            trace(value);
        }
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

NOTE : In hindsight, I realize this may seem like a stupid question, but
I have a settings class that I want to be able to serialize and
Thanks for the comments below. In hindsight, I should have been more detailed. I
I'm currently working on my first Django project and have hit a roadblock in
I have both Eclipse 3.5 and 3.6 on ubuntu 10.04. I am trying, actually
Sorry if this is blatantly obvious, but I've Googled this and I seriously cannot
I'm kind of new to RoR so this may be a stupid question, but
I've got a TCP server written in C# that processes POST data sent to
I have an Android app, where a part of the app is a list
I have an input page in my C# application whereby my boss can enter

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.