书中代码与源码中不符
imkratos opened this issue · comments
Liuzhishuo commented
在《自己动手写java虚拟机》中,您的书中194页 anewarray.go 文件中 Execute函数中 classRef := cp.GetConstant(self.Index).(*rtc.ClassRef)
,而实际应该是classRef := cp.GetConstant(self.Index).(*heap.ClassRef)
。不知道我有没有理解错误
Liuzhishuo commented
另外206页中 getField函数 您的书中少写了 isStatic 的类型bool 哈,代码中也有。