Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

=destroy for non-var failed to compile when nim doc #23726

Open
litlighilit opened this issue Jun 17, 2024 · 5 comments
Open

=destroy for non-var failed to compile when nim doc #23726

litlighilit opened this issue Jun 17, 2024 · 5 comments
Labels
Documentation Generation Related to documentation generation (but not content). Needs Backporting/Fixed in Devel The issues can be solved via backporting

Comments

@litlighilit
Copy link
Contributor

litlighilit commented Jun 17, 2024

Description

A regression, maybe only occur in Nim 2.0.6, not in devel branch or 2.0.4

only causes compile-error when nim doc
and other commands like nim c or nim check just work.

Simplest demo:

type O = object
proc `=destroy`*(self: O) = discard

Nim Version

Nim Compiler Version 2.0.6 [Windows: amd64]
Compiled at 2024-06-17
Copyright (c) 2006-2023 by Andreas Rumpf
active boot switches: -d:release

Current Output

Error: signature for '=destroy' must be proc[T: object](x: var T)

Expected Output

(compiles and no error reported)

Possible Solution

No response

Additional Information

I found it shown on nimpylib's test

@litlighilit
Copy link
Contributor Author

litlighilit commented Jun 17, 2024

As I tested, at least no error in Nim 2.1.1, 2.0.0, 2.0.4

@litlighilit
Copy link
Contributor Author

!nim doc

type O = object
proc `=destroy`*(self: O) = discard

Copy link
Contributor

🐧 Linux bisect by @litlighilit (contributor)
devel 👎 FAIL

Output


IR

Compiled filesize 0 (0 bytes)

Stats

  • Started 2024-06-17T13:23:08
  • Finished 2024-06-17T13:23:08
  • Duration now

AST

stable 👎 FAIL

Output


IR

Compiled filesize 0 (0 bytes)

Stats

  • Started 2024-06-17T13:23:09
  • Finished 2024-06-17T13:23:09
  • Duration now

AST

2.0.4 👎 FAIL

Output


IR

Compiled filesize 0 (0 bytes)

Stats

  • Started 2024-06-17T13:23:12
  • Finished 2024-06-17T13:23:12
  • Duration now

AST

2.0.0 👎 FAIL

Output


IR

Compiled filesize 0 (0 bytes)

Stats

  • Started 2024-06-17T13:23:14
  • Finished 2024-06-17T13:23:14
  • Duration now

AST

1.6.20 👎 FAIL

Output


IR

Compiled filesize 0 (0 bytes)

Stats

  • Started 2024-06-17T13:23:17
  • Finished 2024-06-17T13:23:17
  • Duration now

AST

1.4.8 👎 FAIL

Output


IR

Compiled filesize 0 (0 bytes)

Stats

  • Started 2024-06-17T13:23:19
  • Finished 2024-06-17T13:23:19
  • Duration now

AST

1.2.18 👎 FAIL

Output


IR

Compiled filesize 0 (0 bytes)

Stats

  • Started 2024-06-17T13:23:21
  • Finished 2024-06-17T13:23:21
  • Duration now

AST

1.0.10 👎 FAIL

Output


IR

Compiled filesize 0 (0 bytes)

Stats

  • Started 2024-06-17T13:23:23
  • Finished 2024-06-17T13:23:23
  • Duration now

AST

Stats
  • GCC 11.4.0
  • Clang 14.0.0
  • NodeJS 20.3
  • Created 2024-06-17T13:16:43Z
  • Comments 2
  • Commands nim doc --run -d:nimDebug -d:nimDebugDlOpen -d:ssl -d:nimDisableCertificateValidation --forceBuild:on --colors:off --verbosity:0 --hints:off --lineTrace:off --nimcache:/home/runner/work/Nim/Nim --out:/home/runner/work/Nim/Nim/temp /home/runner/work/Nim/Nim/temp.nim

🤖 Bug found in 18 minutes bisecting 8 commits at 0 commits per second

@juancarlospaco
Copy link
Collaborator

I think theres no "!nim doc" in the bisect bot, I don't know what it should do 🤔
but ideas and pr welcome: https://github.com/juancarlospaco/nimrun-action

@juancarlospaco juancarlospaco added the Documentation Generation Related to documentation generation (but not content). label Jun 17, 2024
@ringabout ringabout added the Needs Backporting/Fixed in Devel The issues can be solved via backporting label Jul 8, 2024
@litlighilit
Copy link
Contributor Author

As I tested, at least no error in Nim 2.1.1, 2.0.0, 2.0.4

...haven't been fixed on 2.0.8

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Documentation Generation Related to documentation generation (but not content). Needs Backporting/Fixed in Devel The issues can be solved via backporting
Projects
None yet
Development

No branches or pull requests

3 participants