Skip to content

string equality should be based on contents not identity #123

Closed
@jyasskin

Description

@jyasskin
$ cat test.rs
fn main() {
  if("0" == "0") {
    log "equal";
  } else {
    log "not equal";
  }
}
$ ./rustboot -L . test.rs -o test.exe && ./test.exe
rt: 0xa0563720:0xbfffece4:0x00100200:     upcall log_str("not equal")

We can work around this in the library, but I'd rather not.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions