Skip to content

fixes #25419; lift magic types to typeclasses#25421

Merged
Araq merged 2 commits into
develfrom
pr_trabte
Jan 14, 2026
Merged

fixes #25419; lift magic types to typeclasses#25421
Araq merged 2 commits into
develfrom
pr_trabte

Conversation

@ringabout

Copy link
Copy Markdown
Member

fixes #25419

@Araq

Araq commented Jan 8, 2026

Copy link
Copy Markdown
Member

What about tyOpenArray, tyVarargs, etc?

@ringabout

ringabout commented Jan 9, 2026

Copy link
Copy Markdown
Member Author
 # we fill it out later. For magic generics like 'seq', it won't be filled
  # so we use tyNone instead of nil to not crash for strange conversions
  # like: mydata.seq
  if s.typ.kind in {tyOpenArray, tyVarargs} and s.typ.len == 1:
    # XXX investigate why `tySequence` cannot be added here for now.
    discard
  else:
    rawAddSon(s.typ, newTypeS(tyNone, c))

tyOpenArray, tyVarargs was special cased here

Comment thread compiler/semstmts.nim Outdated
@nim-lang nim-lang deleted a comment from Copilot AI Jan 9, 2026
@Araq Araq merged commit 40480fe into devel Jan 14, 2026
21 checks passed
@Araq Araq deleted the pr_trabte branch January 14, 2026 15:25
@github-actions

Copy link
Copy Markdown
Contributor

Thanks for your hard work on this PR!
The lines below are statistics of the Nim compiler built from 40480fe

Hint: mm: orc; opt: speed; options: -d:release
192378 lines; 11.178s; 812.973MiB peakmem

narimiran pushed a commit that referenced this pull request Jan 15, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Error: fatal error: invalid kind for lastOrd(tyNone) with type M = set

2 participants