in reply to Re^3: Is this module safe to use -> Threads::Queue::Any
in thread Is this module safe to use -> Threads::Queue::Any

thre would be no delimiter for me to parse string once I dequeue If I used
$Q->enqueue( join $;, $abc, $def, $xyz );
  • Comment on Re^4: Is this module safe to use -> Threads::Queue::Any

Replies are listed 'Best First'.
Re^5: Is this module safe to use -> Threads::Queue::Any
by BrowserUk (Patriarch) on Apr 16, 2010 at 19:12 UTC
    thre would be no delimiter for me to parse string

    I don't understand what you mean:

    use Thread::Queue; $Q = new Thread::Queue;; $toQ = join $;, 'abc', 'cde', 'xyz'; print $toQ;; abc∟cde∟xyz $Q->enqueue( $toQ );; $fromQ = $Q->dequeue(); print $fromQ;; abc∟cde∟xyz print split $;, $fromQ;; abc cde xyz

    Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
    "Science is about questioning the status quo. Questioning authority".
    In the absence of evidence, opinion is indistinguishable from prejudice.
      I wrote similar code and I did not get #8735 as u have it? my printed as "abccdexyz". It is all smooshed together. How can I split using what delimeter?

        Post your code.


        Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
        "Science is about questioning the status quo. Questioning authority".
        In the absence of evidence, opinion is indistinguishable from prejudice.

      I got what you are saying. It does split what is #8735 is that entity?

      Is join faster then simple $str="$str|$str1"?

        It does split what is #8735 is that entity?

        That's just perlmonks converting the non-displayable $; which is actually chr( 28 ) to some form of utf.

        Is join faster then simple $str="$str|$str1"?

        Dunno. Probably not. But there won't be a lot in it.


        Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
        "Science is about questioning the status quo. Questioning authority".
        In the absence of evidence, opinion is indistinguishable from prejudice.