Shop OBEX P1 Docs P2 Docs Learn Events
flexspin compiler for P2: Assembly, Spin, BASIC, and C in one compiler - Page 117 — Parallax Forums

flexspin compiler for P2: Assembly, Spin, BASIC, and C in one compiler

1111112113114115117»

Comments

  • ersmithersmith Posts: 5,910

    @Wuerfel_21 said:
    Does that mean there's a problem with signed char in bytecode C, too? That should really work. Though idk, that'd involve messing with, BCCompileMemOpExEx which is the sort of code that should probably be completely trashed and rewritten.

    I think signed char usually ends up working because the integer type system (usually) inserts the casts it needs, and if it doesn't then it (usually) doesn't matter because the lower 8 bits come out correctly anyway. There might be a few edge cases where it fails though, probably in comparisons.

    signed boolean is an odd beast though because it's really just a 1 bit value, so we can't rely on the lower 8 bits being correct and have to sign extend it on every load/store.

Sign In or Register to comment.