goby-lang / goby

Goby - Yet another programming language written in Go
MIT License
3.49k stars 171 forks source link

Fix object_id method #796

Closed st0012 closed 4 years ago

st0012 commented 4 years ago

In the past, even if you call object_id on the exact same object, it returns different values every time. This PR is to fix that issue + some refactoring around object initialization functions.

codecov[bot] commented 4 years ago

Codecov Report

Merging #796 into master will increase coverage by 0.02%. The diff coverage is 87.87%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #796      +/-   ##
==========================================
+ Coverage   80.22%   80.24%   +0.02%     
==========================================
  Files          54       54              
  Lines        7399     7402       +3     
==========================================
+ Hits         5936     5940       +4     
+ Misses       1238     1237       -1     
  Partials      225      225
Impacted Files Coverage Δ
vm/decimal.go 94.64% <100%> (ø) :arrow_up:
vm/match_data.go 64.51% <100%> (ø) :arrow_up:
vm/error.go 70.96% <100%> (ø) :arrow_up:
vm/go_map.go 82.45% <100%> (ø) :arrow_up:
vm/float.go 80.91% <100%> (ø) :arrow_up:
vm/null.go 87.5% <100%> (ø) :arrow_up:
vm/integer.go 64.37% <100%> (ø) :arrow_up:
vm/boolean.go 93.33% <100%> (ø) :arrow_up:
vm/range.go 93.29% <100%> (ø) :arrow_up:
vm/regexp.go 75.51% <100%> (ø) :arrow_up:
... and 14 more

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update 9074403...c0d21a3. Read the comment docs.

st0012 commented 4 years ago

@saveriomiroddi ah you're right, my bad 😕

st0012 commented 4 years ago

@saveriomiroddi updated, will merge after build finished