1. How do i do this in Euphoria?

I've got the following C code:

40h | scau | 08h | DMAChannel

how do do all those |'s in euphoria?

-Mark.

new topic     » topic index » view message » categorize

2. Re: How do i do this in Euphoria?

This code straight from win32lib.ew ... Thanks to Mr Cuny.

global function or_all(sequence s)
-- or together all elements of a sequence
    atom result

    result = 0
    for i = 1 to length(s) do
        result = or_bits(result, s[i])
    end for
    return result
end function


something = or_all( {40h, scau, 08h, DMAChannel} )


Ray Smith


>I've got the following C code:
>
>40h | scau | 08h | DMAChannel
>
>how do do all those |'s in euphoria?
>
>-Mark.
>

Ray Smith

____________________________________________________________________
Local Government Software Development      Phone: +61 (0)2 63 620088
Fujitsu Australia Limited (Orange)         Fax  : +61 (0)2 63 613505
Email: ray.smith at fujitsu.com.au
____________________________________________________________________

new topic     » goto parent     » topic index » view message » categorize

3. Re: How do i do this in Euphoria?

Ray Smith wrote:

>This code straight from win32lib.ew ... Thanks to Mr Cuny.

Actually, Robert gets credit for this one - I filched it from him!

-- David Cuny

new topic     » goto parent     » topic index » view message » categorize

Search



Quick Links

User menu

Not signed in.

Misc Menu