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

Server crashed when method called on it #103

Open
benash opened this issue Apr 29, 2024 · 0 comments
Open

Server crashed when method called on it #103

benash opened this issue Apr 29, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@benash
Copy link

benash commented Apr 29, 2024

Describe the bug

When calling a method on a variable named it, the server managed by the VSCode extension crashes.

Expected Behavior

No crash

Current Behavior

The server crashes with message: Connection to server got closed. Server will not be restarted.

Reproduction Steps

Minimal example that causes a crash:

fn foo() {
	it.bar()
}

That code in itself is not valid V, but the server shouldn't crash. Additionally, the following code that is valid V still causes a crash:

struct Baz {}
fn (b Baz) bar() {}

fn foo() {
	it := Baz{}
	it.bar()
}

Possible Solution

No response

Additional Information/Context

No response

Environment details (v doctor output)

V full version: V 0.4.5 ec59760
OS: macos, macOS, 13.6.6, 22G630
Processor: 12 cpus, 64bit, little endian, Apple M2 Pro

getwd: /Users/ben/git/abc
vexe: /Users/ben/git/v/v
vexe mtime: 2024-04-29 14:58:21

vroot: OK, value: /Users/ben/git/v
VMODULES: OK, value: /Users/ben/.vmodules
VTMP: OK, value: /tmp/v_501

Git version: git version 2.39.3 (Apple Git-145)
Git vroot status: weekly.2024.18-6-gec597608 (3 commit(s) behind V master)
.git/config present: true

CC version: Apple clang version 15.0.0 (clang-1500.1.0.2.5)
thirdparty/tcc status: thirdparty-macos-arm64 5c1d002f

Editor name

VSCode

v-analyzer Version

v-analyzer version 0.0.4-beta.1.7e11a6f

VS Code Extension Version

v0.0.2

@benash benash added the bug Something isn't working label Apr 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant