Giter Site home page Giter Site logo

Comments (3)

ninovanhooff avatar ninovanhooff commented on September 15, 2024

Note that this lock check seems deprecated in in nim 2
https://forum.nim-lang.org/t/10487

from playdate-nim.

samdze avatar samdze commented on September 15, 2024

Do you get that warning in the IDE or in the command line during compilation?
I'm not getting that warning for some reason.

from playdate-nim.

ninovanhooff avatar ninovanhooff commented on September 15, 2024

Command line

/bin/zsh -c "nimble simulate"
  Executing task simulate in /Users/ninovanhooff/PlaydateProjects/wheelsprung/wheelsprung.nimble
  Executing task simulator in /Users/ninovanhooff/PlaydateProjects/wheelsprung/wheelsprung.nimble
  Verifying dependencies for [email protected]
    Reading official package list
   Checking for https://github.com/ninovanhooff/playdate-nim@#develop
      Info: Dependency on https://github.com/ninovanhooff/playdate-nim@#develop already satisfied
  Verifying dependencies for playdate@#develop
    Reading official package list
   Checking for https://github.com/ninovanhooff/nim-chipmunk-playdate@any version
      Info: Dependency on https://github.com/ninovanhooff/nim-chipmunk-playdate@any version already satisfied
  Verifying dependencies for [email protected]
   Building wheelsprung/wheelsprung using c backend
  Executing /Users/ninovanhooff/.nimble/bin/nim c --colors:on --noNimblePath -d:simulator -d:debug -d:NimblePkgVersion=0.2.0 --path:'/Users/ninovanhooff/.nimble/pkgs/playdate-#develop' --path:/Users/ninovanhooff/.nimble/pkgs/chipmunk7-7.0.3 -o:/Users/ninovanhooff/PlaydateProjects/wheelsprung/wheelsprung /Users/ninovanhooff/PlaydateProjects/wheelsprung/src/wheelsprung.nim
Hint: used config file '/Users/ninovanhooff/.choosenim/toolchains/nim-1.6.16/config/nim.cfg' [Conf]
Hint: used config file '/Users/ninovanhooff/.choosenim/toolchains/nim-1.6.16/config/config.nims' [Conf]
Hint: used config file '/Users/ninovanhooff/PlaydateProjects/wheelsprung/config.nims' [Conf]
..........................................................................................................................................................
/Users/ninovanhooff/PlaydateProjects/wheelsprung/src/screens/game/game_view.nim(124, 6) Warning: declared lock level is 0, but real lock level is <unknown> [LockLevel]
.
/Users/ninovanhooff/.choosenim/toolchains/nim-1.6.16/lib/system/repr_v2.nim(102, 7) Hint: 'firstElement' is declared but not used [XDeclaredButNotUsed]
/Users/ninovanhooff/PlaydateProjects/wheelsprung/src/screens/game/game_screen.nim(260, 8) Warning: method has lock level <unknown>, but another method has 0 [LockLevel]
.
/Users/ninovanhooff/PlaydateProjects/wheelsprung/src/screens/level_select/level_select_screen.nim(16, 6) Warning: declared lock level is 0, but real lock level is <unknown> [LockLevel]
/Users/ninovanhooff/PlaydateProjects/wheelsprung/src/screens/level_select/level_select_screen.nim(22, 6) Warning: declared lock level is 0, but real lock level is <unknown> [LockLevel]
/Users/ninovanhooff/PlaydateProjects/wheelsprung/src/screens/level_select/level_select_screen.nim(72, 8) Warning: method has lock level 0, but another method has <unknown> [LockLevel]
CC: ../../../.nimble/pkgs/playdate-#develop/playdate/graphics.nim
CC: screens/game/game_view.nim

Note that Screen is an object defined here: https://github.com/ninovanhooff/wheelsprung/blob/8a4ad17ffaca0e504de5c6a77a4f07c3d206ca6c/src/navigation/screen.nim#L1

Also note that this file has a push pragma for locks.

Used here: https://github.com/ninovanhooff/wheelsprung/blob/8a4ad17ffaca0e504de5c6a77a4f07c3d206ca6c/src/screens/level_select/level_select_screen.nim#L72

General remark: not really sure what I'm doing here. My goal with all of the "locks" pragmas / annnotations was To Make The Warnings Go Away

edit: got slightly mixed up with what line of code I started this issue for. That's line 16. In addition, there are some warnings for the Screen methods

from playdate-nim.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.