Skip to content

Commit

Permalink
fixes #110; make it compatible with Nim 2.0.0
Browse files Browse the repository at this point in the history
  • Loading branch information
ringabout committed Feb 8, 2024
1 parent c711d8e commit 8c1c3db
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/depgraphs.nim
Original file line number Diff line number Diff line change
Expand Up @@ -184,7 +184,12 @@ proc traverseRelease(c: var AtlasContext; nc: NimbleContext; g: var DepGraph; id
if found != 1:
pv.req = UnknownReqs
else:
let nimbleContents = readFile(nimbleFile)
when (NimMajor, NimMinor, NimPatch) == (2, 0, 0):
# bug #110; make it compatible with Nim 2.0.0
# ensureMove requires mutable places when version < 2.0.2
var nimbleContents = readFile(nimbleFile)
else:
let nimbleContents = readFile(nimbleFile)
if lastNimbleContents == nimbleContents:
pv.req = g.nodes[idx].versions[^1].req
else:
Expand Down

0 comments on commit 8c1c3db

Please sign in to comment.