Euphoria Ticket #116: peek2u bad type inference

When translating peek2u, the type inference is ends up looking like:

    /** 	while peek2u(ptr) do*/ 
L1:  
    if (IS_ATOM_INT(_ptr_1518)) { 
        _735 = *(unsigned short *)_ptr_1518; 
    } 
    else { 
        _735 = NewString((char *)(unsigned long)(DBL_PTR(_ptr_1518)->dbl)); 
    } 

It's not detecting the possibility of an atom being used as a pointer. This probably applies to other peeks, since I think a lot of the code is shared.

Details

Type: Bug Report Severity: Blocking Category: Translator
Assigned To: mattlewis Status: Fixed Reported Release: r2998
Fixed in SVN #: 3000 View VCS: 3000 Milestone:

1. Comment by mattlewis Nov 09, 2009

The translator was only testing for PEEK2S, not PEEK2U and PEEK2S.

Search



Quick Links

User menu

Not signed in.

Misc Menu