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

[BUG] VS Code Extension - Parametername not avaliable in code completion #3934

Open
bmerkle opened this issue Jan 8, 2025 · 0 comments
Open
Labels
bug Something isn't working mojo-repo Tag all issues with this label

Comments

@bmerkle
Copy link

bmerkle commented Jan 8, 2025

Bug description

when i write code with Parameterization there is no code completion for the Parametername

e.g. take the

struct GenericArray[ElementType: CollectionElement]:
    var data: UnsafePointer[ElementType]
    var size: Int

    fn __init__(out self, *elements: ElementType):
        self.size = len(elements)
        self.data = UnsafePointer[ElementType].alloc(self.size)

in self.data = UnsafePointer[ElementType].alloc(self.size) there is no completion offered for ElementType

Steps to reproduce

  • code with Parameter
struct GenericArray[ElementType: CollectionElement]:
    var data: UnsafePointer[ElementType]
    var size: Int

    fn __init__(out self, *elements: ElementType):
        self.size = len(elements)
        self.data = UnsafePointer[ElementType].alloc(self.size)
  • No suggestion for Parametername "ElementType"
    image

System information

mojo 24.6.0 (4487cd6e)

Version: 1.96.2 (user setup)
Commit: fabdb6a30b49f79a7aba0f2ad9df9b399473380f
Date: 2024-12-19T10:22:47.216Z
Electron: 32.2.6
ElectronBuildId: 10629634
Chromium: 128.0.6613.186
Node.js: 20.18.1
V8: 12.8.374.38-electron.0
OS: Windows_NT x64 10.0.19045


Magic version: 0.5.1
System
------------
      Pixi version: 0.37.0
          Platform: linux-64
  Virtual packages: __unix=0=0
                  : __linux=5.15.167.4=0
                  : __glibc=2.35=0
                  : __cuda=12.6=0
                  : __archspec=1=skylake


- What OS did you do install Mojo on ?
- Provide version information for Mojo by pasting the output of `mojo -v`
- Provide Magic CLI version by pasting the output of `magic -V` or `magic --version` 
- Optionally, provide more information with `magic info`.
@bmerkle bmerkle added bug Something isn't working mojo-repo Tag all issues with this label labels Jan 8, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working mojo-repo Tag all issues with this label
Projects
None yet
Development

No branches or pull requests

1 participant