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

VS problem building project and library #1619

Open
cpyrgas opened this issue Oct 30, 2024 · 3 comments
Open

VS problem building project and library #1619

cpyrgas opened this issue Oct 30, 2024 · 3 comments
Assignees
Milestone

Comments

@cpyrgas
Copy link

cpyrgas commented Oct 30, 2024

Open the attached solution (.sln file is in the folder myWinFormApp) in VS 2019, it contains a library "myTest" and a project "myWinFormApp" that is referencing this library.

  1. Go to the library file myForm.prg and type some invalid code, for example in the constructor:

this.nothing := 1

  1. Rebuild All, an error is correctly reported that "nothing" cannot be found
  2. Delete or comment the offending code and rebuild. Now the above error for the library is gone, but errors are reported for the project referencing it:

Error XS0246: The type or namespace name 'myForm' could not be found
Error XS0115: 'Dispose': no suitable method found to override
Error XS0246: The type or namespace name 'myTest' could not be found

Apparently the dll of the library could not be found correctly, even if it compiles without errors now.

  1. Do a Rebuild All again, now all errors are gone
  2. Go back to (1), the problem is reproducible again

test.zip

@RobertvanderHulst
Copy link
Member

If you rebuild just the library after fixing the code, then the errors from the main app will stay in the error browser. If you rebuild all then the errors from the main app should disappear. What kind of rebuild did you do in step 3)?

@cpyrgas
Copy link
Author

cpyrgas commented Oct 30, 2024

It's always a Rebuild All

@RobertvanderHulst
Copy link
Member

This seems to be working as expected in VS 2022. I am unsure if I should spend much time trying to find out why this fails in VS 2019...

@RobertvanderHulst RobertvanderHulst self-assigned this Oct 30, 2024
@RobertvanderHulst RobertvanderHulst added this to the X# 3.0 milestone Dec 24, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants