瀏覽代碼

Compare symbols by their name not by their address to prevent non-determinism.

master
Ian Piumarta 2 年之前
父節點
當前提交
eb85a1fb75
共有 1 個檔案被更改,包括 2 行新增0 行删除
  1. +2
    -0
      src/object.c

+ 2
- 0
src/object.c 查看文件

@ -427,6 +427,8 @@ int oopcmp(oop a, oop b)
}
case String:
return strcmp(get(a, String, value), get(b, String, value));
case Symbol:
return strcmp(get(a, Symbol, name), get(b, Symbol, name));
default: {
intptr_t l= (intptr_t)a, r= (intptr_t)b;
if (l < r) return -1;

Loading…
取消
儲存