0xAA
0xAA
> I _think_ Sift should work how you want it to -- do you have a pseudocode example? I can use it like: ```JavaScript let jsData=parse(bson) // maybe bson is...
I understand it can't be answered by sift, but I ask it here anyway. I can use it like: ```JavaScript const test = sift({ a:{ $exists: true } })); test({a:1});...
其实就是js的字符串字面量不是object,而weak是对object垃圾收集做手脚,所以不匹配。归根结底是语言设计问题。c#或java也有弱引用,传字符串字面量就没问题。
另外,string在使用被自动ToObject是约定俗成的东西,之所以weakmap实现中不这样,是因为基本类型虽然有对应的object形式,但设计上无共享语义(使得实现上可以共享而进行优化),你绕过了这个设计限制而已。简单讲:a=new String('abc'); b=a;则显然b与a指向同一片内存,但a=new String('abc'); b=new String('abc'); 则b与a是否指向同一片内存是未定义的。另外实在没必要用weakmap防止string这种小东西无法被回收,因为weakmap内部会根据这个string的地址生成另一个更复杂的标识对象,那个内存和cpu的overhead比起用map完全是倒退~
I forked this repo, supporting newer version of node: https://github.com/jinCN/Mancy
Sorry. Not a lawyer?So cute! Thank you^_^
your makefile is: mk/Makefile and I run: make then I get error: Makefile:1: **\* 遗漏分隔符 。 停止。 so what's wrong please?
I was sure you are right! I got a cygwin.I got it right. But: LINK obj/debug/app /usr/bin/ld: cannot find -ldir3 I think it's the libdir3.so that ld can't find How...
Ok,here: Administrator@PC-201406111817 /cygdrive/f/Work/nonrec-make/ex1 $ make VERBOSE=yes /bin/bash: tput: command not found /bin/bash: line 0: [: -gt: unary operator expected Rules generated for "debug" mode... CC top_a.c CC top_b.c CC main.c...
g++ -g -W -Wall -ggdb -MMD -D_REENTRANT -D_POSIX_C_SOURCE=200112L -D__EXTENSIONS__ -DDEBUG -DLITTLE_ENDIAN -ggdb /cygdrive/f/Work/nonrec-make/ex1/obj/debug/top_a.o /cygdrive/f/Work/nonrec-make/ex1/obj/debug/top_b.o /cygdrive/f/Work/nonrec-make/ex1/obj/debug/main.o /cygdrive/f/Work/nonrec-make/ex1/Dir_1/obj/debug/dir1_lib.a /cygdrive/f/Work/nonrec-make/ex1/Dir_2/obj/debug/dir2_lib.a -L/cygdrive/f/Work/nonrec-make/ex1/Dir_3/obj/debug/ -ldir3 -lm -o /cygdrive/f/Work/nonrec-make/ex1/obj/debug/app /usr/bin/ld: cannot find -ldir3 CYGWIN_NT-6.1 x86_64 Is there...