-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
Debugger doesn't show correct information for array initialized with runtime length #585
Comments
@YXuewei What OS are you running on and if you are using |
@pieandcakes I'm using windows, and I do turned pretty-printing on. I write a sample code to demonstrate what it looks like. |
@YXuewei The visualization of the variables through pretty printing is provided by gdb's community. If you want, you can search and see if there is another option to help visualize the array. We also support .natvis visualization using a .natvis visualizer file but you would also need to create one from scratch. It seems like gdb is returning different information for each case, which we have no control over. |
@pieandcakes Is that possible to let VSCode to use GDB in WSL? If it is what we going to have in Windows Creator update I will save me sometime for getting a *nix or some money on macOS. |
@pieandcakes It is the same if I use LLDB, see screen shoots below. I tried this with a MacBook Pro. |
@YXuewei We also enabled python formatting for lldb recently. I don't know if the behavior is the same. You can enable |
@pieandcakes No it doesn't work, it didn't bring any difference without the command when inspecting. It should be a way in LLDB to enable something like pretty printing in GDB. There is no reason that gdb can do it but LLDB can not. Otherwise how does Xcode be able to view object contains or dynamic array? |
@YXuewei Unfortunately LLDB the pretty printing is compiled in and not able to be disabled. I don't know if Xcode provides additional pretty printing configurations but you can look at the documentation here: http://lldb.llvm.org/varformats.html The ones included in our package are located at: |
Closing issue with no recent updates. If this issue is still occuring, please open a new issue. |
The MIEngine was still compiling against incredibly ancient packages. This switches it over to something recent - the packages that came out at the same time as .NET Core 1.0 RTW. The primary IL level difference of this change is to increment the reference assembly version of the following in the non-'Desktop' configurations. System.Xml.XmlSerializer System.IO.FileSystem System.Net.Http System.IO.FileSystem.Primitives In addition, this changes: * The Desktop configuration to stop dropping a bunch of facade assemblies that it doesn�'t seem like it actually needed. * Stops having the IOS launcher need to partially depend on facade assemblies. To do this I added an MIEngine definition of RemoteCertificateValidationCallback.
I ran into a problem that if I declare an array with know length such as
int array[5];
the debug works perfectly, however, if I initialize an array with length only know at run time for example
int n = someinput; int array[n]
the debug doesn't show correct information for this array, it shows length of 0, and can't inspect the element. Please see pic below
I'm absolutely, completely, definitely sure image[] and input[] by the time is already initialized correctly.
The text was updated successfully, but these errors were encountered: