From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Paul N. Hilfinger" To: fnasser@redhat.com Cc: gdb-patches@sources.redhat.com Subject: Side-effects of double-parsing patch Date: Sun, 29 Apr 2001 04:11:00 -0000 Message-id: <200104291111.EAA26063@localhost.localdomain> X-SW-Source: 2001-04/msg00268.html Fernando, The patch of 2001-01-26 to fix double parsing of filenames causes some other changes, and I'm not certain which are intentional. [A quick review for the general audience: GDB used to call symbol_file_command in a number of places for, well, reading the symbol file. However, when called "internally" (that is, for purposes other than implementing the symbol-file command), this caused file names to get parsed twice, with odd effects in some cases. These calls were therefore changed to calls to symbol_file_add_main, which immediately calls symbol_file_add with some filled-in arguments.] Now here's my question: symbol_file_command eventually calls symbol_file_add, too, but it then goes on to call RESET_HP_UX_GLOBALS, reinit_cache_frame, and set_initial_language. This no longer happens for the "internal" calls. One side effect is that set_initial_language is not called when GDB starts up, so that one now always starts in C (I think). Unfortunately, this turns out to be a slight problem in the changes I am making for Ada. This could be just a peculiarity of Ada, of course, so before I do anything kludgey, may I ask what the reasoning was behind dispensing with these three calls? Thanks. Paul Hilfinger