584 - Status: Closed QC #: 1124 - CiteSeerX

479
User Reported Issues for Delphi and C++Builder in Quality Central that are fixed in Delphi XE and C++Builder XE QC #: 329 - Status: Closed QC #: Project Date Reported: Area: 329 Delphi 11/11/1996 RTL\Delphi\WinAPI Description Steps: MakeLCID and MakeLangId functions should be added, as in the Win32 macros. All the other associated macros (primary from LANGID, etc.) should be added as well. QC #: 584 - Status: Closed QC #: Project Date Reported: Area: 584 Delphi 4/9/2002 IDE\Structure Pane Description Steps: [QC Short Description] Strcuture View (formerly Object TreeView) doesn't automatically scroll when in Drag&Drop [QC Description] When designing complex forms the content of Structure View doesn't fit on the screen. If you then try to move components in the Structure TreeView by Drag&Drop you can't drop it onto a TreeView node which is currently not visible because the TreeView doesn't scroll when you're pointing your mouse near the edges of the TreeView. That way Object TreeView loses it's most important feature (IMO) ! QC Entry 584 1. Create a new application 2. Drop quite a few buttons etc. on the form and a PageControl. 3. Open the Object TreeView (Alt+Shift+F11) 4. Resize the Object TreeView window so that not all nodes are visible and the scrollbars appear 5. Now try to drag one of the buttons TreeNodes to the edges of the TreeView exp: TreeView should automatically scroll act: Nothing QC #: 1124 - Status: Closed QC #: Project Date Reported: Area: 1124 C++Builder 9/9/2002 IDE\Translation Tools Description Steps: I can't port existing BCB5 translated applications. AFAICT there are several faults in the resulting BPRs including: UNITNAME is always "Form" CONTAINERID is always empty (though this may be correct). In addition "#pragma resource" has been changed so that you need double '\\'s to represent a single '\'. Having fixed these issues I can get the project to Build and Make but I get EResourceNotFound on running and when I try to open the form for viewing/designing I just get taken to the DFM in the edit window. --------- 1.Choose a VCL project with several forms. 2.\File\New\ and select Resource DLL Wizard 3.Click to the language selection page and enable a foreign language. 4.Click on to finish and allow the IDE to recompile and create the new project. You will find the new project has only one form (probably the first listed in your original project) and that double clicking the form in the Project Manager only opens the file in the text editor. The pop-up menu has 'View as form' greyed out. If you attempt to compile this project it will fail at a #pragma directive. If you fix this by replacing '\' with '\\' it will compile and link but the

Transcript of 584 - Status: Closed QC #: 1124 - CiteSeerX

User Reported Issues for Delphi and C++Builder in Quality Central that are fixed in Delphi XE and C++Builder XE 

QC #: 329 - Status: Closed

QC #: Project Date Reported: Area: 329 Delphi 11/11/1996 RTL\Delphi\WinAPI Description Steps:MakeLCID and MakeLangId functions should be added, as in the Win32 macros. All the other associated macros (primary from LANGID, etc.) should be added as well.

QC #: 584 - Status: Closed

QC #: Project Date Reported: Area: 584 Delphi 4/9/2002 IDE\Structure Pane Description Steps:[QC Short Description] Strcuture View (formerly Object TreeView) doesn't automatically scroll when in Drag&Drop [QC Description] When designing complex forms the content of Structure View doesn't fit on the screen. If you then try to move components in the Structure TreeView by Drag&Drop you can't drop it onto a TreeView node which is currently not visible because the TreeView doesn't scroll when you're pointing your mouse near the edges of the TreeView. That way Object TreeView loses it's most important feature (IMO) ! QC Entry 584

1. Create a new application 2. Drop quite a few buttons etc. on the form and a PageControl. 3. Open the Object TreeView (Alt+Shift+F11) 4. Resize the Object TreeView window so that not all nodes are visible and the scrollbars appear 5. Now try to drag one of the buttons TreeNodes to the edges of the TreeView exp: TreeView should automatically scroll act: Nothing

QC #: 1124 - Status: Closed

QC #: Project Date Reported: Area: 1124 C++Builder 9/9/2002 IDE\Translation Tools Description Steps:I can't port existing BCB5 translated applications. AFAICT there are several faults in the resulting BPRs including: UNITNAME is always "Form" CONTAINERID is always empty (though this may be correct). In addition "#pragma resource" has been changed so that you need double '\\'s to represent a single '\'. Having fixed these issues I can get the project to Build and Make but I get EResourceNotFound on running and when I try to open the form for viewing/designing I just get taken to the DFM in the edit window. ---------

1.Choose a VCL project with several forms. 2.\File\New\ and select Resource DLL Wizard 3.Click to the language selection page and enable a foreign language.4.Click on to finish and allow the IDE to recompile and create the new project. You will find the new project has only one form (probably the first listed in your original project) and that double clicking the form in the Project Manager only opens the file in the text editor. The pop-up menu has 'View as form' greyed out. If you attempt to compile this project it will fail at a #pragma directive. If you fix this by replacing '\' with '\\' it will compile and link but the

I tried recreating the project from scratch but after running the Resource DLL Wizard the translation project only had the first form listed. Aside from that it appeared to have the same BPR defects as the upgraded BPR. -------- None of the ITE menu items appear in the IDE although it is listed as an available package.

resulting DLL fails when you try and run it and is obviously deficient. // ADDITIONAL EXAMPLE OF 'BROKEN ITE' ////////////////////////////////// The 'RichEdit' example project shows some aspects of how broken the ITE is. Each international project does at least have two forms but: 1.They're both called "Form" in the Project Manager 2.You can't view/edit them as forms..only as DFMs. FWIW if you build the project it does work but obviously in its current state it would be a PITA to maintain.

QC #: 1155 - Status: Closed

QC #: Project Date Reported: Area: 1155 Delphi 12/18/1999 IDE\Open Tools API Description Steps:Add the ability to load and unload design-time packages to IOTAPackageServices. http://vmsfjira:8665/browse/RAD-3484

QC #: 1193 - Status: Closed

QC #: Project Date Reported: Area: 1193 C++Builder 5/10/2002 Compiler\C++\Back End Description Steps:Internal backend error compiling attached code old description in comment (used to be a link time problem)

bcc32 raid237320.cpp exp: clean compile act: CodeGear C++ 5.A0 for Win32 Copyright (c) 1993, 2007 CodeGear raid237320.cpp: Internal backend error W1517 compiling ???(0) *** 1 errors in Compile ***

QC #: 1315 - Status: Closed

QC #: Project Date Reported: Area: 1315 C++Builder 5/20/2002 Compiler\C++\Back End Description Steps:[QC Short Description] Back end error [QC Description] Posted by a user as a problem in BC++, this invalid code generates a back end error. in BCB6. --------- C:\Projects\Lookat\temp3 >type test24.cpp a(a) void a; {

a; } C:\Projects\Lookat\temp >bcc32 -c test24 Borland C++ 5.6 for Win32 Copyright (c) 1993, 2002 Borland TEST24.CPP: Warning W8054 TEST24.CPP 2: Style of function definition is now obsolete Warning W8070 TEST24.CPP 6: Function should return a value in function a() Internal backend error C6993 compiling TEST24.CPP(5) *** 1 errors in Compile *** C:\Projects\Lookat\temp > --------- QC Entry 1315

QC #: 1346 - Status: Closed

QC #: Project Date Reported: Area:1346 Delphi 5/24/2002 IDE\Project Management\Project Manager

Description Steps:[QC Short Description] control build order via drag and drop instead of endless "Build sooner/later" [QC Description] Like many others my projects (in the realworld sense) consist of quite a big number of individual projects (in the Delphi sense). Of course I need to order these based on their inter-dependencies to ensure a "build/compile all projects" will succeed. When I add projects to the project group they're always added at the bottom and I have to go through an almost endless cycle of right click/build sooner steps to put the new project in the place it belongs.It would be much nicer if I could just drag it to the desired position. An intermediate solution would maybe be if the new project would at least be inserted at the position where I invoked the "Add new/existing project" from the context menu. I suggest both. QC Entry 1346

QC #: 1936 - Status: Closed

QC #: Project Date Reported: Area: 1936 Delphi 7/26/2002 IDE\Search\Find in Files Description Steps:[QC Short Description] Allow "find in files" in properties on forms/datamodels/frames (DFMs) [QC Description] When finding in files only the source code is searched. There is no such function for searching in all forms / data models within a project / directory etc. Example: Your customer asks you to change all texts / labels / ... from Automobile to Vehicle. You know this word is present is source code, on many forms in captions, hints etc.

Do a "Find in files" on Automobile with the (Associated files checkbox enabled or something like that). When you select the Automobiles found on DFMs it popups the form, selects the correct component/control, popups the Object Inspector and selects the correct property. QC Entry 1936

QC #: 2334 - Status: Closed

QC #: Project Date Reported: Area: 2334 Delphi 9/12/2002 Midas\TClientDataSet Description Steps:Before first use of TClientDataSet.Filter, TClientDataSet.StatusFilter work as expected, but after - TClientDataSet.StatusFilter not worked. [Dave Rowntree: This problem also exists in D7] QC Entry 2334

TDBXFulcrumBugsSuite.Native.DB.Test.exe connection=ibconnection -s:TestRaid_160124 -OR- 1. Download, compile and run project in attachments 2. Follow on screen instructions to demonstrate the problem Note from Nick on 6/22/2010: Moved up in priority because of field test request

QC #: 2480 - Status: Closed

QC #: Project Date Reported: Area: 2480 C++Builder 9/24/2002 RTL\C++\Miscellaneous Description Steps:[QC Short Description] strtol and strtoul ( _i64toa and _ui64toa ? ) malfunction [QC Description] Short description: strtol and strtoul ( possibly _i64toa and _ui64toa as well) fail to detect input number overflow in some cases and return wrong result. Tested with BC 5.02, BCB5, BCB6( thanks to Jose Hortal) --------------------------------------------------------- Long description: When parsing input string with strto(u)l, numbers "near to" but greater than ULONG_MAX, both functions fail to detect overflow (don't set errno) and return wrong value. The numbers affected are defined with following rule: having char* ep; strtol( snumber, &ep , radix) where 'radix' defines valid _digits_ ['0','1',...N], AND if the last (rightmost) digit of ULONG_MAX converted to 'radix' representation is *not* equal to last valid digit N defined by 'radix', THAN all values between ULONG_MAX+1 and ULONG_MAX+n will be

1. bcc32 foo.cpp 2. foo.exe 3. press <space> to continue (increment base) <escape> to exit //exp : no RTL bugs to be reported //res : only tests with base 2,4,8,16 or 32 pass Create console application with attached test code. On output, "RTL bug:..." message is displayed for every value that is parsed wrongly.

parsed wrong, where 'n' is the difference between last valid digit N defined by 'radix',and last (rightmost) digit of ULONG_MAX represented with base 'radix'. The result of both functions, strtol and strtoul, will be equal to n-1 in this case and errno value will not be set to ERANGE as expected. Gee, even I don't understand what I wrote above :-) I hope an example will help having char* ep; strtol( snumber, &ep , 10) where 'radix' defines valid _digits_ ['0','1',...,'9'], AND ULONG_MAX is represented as "4294967295" in 10 base. Last (rightmost) digit of that number is '5' and last valid digit for 10 base is '9' therefore they arenot equal. THAN n = 9 - 5 == 4 => all these values will be parsed wrong: 4294967295 + 1 = 4294967296 ( strtol = 0 / errno = 0) 4294967295 + 2 = 4294967297 ( strtol = 1 / errno = 0) 4294967295 + 3 = 4294967298 ( strtol = 2 / errno = 0) 4294967295 + 4 = 4294967299 ( strtol = 3 / errno = 0) See attached test program that will run through all valid bases and display values that are parsed wrong. --------------------------------------------------------- Details: Looking at RTL source in "\Source\RTL\source\io\scantol.c" around line 178 overflow condition is tested with: oldresult = result; result = result * radix + digit; if ((result - digit) / radix != oldresult) { status = 2; / * overflow * / result = sign ? LONG_MIN : LONG_MAX; break; } This test is buggy. At a first glance it looks like the same problem is in "Source\RTL\source\io\scn2i64.c" (not tested) which affects _i64toa and _ui64toa. QC Entry 2480

QC #: 2499 - Status: Closed

QC #: Project Date Reported: Area: 2499 Delphi 9/25/2002 IDE\Search\Find in Files Description Steps:[QC Short Description] Redo a search using F5 or ctrl-R [QC Description] If focusing on a search tab in the message view, it would be very neat if it was possible to repeat the search with a single keystroke. F5 (common for refresh) or Ctrl-R would be fine. QC Entry 2499

Note, you can now use a menu item, but there should be a keystroke for that

QC #: 2750 - Status: Closed

QC #: Project Date Reported: Area:2750 Delphi 10/28/2002 VCL\System Controls\TDdeServerItem

Description Steps:[QC Short Description] TDdeServerItem.CopyToClipboard Fails [QC Description] Trying to find out why this simple method does not work brough me to the website: http://www.obsti.se/delphiexchange/dextras/ddefix.html It describes a simple fix for a serious problem which has been around since Delphi 1 !? It is using try..finally for the clipboard.close but the functionality fails miserably for it lacks any clipboard.open statement. QC Entry 2750 [In Delphi 7]

1. Place a TDdeServerConv and a TDdeServerItem and fill the properties. 2. Call DdeServerItem.CopyToClipboard. 3. Go to Word and attempt to Paste this link, you will fail. Reason: CopyToClipboard misses Clipboard.open procedure TDdeServerItem.CopyToClipboard; var Data: THandle; LinkData: string; DataPtr: Pointer; begin if FServerConv <> nil then LinkData := ddeMgr.AppName + #0 + FServerConv.Name + #0 + Name else if (Owner =nil) then Exit else if Owner is TForm then LinkData := ddeMgr.AppName + #0 + TForm(Owner).Caption + #0 + Name; try Clipboard.Open; (* << ADDED MISSING LINE --------------------------------------------------------- *)

QC #: 2913 - Status: Closed

QC #: Project Date Reported: Area:2913 Delphi 11/14/2002 VCL\Core VCL Classes\Streaming

Description Steps:[regression] program Project1; {$APPTYPE CONSOLE} uses SysUtils, classes; type tmyclass = class( tpersistent); begin registerclassalias( tmyclass, 'WillWork'); registerclassalias( tmyclass, 'D7WillRaiseAnException'); registerclassalias( tmyclass, 'D7WillNeverSeeThisLine'); end. This code works as expected with D5. It does not work with D7, since RegisterClassAlias calls RegisterClass which is no longer comparing the class pointer before checking the class name, thus raising an exception on the second call. JensG QC Entry 2913 trunk rev: 24740 update rev: 24745

QC #: 2925 - Status: Closed

QC #: Project Date Reported: Area:

2925 C++Builder 11/15/2002 Compiler\C++\Front End\Diagnostics

Description Steps:[QC Short Description] Function prototyping error [QC Description] For the following code: void fred( AnsiString const bill ); void fred( AnsiString bill ) { bill=AnsiString( "fred" ); } The compiler emits the error: [C++ Error] Unit1.cpp(18): E2285 Could not find a match for 'AnsiString::operator =(AnsiString)' My first thoughts were that this is confusing since it's saying that you can't assign an AnsiString to an AnsiString. After discussions on the newsgroups it appears that the error message is actually plain wrong and the code should compile cleanly. There is a workaround for this problem. QC Entry 2925

bcc32 -c raid238320.cpp exp: clean compile act: CodeGear C++ 5.A0 for Win32 Copyright (c) 1993, 2007 CodeGear raid238320.cpp: Error E2285 raid238320.cpp 9: Could not find a match for 'operator AnsiString::= (AnsiString)' in function fred(const AnsiString) *** 1 errors in Compile ***

QC #: 3399 - Status: Closed

QC #: Project Date Reported: Area: 3399 Delphi 1/22/2003 Debugger\Breakpoints Description Steps:[QC Short Description] Add ability for breakpoint to be active only in selected thread [QC Description] I have to debug the same code that is run in a few different threads, those threads don't bother each other. When I put a break point in the code, debugger stops when each thread reachs this point, but I only want one particular thread to stop there, that's why I have to observe thread window if I'm in the right one. The nice solution would be to select thread in the Threads Window then query popup menu on a thread and select for example 'disable debug' if the debugger for a thread is active or 'enable debug' if the debugger for a thread is inactive. Thread state during debugging would be presented with appropriate icon. QC Entry 3399

QC #: 3755 - Status: Closed

QC #: Project Date Reported: Area: 3755 C++Builder 3/5/2003 Compiler\C++ Description Steps:// reopened for QC 3755 Compilier and Linker should make the following items accessable by script - perhaps included with the version information.

Integration Build Number (not product version) SKU (if relevant) these two data points, along with the platform (which can be determined by the test tool), and the name of the binary file, should exactly identify the binary under test. This allows for automatic, unambiguous logging of exactly what is being tested, and to prevent the testing of one version and attributing the results to another.

QC #: 3791 - Status: Closed

QC #: Project Date Reported: Area:3791 Delphi 3/13/2003 VCL\Win 32 Controls\TToolBar

Description Steps:[QC Short Description] Setting the Visible property of TToolButtons to False at runtime causes other TToolButtons to behave incorretly [QC Description] I have a TToolBar with aprox 10 buttons. At runtime I hide some of these buttons. Some of the buttons that are left behave incorrectly. One on the buttons now does nothing, and another calls the wrong button click event. However, shortcuts for the buttons and Button.Click both still work. If I maximize the form the buttons start to work again. I did find this piece of code which does work, but I do not want to do this everytime I show/hide buttons on a TToolBar. pCaption := TToolBar.Buttons[0].Caption; TToolBar.Buttons[0].Caption := ''; TToolBar.Buttons[0].Caption := pCaption; QC Entry 3791

Run the attached example. Click the referrals button to open the child form with the toolbar on. Now click the "Elective Exward" button and nothing happens except you get a mouse drag icon. Note using the ALT+W key still works. Now click the "Add" button and the "Elective Exward" button event is called but using ALT+A still works. All the other buttons work fine. Now resize the form and ALL the buttons begin to work correctly????

QC #: 3820 - Status: Closed

QC #: Project Date Reported: Area: 3820 Delphi 3/16/2003 RTL\Delphi\Date - Time Description Steps:This has also been reported for BCB/6.0, report #3526. I just copied the same report here. HoursBetween does not return the correct value of HoursBetween in some cases. By analysing the behaviour of the functions involved in returning the number of hours, i found that the problem seems to be localised on the Trunc function (called in HoursBetween) returning 999 as the truncated value of 1000.000008, calculated by the Hourspan function.QC Entry 3820 [Top Ten]

Compile and run the attached program. See the following output. FAIL #2 FAIL FAIL #2 indicates that the expected value of 1000 was not seen from HoursBetween. program Test; {$APPTYPE CONSOLE} uses SysUtils, DateUtils; var datebeg, dateEnd: TDateTime; RetVal: Integer;

Counter: Integer = 0; begin datebeg := EncodeDateTime(2003,1,1,0,0,0,0); dateend := EncodeDateTime(2003,2,11,15,0,0,0); RetVal := HoursBetween(datebeg,dateend); if RetVal = 999 then Inc(Counter) else WriteLn('FAIL #1'); datebeg := EncodeDateTime(2003,1,1,0,0,0,0); dateend := EncodeDateTime(2003,2,11,16,0,0,0); RetVal := HoursBetween(datebeg,dateend); if RetVal = 1000 then Inc(Counter) else WriteLn('FAIL #2'); datebeg := EncodeDateTime(2003,1,1,0,0,0,0); dateend := EncodeDateTime(2003,2,11,17,0,0,0); RetVal := HoursBetween(datebeg,dateend); if RetVal = 1001 then Inc(Counter) else WriteLn('FAIL #3'); if Counter = 3 then WriteLn('PASS') else WriteLn('FAIL'); end.

QC #: 4149 - Status: Closed

QC #: Project Date Reported: Area:4149 Delphi 10/15/2009 3:53:52 PM RTL\Delphi\File Management

Description Steps:TStream.ReadBuffer() and TStream.WriteBuffer() fails for streams that cannot return/write the requested amount of data in one read/write.

In the classes unit source, see the following source. procedure TStream.ReadBuffer(var Buffer; Count: Longint); begin if (Count <> 0) and (Read(Buffer, Count) <> Count) then raise EReadError.CreateRes(@SReadError); end; procedure TStream.WriteBuffer(const Buffer; Count: Longint); begin if (Count <> 0) and (Write(Buffer, Count) <> Count) then raise EWriteError.CreateRes(@SWriteError); end; Note, that if Count number of bytes is not read or written that an exception is raised.

QC #: 4162 - Status: Closed

QC #: Project Date Reported: Area:4162 Delphi 4/21/2003 VCL\Core VCL Classes\TApplication

Description Steps:[QC Short Description] StayOnTop Bug in Delphi 6 and 7 but not in Delphi5

The following is very simple test. 1.First create a new project in Delphi7, set some properties of the main form (Form1) like this : Left

[QC Description] There is a bug in Delphi 6 and 7, and BDS2006 (not in Delphi 5). A form with FormStyle=fsStayOnTop will not stay on topmost in some situations.The following is very simple test. 1.First create a new project in Delphi7, set some properties of the mainform (Form1) like this : Left = 388 Top = 165 Width = 264 Height = 132 Hint = '11111111111111111111111111111111111111111111111' FormStyle = fsStayOnTop Position = poDesktopCenter ShowHint = True 2.Then run this program, and start another program, for example, the notepad.exe . 3.Drag form1 of project1 to overlap the window of notepad. Now form1 is properly staying on topmost. 4.Active project1 and move mouse over form1, now you can see the long hint '1111111111111111111111111'. 5.When hint showing( This is important!), move mouse quickly and click the window of notepad. Do you see the window of notepad overlap form1?Just try some times to switch between program quickly, you can find that form1 is not staying on topmost. 6. If you compile this project under delphi5, this bug is gone. Why the bug occurred in Delphi7 ? I found that the VCL of Delphi7 changed Forms.pas. The implements in TApplication.RestoreTopMosts and TApplication.DoNormalizeTopMosts are differ from Delphi5 implements. Delphi5 implements: procedure TApplication.RestoreTopMosts; var I: Integer; begin if (Application.Handle <> 0) and (FTopMostLevel > 0) then begin Dec(FTopMostLevel); if FTopMostLevel = 0 then begin for I := FTopMostList.Count - 1 downto 0 do SetWindowPos(HWND(FTopMostList[I]), HWND_TOPMOST, 0, 0, 0, 0, SWP_NOMOVE or SWP_NOSIZE or SWP_NOACTIVATE); FTopMostList.Clear; end; end; end; Delphi7 implements: procedure TApplication.RestoreTopMosts; var I: Integer; begin if (Application.Handle <> 0) and (FTopMostLevel > 0) then begin Dec(FTopMostLevel);

= 388 Top = 165 Width = 264 Height = 132 Hint = '11111111111111111111111111111111111111111111111' FormStyle = fsStayOnTop Position = poDesktopCenter ShowHint = True 2.Then run this program, and start another program, for example, the notepad.exe . 3.Drag form1 of project1 to overlap the window of notepad. Now form1 is properly staying on topmost. 4.Active project1 and move mouse over form1, now you can see the long hint '1111111111111111111111111'. 5.When hint showing( This is important!), move mouse quickly and click the window of notepad. Do you see the window of notepad overlap form1? Just try some times to switch between program quickly, you can find that form1 is not staying on topmost. 6. If you compile this project under delphi5, this bug is gone.

if FTopMostLevel = 0 then begin for I := FTopMostList.Count - 1 downto 0 do SetWindowPos(HWND(FTopMostList[I]), HWND_TOPMOST, 0, 0, 0, 0, SWP_NOMOVE or SWP_NOSIZE or SWP_NOACTIVATE or SWP_NOOWNERZORDER); FTopMostList.Clear; end; end; end; Note the flags in SetWindowPos is important! Delphi7 has a extra flagSWP_NOOWNERZORDER. This flag make the main form not stay on topmost. When this hint window is showing, switching between programs trigerTApplication.RestoreTopMosts and TApplication.DoNormalizeTopMosts. The hint window is a topmost window too. These codes run and make form1 not stay on topmost. SYSOP (comment from Jordan Russell): > Forms with fsStayOnTop will only stay on top of other windows in the ** same ** application. > > Hence, I believe this report is wrong. No, that is only true of secondary forms. By design, fsStayOnTop main forms will stay on top of all applications. (Check TApplication.DoNormalizeTopMosts and you'll see that it makes an exception for the main form.) Please re-open. QC Entry 4162

QC #: 4857 - Status: Closed

QC #: Project Date Reported: Area: 4857 Delphi 6/27/2003 IDE\Packages Description Steps:When using a package with search directories set in relative way (..\MainUnitDir) after selecting a host application the whole package thinks that it resides in the EXEs directory. So, if someone uses relative directories cant really debug a package. (unless package and EXE is in the same dir) QC Entry 4857

------------------- UPDATED ---------------------- + Reproduced in D7 + Pull PackageTestP.zip and extract it out \projects\PackageTestP directory + Pull MainAppTest.zip and extract it out to \projects\MainAppTest + Open PackageTestP's project + Click Project | Options + Set the search path to say ..\MainAppTest + Set Output directory to the PackageTestP directory + Set Unit output directory to PackageTestP directory + Build the package + Open the MainAppTest project + Build that project + Return to the PackageTestP + Click Run | Parameters + Set host application to MainAppTest.exe + Click OK + Set a break point in the procedure that is in the package. + Build to make sure you get a break point + Run //Notice that the breakpoint is never hit. ------------------- ORIGINAL -------------------- 1. Have a package with search directories set in relative mode 2. Choose Run > Parameters and assign a Host Application that is in a

diferent directory than the package.

QC #: 5269 - Status: Closed

QC #: Project Date Reported: Area: 5269 Delphi 7/17/2003 Debugger Description Steps:[QC Short Description] Add option to turn off "Source has been modified. Rebuild?" [QC Description] Add an Environment Option to turn on or off this message: "Source has been modified. Rebuild?" It is common to change code during debugging, whether intentionally or unintentionally. It is very annoying to be in the middle of debugging and have Delphi hang for 20 seconds while it determines if I have changed anything. It then interrupts what I am doing to ask me if I want to rebuild. I would like to turn this option off so that it never checks to see if I have changed anything. The compiler will check it again anyway the next time I build. (I'm using Delphi 6, so maybe this is already fixed in Delphi 7.) QC Entry 5269

Set a breakpoint in your code. Run the program to that breakpoint. Edit the code or add a comment, and save your work. Continue stepping through the code. Delphi will hang for a while, then ask if you want to rebuild.

QC #: 5338 - Status: Closed

QC #: Project Date Reported: Area:5338 Delphi 7/22/2003 VCL\Core VCL Classes\Streaming

Description Steps:Changing a Enumeration value that is published on a component causes undefined results. QC Entry 5338

Steps to produce 1. install the package attached with "TMyControl" 2. Open the Form1 from the Propread Project. 3. Make sure that the MyEnum property has the value enThree 4. save the form 5. remove the . from {.$DEFINE BUG} and recompile the package. 6. reopen the form. now the MyEnum property has the value enTwo, but no one has been noticed that the property was changed ! 7. do nothing else than save the form again. 8. Close the form and try to reopen the form. you will get the message "object expected on line 24" taking a look at the dfm you will see, that the MyEnum property has no longer a valid value assigned. The Problem is that GetEnumValue does return a (-1) if the Value does not exist. ReadPropValue from the reader does not check this value at all, and assigns it using SetOrdProp to the property. Delphi 5 raised a exception, which would be the correct solution.

QC #: 5521 - Status: Closed

QC #: Project Date Reported: Area:5521 C++Builder 8/6/2003 ActiveX\Type Library Editor Description Steps:[QC Short Description] Redundant semicolon always added to end of all implementation stubs! [QC Description] Minor problem When refresh implementation button is pressed all newly generated implementation stubs have a semicolon added at the end of the closing brace e.g. STDMETHODIMP TEDGMsgContextImpl::set_TargetAddress(long Value) { try { } catch(Exception &e) { return Error(e.Message.c_str(), IID_IEDGMsgContext); } return S_OK; }; There should NOT BE a semicolon HERE! Causes minor issues with source code validation tools (such as lint) QC Entry 5521

Should be self explanatory! If not then 1/ Create an automation object 2/ Add a method or property 3/ Refresh implementation 4/ Examine generated code

QC #: 5607 - Status: Closed

QC #: Project Date Reported: Area: 5607 Delphi 8/12/2003 IDE\Code Editor Description Steps:[QC Short Description] Include a Source Code Formatter in Delphi's IDE [QC Description] I think it would be useful if Delphi could auto-format EXISTING code, not just new code as it's being typed. Perhaps include a Source Code Formatter, which does one or more of the following: - Properly indents all code in a file to a given number of spaces (Report 1131). - Arranges all Begin/End statements consistently according to a style.- Sorts implementation of procedures and functions (Report 424). - Correct all Upper/Lowercase variables according to VAR declarations (Report 972). - Has the ability to apply these style changes to a single file or all files in a project. I realize that there are 3rd party tools that do this, but it would be much

easier if Delphi included it. QC Entry 5607

QC #: 5740 - Status: Closed

QC #: Project Date Reported: Area:5740 Delphi 8/27/2003 Debugger\Interaction with IDE

Description Steps:This is very irritating IMO since 99.9% of the time I say No. As the number compilation/run/debug cycles increases the latency between this prompt gets longer and longer. QC Entry 5740 Place a checkbox in the dialog: "Never ask me again"

1) set break point 2) run project 3) modify code (placing an extra space on a line of code is sufficient)4) Hit F9 to continue running You will see the dialog: --------------------------- Information --------------------------- Source has been modified. Rebuild? --------------------------- Yes No Cancel Help ---------------------------

QC #: 5793 - Status: Closed

QC #: Project Date Reported: Area:5793 C++Builder 9/1/2003 Compiler\C++\Front End\Templates

Description Steps:[QC Short Description] Correct Using declaration rejected [QC Description] Class-scope using declarations get incorrectly rejected if a symbol of the same name is already present in the class. QC Entry 5793 Happens in BCB6

bcc32 -c -w- raid236667.cpp exp: clean compile act: CodeGear C++ 5.A0 for Win32 Copyright (c) 1993, 2007 CodeGear raid236667.cpp: Error E2193 raid236667.cpp 20: Too few parameters in call to 'using_overloads_fr om_typename_base<int,base>::f(const int &)' in function test() *** 1 errors in Compile ***

QC #: 5809 - Status: Closed

QC #: Project Date Reported: Area: 5809 Delphi 6/8/1998 VCL\Core VCL Classes Description Steps:TWriter.WriteProperties should be moved from private to public visibility, to facilitate business object framework writers. Ref: QC1986 Right now, these people *must* go to TCollection/TCollectionItem to implement streamable properties in their frameworks.

QC #: 5880 - Status: Closed

QC #: Project Date Reported: Area: 5880 Delphi 9/5/2003 RTL\Delphi\Date - Time Description Steps:[QC Short Description] GetLocaleFormatSettings missing initialization and wrong argument [QC Description] The procedure GetLocaleFormatSettings appears to have two bugs. It fails to set the value of TwoDigitYearCenturyWindow. And the line GetLocaleMonthDayNames(LCID, FormatSettings); should be GetLocaleMonthDayNames(DefaultLCID, FormatSettings); Windows XP Home lets the user set how to interpret a two-digit year in Control Panel > Regional and Language Options > Regional Options > Customize > Date > Calendar. This would be a good value to set TwoDigitYearCenturyWindow to. QC Entry 5880

QC #: 6585 - Status: Closed

QC #: Project Date Reported: Area:6585 Delphi 12/9/2003 VCL\Core VCL Classes\Streaming

Description Steps:TReader.ReadBoolean only performs a "ReadValue = vaTrue" check to determine its return value, and since ReadValue only blindly reads and casts a byte, ReadBoolean will always pass whatever type was written is the filer. This leading to ReadErrors being detected in further "correct" filer reads at best, and at worse, this can result in undetected data loss/corruption. Also present in Delphi 5 and 6. QC Entry 6585

Paste the following code in a TButton click event f.i., run it. No error will be triggered. var str : TMemoryStream; rd : TReader; wr : TWriter; begin str:=TMemoryStream.Create; wr:=TWriter.Create(str, 1000); wr.WriteInteger(5); // could write about anything here wr.Free; str.Position:=0; rd:=TReader.Create(str, 1000); rd.ReadBoolean; // happy! rd.ReadBoolean; // happy! rd.Free; str.Free; end;

QC #: 7102 - Status: Closed

QC #: Project Date Reported: Area: 7102 Delphi 1/28/2004 Midas\TClientDataSet Description Steps:TClientDataset slows down with large data volume. As the amount of data contained within a TClientDataset increases, the speed at which a constant amount of data is inserted deteriorates almost linearly. This creates an overhead that ranges from annoying for a small volume of data to unacceptable for larger volumes. Also appending only one more record to a TClientdataset containing many rows is very slow. The problem seems to be severely aggravated by the use of large VARCHAR fields QC Entry 7102

Compile the attached project or run the provided executable and press Add Vessels. After pressing some times you will notice that the time it takes to add the data grows steadily.

QC #: 7524 - Status: Closed

QC #: Project Date Reported: Area:

7524 Delphi 3/5/2004 Compiler\Delphi\Language\Variants

Description Steps:[QC Short Description] VarArrayRedim() mistakenly changes low bound of rightmost array dimension [QC Description] When VarArrayRedim is called on a multidimensional array (2 or more dimensions) it changes its rightmost dimension low bound to that of the leftmost dimension. For example, when a bidimensional array with dimensions [0..1], [2..5] is VarArrayRedim'd to 6 it will end-up having the dimensions [0..1], [0..6]. This is because the writer of VarArrayRedim() did not take into account the fact that the indices vector that is passed in the SafeArrayXXX() windows api functions contains indexes IN REVERSE ORDER. Therefore the assignment: with LVarArray^ do VarBound.LowBound := Bounds[DimCount - 1].LowBound; is wrong. It should be: with LVarArray^ do VarBound.LowBound := Bounds[0].LowBound; because Bounds[DimCount - 1] corresponds to the leftmost dimension, not the rightmost. This is mentioned in MSDN in the description for e.g. function SafeArrayGetElement(): rgIndices: Pointer to a vector of indexes for each dimension of the array. The right-most (least significant) dimension is rgIndices[0]. The left-most dimension is stored at rgIndices[psa->cDims - 1]. QC Entry 7524

Compile and run the attached application below. program BTS242389; {$APPTYPE CONSOLE} uses Variants, SysUtils; var V: Variant; begin V := VarArrayCreate([0,1, 2,5], varVariant); WriteLn(Format('[%d..%d] [%d..%d]', [VarArrayLowBound(V, 1), VarArrayHighBound(V, 1), VarArrayLowBound(V, 2), VarArrayHighBound(V, 2)])); VarArrayRedim(V, 6); WriteLn(Format('[%d..%d] [%d..%d]', [VarArrayLowBound(V, 1), VarArrayHighBound(V, 1), VarArrayLowBound(V, 2), VarArrayHighBound(V, 2)])); end. One would expect that the second message would display [0..1] [2..6] but it displays [0..1] [0..6] instead. Change the low bound of the first dimension to any number you want and run the program again. You will see that after VarArrayRedim the low bound of the second dimension will be the same as the low bound of the first dimension and not 2. NOTE: I added TVariantsTests.Test_VarArray_Redim to rtl\test\UnitTest.Variants.

QC #: 7652 - Status: Closed

QC #: Project Date Reported: Area: 7652 C++Builder 10/8/1997 IDE\Menu Designer Description Steps:Stream Read Error is generated if there is a zero length BCB.DMT file in the BIN directory. Same report #31122

Originally #7652: -unzip the attached BCB.DMT and place in BIN. -Launch BCB.EXE result: Stream Read Error Would it be possible to protect this file with a lock file such as BCB.DRL does for BCB.DRO? This file seems particularly subject to corruption judging by the frequency of this error being reported in the newsgroups.

QC #: 8070 - Status: Closed

QC #: Project Date Reported: Area: 8070 Delphi 5/5/2004 RTL\Delphi\Math Unit Description Steps:This also happens in BDS 2006 and Highlander. [QC Short Description]

With a TButton (Button1)and a TMemo (Memo1), code the following procedure TForm1.Button1Click(Sender: TObject); var e: extended; begin e := RoundTo(1.235, -2);

RoundTo and SimpleRoundTo are very sick [QC Description] Help says about RoundTo(): "Rounds a floating-point value to a specified digit or power of ten using Banker's rounding." And the D7 help further says gives these examples: RoundTo(1.235, -2) ->1.24 RoundTo(1.245, -2) -> 1.24 But in reality: RoundTo(1.235, -2) ->1.24 RoundTo(1.245, -2) -> 1.25 RoundTo does indeed "use" bankers rounding to arrive at its result, but it uses it incorrectly. For an example of good, well tested decimal rounding routines for the extended, double, and single number types, see my DecimalRounding (JH0) package in CodeCentral at URL: http://codecentral.borland.com/codecentral/ccweb.exe/listing?id=17998(I can give you my test program if you are interested.) The SimpleRoundTo function suffers a similar problem. The Help file says "SimpleRoundTo uses asymmetric arithmetic rounding to determine how to round values that are exactly midway between the two values that have the desired number of significant digits. This method always rounds to the larger value." SimpleRoundTo happens to give the correct results for the examples given in the Help file; but for other values, gives results that don't seem to "jive" with the Help description. E.g. SimpleRoundTo(1.005, -2) -> 1.00 Now, floating point experts will recognize that the possibility of an input decimal fraction number being "exactly midway between the two values that have the desired number of significant digits" is *very* small. This probably is so small, in fact, that the help definition of "midway" very rarely comes into play, as it did not in the example immediately above. The Help definition can however easily mislead the neophyte programmer. QC Entry 8070 [BCMF]

Memo1.Lines.Add(Format('RoundTo(1.235, -2) -> %0.4f (S.B. 1.24)',[e])); e := RoundTo(1.245, -2); Memo1.Lines.Add(Format('RoundTo(1.245, -2) -> %0.4f (S.B. 1.24)',[e])); end; When executed, you will get RoundTo(1.235, -2) -> 1.2400 (S.B. 1.24) RoundTo(1.245, -2) -> 1.2500 (S.B. 1.24) Notice the error in the second test.

QC #: 8616 - Status: Closed

QC #: Project Date Reported: Area: 8616 Delphi 7/10/2004 IDE\Packages Description Steps:[QC Short Description] Include an Uninstall/Remove context menu item in the project manager when a package is loaded. [QC Description] When a package project is open in the project manager. I would like an Uninstall context menu item, so that the package can be unloaded from the IDE easily. QC Entry 8616

QC #: 8617 - Status: Closed

QC #: Project Date Reported: Area:8617 Delphi 7/10/2004 IDE\Project Management\Project Manager

Description Steps:[QC Short Description] Add Compile All and Build All context menu items to the project group node [QC Description] Can you please add Compile All and Build All context menu items when you select the Project Group node in the Project Manager. QC Entry 8617

QC #: 8626 - Status: Closed

QC #: Project Date Reported: Area: 8626 C++Builder 7/12/2004 Documentation Description Steps:[QC Short Description] Internal error: L3170 [QC Description] Internal error while build. Could not find any description of this internal error from net (There used to be some very good list of these, can't remember where tough) If someone has any info please let me know. QC Entry 8626

QC #: 8649 - Status: Closed

QC #: Project Date Reported: Area:8649 Delphi 7/16/2004 Documentation\IDE Help Contexts Description Steps:[QC Short Description] Small error in Example for EConvertError [QC Description] There should be one more "end" in Delphi example QC Entry 8649 Also, sentence formatting is wrong: "EConvertError is raised when An application makes an unsuccessful... "

Open this page of the help file. ms-help://borland.bds3/bds3win32api_win32/html/SysUtilsEConvertErrorClass.htm The delphi example is missing an end to complete the try..except statement. ============= the text for 2010 at http://docwiki.embarcadero.com/VCL/en/SysUtils.EConvertError is still broken: //Delphi example const LF = #10; var TempDate: TDateTime; begin try TempDate := StrToDateTime('99/99/1998'); except on E: EConvertError do ShowMessage(E.ClassName + LF + E.Message); end; =============

QC #: 8762 - Status: Closed

QC #: Project Date Reported: Area: 8762 Delphi 8/9/2004 Midas Description Steps:[QC Short Description] 'invalid blob handle in record buffer' for details when using poFetchDetalsOnDemand [QC Description] When one uses server-side (nested) details and poFetchDetailsOnDemand and any blob field in detail dataset, 'invalid blob handle in record buffer' appears immediately (not for master dataset, only for detail). poFetchBlobsOnDemand is not needed for this to appear, though with it situation is same. Without both poFetchDetailsOnDemand and poFetchBlobsOnDemand everything seems to be fine. QC Entry 8762

BugSuite.MIDAS.Native.DB.Test.exe connection=ibconnection -s:TestRaid_208267 -or- 1. Download an unzip the test case app from Attachments. 2. Open the test case project in Delphi. 3. Compile and run. 4. follow the on screen steps.

QC #: 8800 - Status: Closed

QC #: Project Date Reported: Area:8800 Delphi 8/14/2004 Database\Data Aware Controls\TDBGrid

Description Steps:[QC Short Description] Mixing lookup fields with numeric and string keys in a DBGrid throws exceptions [QC Description] Added by Sysop <<<<<<<< This issue still exists in Delphi 2010. Please see attached Delphi project to reproduce this issue. >>>>>>>> When a DBGrid includes lookup fields with different types of keys (e.g.- String and numeric) then editing one field and then the other can throw exceptions for "key not found" and type mismatches. The problem seems to be in the DBGrid code on the first of two updates of the pulldown list where it incorrectly uses the previous key, from the previous field. If the type is different it causes problems. The second update corrects the problem. The exceptions are only seen in the debugger, not in the final application run by itself (i.e.- not seen by the user). This was only tried with ClientDataSets, though it is probably a problem with other data sources since it seems to be in the DBGrid code. QC Entry 8800

A simple BCB demonstration program is attached, or you can create your own: - Create a couple of lookup data sets, one with a numeric key and one with a string key. - Create a dataset that includes numeric and string fields to use as keys, and add two lookup fields, one based on the numeric key and lookup dataset and the other string based. - Drop a grid on your form and link it to the main dataset. - Add code to your form initialization to put some data in the lookup tables. - Run the application and make a selection from the pulldown list of the string based lookup field. Then try to make a selection from the numerically keyed lookup field pulldown. You will see the exception(s) in the debugger, and then be able to continue on and finally make the proper selection.

QC #: 9600 - Status: Closed

QC #: Project Date Reported: Area: 9600 Delphi 11/24/2004 Midas Description Steps:[qa note] this has been around since D7. [QC Short Description] 'operation not applicable' for reediting nested detail dataset after refresh of master (poFetchDetailsOnDemand on) [QC Description] When one uses server-side (nested) detail, after editing detail value,

BugSuite.MIDAS.Native.DB.Test.exe connection=ibconnection -s:TestRaid_222601 -OR- 1. Download an unzip the test case app from Attachments. 2. Open the test case project in Delphi. 3. Change netfiledir and privatedir in session component if needed 4. Compile and run.

applying updates (or only merging changelog), refereshing master and editing same value again 'operation not applicable' is raised on posting. poFetchDetailsOnDemand must be set on provider for it, without it all seems to be working well. QC Entry 9600

5. Click on button to produce the error. The demo uses standard DBDEMOS using bde/paradox. The demo is created using delphi 7.1 + latest beta update, but i tried it with delphi 2005 trial with same results.

QC #: 10315 - Status: Closed

QC #: Project Date Reported: Area: 10315 Delphi 1/12/2005 IDE\History View Description Steps:[QC Short Description] There are no shortcuts to the difference viewer for the history view [QC Description] There are no shortcuts to the difference viewer for the history view QC Entry 10315

QC #: 10355 - Status: Closed

QC #: Project Date Reported: Area:10355 Delphi 1/13/2005 Documentation\Online Help\Main help

Description Steps:[QC Short Description] No documentation for regular expression syntax [QC Description] The "Find", "Find in Files", and "Replace" dialogs all have a checkbox labeled "Regular expressions". Delphi 2005's Help files have no information about the syntax for these regular expressions. This is a problem, especially since the regex syntax is nonstandard. (There's not even anything to show which regex features aren't supported.) This is a regression from the Delphi 7 Help. Delphi 7's Help file did include a page that listed the special syntax available in a regex, and the "Search|Find", "Search|Find in Files", and "Search|Replace" Help topics all hyperlinked the words "regular expressions" to this page. QC Entry 10355

Sysop Edit: Url is ms-help://borland.bds3/bds3ui/html/Find.htm <<<<<PUT IN JIRA FEB 2009>>>>>

QC #: 10526 - Status: Closed

QC #: Project Date Reported: Area: 10526 Delphi 1/21/2005 RTL\Delphi\Other RTL Description Steps:[QC Short Description] Inline StrUtils.IfThen [QC Description] Inline StrUtils.IfThen QC Entry 10526

QC #: 11861 - Status: Closed

QC #: Project Date Reported: Area:11861 Delphi 4/5/2005 RTL\Delphi\Format + Float Description Steps:[QC Short Description] Format a 1 character string with a precision specifier of 0 does not truncate to 0. [QC Description] Format's help indicates that %s can have a precision specifier on it that will truncate the string to the length of the precision specifier. The problem is that if you supply a 0 and the string that will be substituted is only 1 character long, the resultant string is not truncated to 0 length.QC Entry 11861

Compile and run the attached application below. See the following output indicating failure. FAIL #1 S:===a=== (JJS: Note: running with the .NET compiler also produces a failure as seen below.) FAIL #1 S:===a=== FAIL #2 S:===aa=== program BTS257259; {$APPTYPE CONSOLE} uses SysUtils; var S: String; Counter: Integer = 0; begin S := Format('===%.*s===',[ord(false),'a']); if S = '======' then Inc(Counter) else WriteLn('FAIL #1 S:', S); //returns "===a===" (incorrect) S := Format('===%.*s===',[ord(false),'aa']); //returns "======" (correct) if S = '======' then Inc(Counter) else WriteLn('FAIL #2 S:', S); if Counter = 2 then WriteLn('PASS'); end.

QC #: 12162 - Status: Closed

QC #: Project Date Reported: Area: 12162 Delphi 4/20/2005 IDE\History View Description Steps:[QC Short Description] Use a custom comparison tool in History/Diff tab. [QC Description] It would be nice to use a custom comparison tool from the History tab. This would allow Borland tool developers to kick off the best comparison tool on the market, Beyond Compare, the product of a Borland tool. Bonus if Beyond Compare comparison window could be integrated into the IDE. Info on BeyondCompare: http://www.scootersoftware.com QC Entry 12162

QC #: 12695 - Status: Closed

QC #: Project Date Reported: Area:12695 Delphi 5/10/2005 Compiler\Delphi\Language\Overloading

Description Steps:[QC Short Description] Confusion with strict protected and protected overloaded methods [QC Description] If a method is overloaded and one or more are strict protected and one or more are protected, the compiler only considers the first mentioned overload to determine accessibility. As a result, the compiler may give errors in cases where it should compile without errors. Obvsiouly, this is a minor problem with an easy workaround in most cases (swap the order of declaration). QC Entry 12695 (JJS: Initially logged in Delphi.NET but present for Delphi Win32 as well.)

Compile the attached program below. See the following compile time errors. Error: E2362 Cannot access protected symbol TestClass.Check2 Error: E2003 Undeclared identifier: 'Check1' In a text editor, select the text between the lines labeled #1 and #2, copy the text to the clipboard, and delete the highlighted text. Now position the text cursor on the line beneath the one labeled #3 and paste in the text from the clipboard. Recompile the application and see that compilation succeeds as was initially expected. program BTS257291; {$APPTYPE CONSOLE} type TestClass = class //#1 strict protected class procedure Check1(param1, param2: Integer); overload; static; procedure Check2(param1, param2: Integer); overload; //#2 protected class procedure Check1(param1: Integer); overload; static; procedure Check2(param1: Integer); overload; //#3 end; TestClass2 = class strict private FTest: TestClass; public procedure CheckInOther; end; class procedure TestClass.Check1(param1, param2: Integer); begin end; procedure TestClass.Check2(param1, param2: Integer); begin end; class procedure TestClass.Check1(param1: Integer); begin end; procedure TestClass.Check2(param1: Integer); begin end; procedure TestClass2.CheckInOther; begin FTest.Check2(1); end; begin TestClass.Check1(1); WriteLn('PASS'); //PASS on compile end.

QC #: 12709 - Status: Closed

QC #: Project Date Reported: Area: 12709 Delphi 5/10/2005 IDE\Structure Pane Description Steps:[QC Short Description] Cannot drop components onto the Structure Pane [QC Description] When moving from Delphi 7 to Delphi 2005 one obvious flaw in the new IDE is that you cannot drop components from the Tool Palette to the Structure Pane (used to be called the Object Tree View). This was a great feature in Delphi 7 and I really miss it. Would be also great if you could drag components from the Tool Palette to the structure pane since the Tool Palette now supports the dragging of components. QC Entry 12709

1. Create a form. 2. Drag a panel to the form. 3. Select a label from the Tool Palette and attempt to drop it onto the panel shown in the structure pane. ext: Label to be created and parented by the panel act: Dropping of label not accepted NOTE: The Structure Pane shows a blue line between the tree view entries but even when this is displayed the drop operation doesn't succeed.

QC #: 12775 - Status: Closed

QC #: Project Date Reported: Area: 12775 Delphi 5/12/2005 VCL\Graphics Description Steps:[QC Short Description] TJPEGImage raises AV when beeing assigned if empty [QC Description] If an empty TJPEGImage is assigned to a say a TBitmap, it will produce an Access Violation. This is because it notices that it hasn't decompressed the jpeg data, and tries to do this, without checking if there actually IS any jpeg data. This is also present in Delphi 7 and possibly other versions. QC Entry 12775 (exist in D7)

Run the following program: program JpegCrash; uses Graphics, Jpeg; var bmp: TBitmap; jpg: TJPEGImage; begin bmp:= TBitmap.Create; jpg:= TJPEGImage.Create; bmp.Assign(jpg); // will AV jpg.Free; bmp.Free; end.

QC #: 12909 - Status: Closed

QC #: Project Date Reported: Area:12909 Delphi 5/18/2005 IDE\Packages\New Component Wizard

Description Steps:[QC Short Description] The palette page combobox should be sorted alphabetically in the New VCL Component wizard [QC Description] When creating a New VCL component I was expecting the Palette Page combobox that lists all of the current palette pages to display them in alphabetical order. Currently they are displayed in the order they appear within the Tool Palette. It would be a lot more efficient to search for a particular page if the list was sorted alphabetically. QC Entry 12909

QC #: 14169 - Status: Closed

QC #: Project Date Reported: Area: 14169 Delphi 7/6/2005 IDE\Form Designer Description Steps:Forms Preview: [QC Short Description] Display x,y coordinates as you mouse over / interact with the preview window [QC Description] > 1) report the x,y as you mouse over or move the object QC Entry 14169

Using the embedded Form Designer: Create a new Delphi VCL app With the form designer active, drag the shape around the form position preview control that is shown in the lower right corner of the form designer pane EXP: The Top/Left coordinates of the form are shown in a tooltip hint as you drag the form shape ACT: No tooltip hint is shown

QC #: 15374 - Status: Closed

QC #: Project Date Reported: Area: 15374 Delphi 8/24/2005 Documentation Description Steps:[QC Short Description] Help for Code Insight options page is outdated [QC Description] The help is way outdated for the new Code Insight features as mentioned on the current Code Insight documentation page. The Symbol Color information is now located on a new node in the Options Tree. ms-help://borland.bds4/bds4ref/html/codeinsight.htm QC Entry 15374

Start Dexter Tools | Options Select the Code Insight node under the Editor Options node Press the HELP button.

QC #: 16017 - Status: Closed

QC #: Project Date Reported: Area: 16017 Delphi 9/16/2005 RTL\Delphi\Other RTL Description Steps:[QC Short Description] Comparision of 2 BCD values gives wrong result [QC Description] The BcdCompare function must return -1,0,1 values, according spec. The comparision of variants storing BCD values depends on that, because following method is programmed so: function TFMTBcdData.Compare(const Value: TFMTBcdData): TVarCompareResult; begin Result := TVarCompareResult(BcdCompare(Self.FBcd, Value.FBcd)+1); end; But BcdCompare may return, in general, values from -9 to 9. That is because BcdCompare calls function CompareNormalizedFractions, and it has the code: N1 := BcdIn1.Fraction[I] shr 4; N2 := BcdIn2.Fraction[I] shr 4; Result := N1 - N2;

(JJS: Here's the test case, but it compiles and runs for me.) program BTS273740; { Comparision of 2 BCD values gives wrong result } {$APPTYPE CONSOLE} uses SysUtils, Variants, FmtBCD; procedure DoTest; var v1, v2: Variant; begin v1 := VarFMTBcdCreate(StrToBcd('-4567890123.4568')); v2 := VarFMTBcdCreate(StrToBcd('-234567890')); if v1 < v2 then WriteLn('PASS') else

...... Exit; QC Entry 16017

WriteLn('FAIL'); end; begin try DoTest; except on E: Exception do begin Writeln('FAIL - Exception error'); WriteLn(' ClassName=', E.ClassName); WriteLn(' Message=', E.Message); end; end; end.

QC #: 18567 - Status: Closed

QC #: Project Date Reported: Area:18567 C++Builder 10/20/1999 Compiler\C++\Front End\Exception Handling

Description Steps:According to 15.5.1 (1), the terminate function should be called when the destruction of an object during stack unwinding (15.2) exits using an exception. bcc32 generates code that does not call terminate in this case. #include <exception> using std::set_terminate; using std::terminate_handler; #include <cstdio> using std::printf; using std::puts; #include <cprocess> using std::exit; terminate_handler oldterminate; void myterminate(){ exit ((puts("passed"),0)); } struct D{ D(); ~D(); static int i; }; int D::i = 0; inline D::D(){ ++i; printf("D ctor %d\n", i); if (i == 2) throw 0; } inline D::~D(){ printf("D dtor %d\n", i); --i; throw 0; } int main() { oldterminate = set_terminate( myterminate ); try { D d[3]; } catch(...){ puts("Caught int"); } return ((puts("failed"),1)); } [QC Entry 18567]

bcc32 test0098.cpp test0098.exe //res: D ctor 1 D ctor 2 D dtor 2 Caught int failed //exp: D ctor 1 D ctor 2 D dtor 2 passed

QC #: 18685 - Status: Closed

QC #: Project Date Reported: Area: 18685 C++Builder 2/3/1997 Debugger\Call Stack Description Steps:Call Stack view's vertical scroll bar thumb is not proportional. It is always the same size no matter how many calls are in the stack [QC Entry 18685]

File|New app Create an infinitely recursive function in unit1.cpp Call the function from the TForm1 ctor Step through many iterations of the recursive function while the Call Stack view is open The vertical scroll bar thumb should decrease in size with each iteration

QC #: 19727 - Status: Closed

QC #: Project Date Reported: Area: 19727 Delphi 10/3/2005 RTL\Delphi\Math Unit Description Steps:(JJS: Not yet delivered in 14.0.3559.24962, not certain if this will come in for Update 2 due to unit versioning) [QC Short Description] Provide overloaded procedures of SinCos [QC Description] Please provide overloaded procedures of the SinCos procedure in math.pas. SinCos is available as: procedure SinCos(const Theta: Extended; var Sin, Cos: Extended); but Double and Single are also necessary: procedure SinCos(const Theta: Double; var Sin, Cos: Double); procedure SinCos(const Theta: Single; var Sin, Cos: Single); program test; var s,c: Double; begin SinCos(1.234, s, c); //not possible in this case due to Double vars. end; QC Entry 19727

Also look at all related functions to see if they also need overloads

QC #: 20051 - Status: Closed

QC #: Project Date Reported: Area: 20051 Delphi 10/12/2005 IDE\Search Description Steps:[QC Short Description] Remove modal search dialog and add a "Firefox Search Bar" [QC Description] Currently, the current file search feature of the IDE pops up a modal dialog box, which the user fills out, and which then requires a click. Since modal dialogs are rapidly going out of style, please institute a search functionality similar to that found in the Firefox web browser. Rather than pop up a modal dialog, the IDE should display at the bottom of the editor a small tool bar that allows the user to type the search phrase into an edit box. Incremental search is done as the user types. If the user types something that is not found in the file, then a small "not found" sound is played. The tool bar can have common search choices such as "Match Case", "Find Next", "Find Previous", etc. I've grown quite used to the Firefox Search model, and really like it. I think it would make a great addition to the Delphi IDE. QC Entry 20051

QC #: 20171 - Status: Closed

QC #: Project Date Reported: Area:

20171 Delphi 10/16/2005 Documentation\Online Help\VCL Description Steps:[QC Short Description] Editorial error in help for RecodeMillisecond function [QC Description] The help page (in the text body) for RecodeMillisecond refers to the function twice as "RecodeDateMilliSecond". (does this one compete for Yawn of the Year Award? <g>) QC Entry 20171

Open the following help page and note the incorrect spelling of the routine. ms-help://borland.bds3/bds3win32api_win32/html/DateUtilsRecodeMilliSecondRoutine.htm

QC #: 20184 - Status: Closed

QC #: Project Date Reported: Area: 20184 Delphi 10/16/2005 IDE\Menus Description Steps:[QC Short Description] Edit menu items missing [QC Description] Several items are missing from the Edit menu until either: A new project is created; or An existing project is opened and one of it's forms is clicked. QC Entry 20184

+ Close Dexter if it is already opened + Startup DeXter + Click Edit menu //exp: menu items disabled //act: as expected + Create a new project + Click Edit menu //exp: Align, Size, Tab order etc show up //act: As Expected + Click File | Close All + Click Edit menu //Exp: All menu items are disabled //act: Align, Size, Tab order (things having todo with the form designer remains enabled. Clicking on them does nothing to the IDE. ------------- ORIGINAL STEPS -------------------- If DeXter is running, close it. 1) Run DeXter. 2) Click on the Edit menu and observe the items listed: Undo Redo Cut Copy Paste Delete Select All Align to Grid Bring to Front Send to Back 3) Create a new project - don't click on its form or editor window. 4) Several new items appear on the Edit menu: Align... Size... Scale... Tab Order... Creation Order... Flip Children Lock Controls 5) Close DeXter and reopen it.

6) Check the Edit menu to verify the items are again missing. 7) Reopen an existing project. 8) Check the Edit menu - the items are still missing. 9) Click on the edit window. 10) Check the Edit menu - the items are still missing. 11) Click on the project's form. 12) Check the Edit menu - the items have appeared. 13) Close the project. 14) Check the Edit menu - the items are sill there.

QC #: 20222 - Status: Closed

QC #: Project Date Reported: Area:20222 Delphi 10/17/2005 Documentation\Online Help\VCL

Description Steps:[QC Short Description] Missing Information (W1000 Symbol Depreciated) [QC Description] Compiling some older Packages I got: W1000 Symbol Depreciated on AllocateHwnd, DeallocateHwnd These must be documented to point to what should be being used if they are now depreciated. Also got the same error of "FileAge" but the documentation does NOT show that it is depreciated -- this page needs to be updated to show it is depreciated and I should be using. QC Entry 20222

QC #: 21045 - Status: Closed

QC #: Project Date Reported: Area: 21045 Delphi 11/5/2005 RTL\Delphi\WinAPI Description Steps:[QC Short Description] Merge shldisp.h translation in ShlObj.pas ? [QC Description] The shldisp.h header contains many interfaces/functions/types/structures/constants to access the content of the right plane of the shell view. All computers running at least Internet Explorer 4 (or the corresponding Shell32.dll) support these declarations. It can be generated by importing the type library of Shell32.dll, but it would be great if the Delphi RTL provides this unit. QC Entry 21045

QC #: 21119 - Status: Closed

QC #: Project Date Reported: Area: 21119 Delphi 11/7/2005 RTL\Delphi\Math Unit Description Steps:[QC Short Description] Please inline the InRange and RandomFrom functions in math.pas [QC Description] Please inline the InRange and RandomFrom functions in math.pas Description says it all :-) QC Entry 21119

// see description

QC #: 21140 - Status: Closed

QC #: Project Date Reported: Area: 21140 Delphi 11/7/2005 Debugger\Stepping Description Steps:[QC Short Description] Stepping/debugging within selected thread(s) only [QC Description] When debugging multi-threaded applications single stepping the debugger can cause jumps between threads. This is of course not an error but it can be rather anoying. I suggest a Ctrl/Shift/Alt F7/F8 or whatever key combination that will cause the debugger to not stop in other threads but only in the relevant thread. It would also be great to be able to enable/disable breakpoints/breakpoint groups based on what thread they are activated in. Of course this feature is equally relevant in Win32 and .NET. QC Entry 21140

QC #: 21417 - Status: Closed

QC #: Project Date Reported: Area:21417 C++Builder 11/14/2005 ActiveX\IDE\Project Manager Interaction

Description Steps:[QC Short Description] Project Manager does not display the Project_TLB.h file [QC Description] The Project Manager never displays the Project_TLB.h file of an ActiveX Library. It does display the Project_TLB.cpp file by itself, which rarely does anything when clicked on. QC Entry 21417 [ BCB6 : true ] As designed ? // this is why 236414 is happened ( _TLB.h is not part of project file, kind of )

File | New | Other | ActiveX | ActiveX Library Expected: "Project_TLB.cpp" treenode that displays two child nodes - "Project_TLB.cpp" and "Project_TLB.h" Actual: "Project_TLB.cpp" treenode that has no child nodes at all. File | Save All create new directory and save all files Flie | Close All File | Reopen and selcet the project check nodes on PM // _ATL.cpp has sub nodes _ATL.cpp

_ATL.h // _TLB.cpp doesn't have sub node

QC #: 21439 - Status: Closed

QC #: Project Date Reported: Area:21439 Delphi 11/15/2005 IDE\Code Editor\Error Insight Description Steps:[QC Short Description] Error Insight False Error, even compile returns no error [QC Description] The Delphi Win32 personality has a bug in error insight. QC Entry 21439 [borland.private.fieldtest.dexter.ide] [2142 Win32 Delphi] Error Insight Bug?

type var MAXVALIDATEEXTENDED2 : Extended = 1E2000; Gets a red underline at '1', but compiles fine.

QC #: 21443 - Status: Closed

QC #: Project Date Reported: Area: 21443 Delphi 11/15/2005 IDE\Object Inspector Description Steps:[QC Short Description] Object Inspector now shows references to other units in C++ style. [QC Description] When linking components to objects in datamodules or other units, the Object Inspector uses '->' instead of a '.'. (DataModule1->ClientDataSet1 instead of DataModule1.ClientDataSet1) QC Entry 21443 [borland.private.fieldtest.dexter] [ ref : 235677 ]

(Make Sure C++ is installed) 1. Create a new Delphi VCL app. 2. Add a DataSource to the form. 3. Add a new form. 4. Add a ClientDataSet to the form. 5. Back to the first form, File/Use Unit, use the second. 6. Select the datasource, and on the Object Inspector set its DataSet property to Form2.ClientDataSet1. exp: "Form2.ClientDataSet1" act:: "Form2->ClientDataSet1"

QC #: 22015 - Status: Closed

QC #: Project Date Reported: Area: 22015 Delphi 12/7/2005 IDE\Code Editor Description Steps:[QC Short Description] Bookmark icon when font size is 8 [QC Description] When font in editor is Courier New and size is 8, when you use bookmarks in the editor, removing a bookmark will not remove the top line of the icon. It appears that the redraw routine follow the height of the font, and since the icon is a little bigger, the first pixel line of the icon will not be redrawn until you move the cursor up one line. QC Entry 22015

Open D2006 Go into Tools>Options>Editor Options>Display, set Editor font to Courier New and Size to 8 (or 9) and press Ok. Create a bookmark in source by using Ctrl+Shift+1. Press Ctrl+Shift+1 again and notice that a part of the icon will not be removed. Move the cursor up one line, and the icon part will disappear. Looks like the redraw of the icon use the font height, and the icon is higher than this height.

QC #: 22088 - Status: Closed

QC #: Project Date Reported: Area:

22088 C++Builder 12/8/2005 IDE\Packages Description Steps:[QC Short Description] Component does not appear in C++ tool palette [QC Description] If a Delphi package is installed without the option generating all C++ builder files, then it won't appear in C++ tool palette, which is correct. However, if you go back to the package and select "Generate all c++ builder files", rebuild and remove + reinstall package, the components still won't appear in C++ tool palette. It seems that it is marked as a Delphi package forever, until you recreate the package in Delphi and save it as a different name. QC Entry 22088

NOTE: I've tracked this down to the package cache in the registry. deleting this is a workaround. It should be deleted whenever a package is installed. Create a Package in Delphi, and create an empty TComponent descendent to go with it. Build and install. Create a VCL Form app in C++. Save and Close. Remove bpl from package list. Open Package again, go to Project Options | Linker | Generate all C++ builder files. Build and install. Open the C++ VCL Form app again. Try to find the component you've created in Delphi -- not found!

QC #: 22809 - Status: Closed

QC #: Project Date Reported: Area: 22809 Delphi 12/26/2005 IDE\Form Designer Description Steps:[QC Short Description] Access violation when deleting FlowPanel [QC Description] Under special circumstance (see steps), deleting a FlowPanel in the FormDesigner causes an AV which renders the IDE totally unstable, so it has to be killed with the Task Manager. QC Entry 22809 Stack: + $8[51F315B6]{rtl100.bpl } Classes.Classes.TList.IndexOf (Line 3018, "classes.pas" + 2) + $8 + $0[51F06B47]{rtl100.bpl } System.System.@HandleAnyException (Line 9980, "system.pas" + 13) + $0 + $41[7C903786]{ntdll.dll } RtlConvertUlongToLargeInteger + $41 + $9[7C90EAF5]{ntdll.dll } KiUserExceptionDispatcher + $9 + $6[5203C998]{vcl100.bpl } Controls.Controls.TWinControl.WndProc (Line 7242, "Controls.pas" + 101) + $6 + $C[52038674]{vcl100.bpl } Controls.Controls.TControl.Perform (Line 5018, "Controls.pas" + 5) + $C

// Note: SafeMM will make this reproduce consistently. 1. New VCL Form32 App 2. Put a FlowPanel on the form, resize it so it is big enough to hold 2 LabeledEdits. 3. Add two TLabeledEdit components to the panel; no need to set any properties 4. Select the FlowPanel, wait until the designer hint is shown 5. Press Del to delete the FlowPanel If the AV doesn't occur, press Ctrl+Z to undo the delete and repeat from step 4. I've personally never seen it AV on the first delete, but always on subsequent deletes. After the AV occured, you have to kill bds.exe, since the IDE can't close the form and therefore the project properly. If, after the AV, I put another component on the form (say a TButton), the Structure View gets updated and I can see that the FlowPanel and the LabeledEdits are still there, although not shown in the designer. The interesting thing is, that LabeledEdit2 is now parented by the form and not the FlowPanel!

QC #: 22979 - Status: Closed

QC #: Project Date Reported: Area:22979 C++Builder 1/1/2006 Documentation\IDE Help Contexts

Description Steps:[QC Short Description] No online help for TLIB included in BDS2006 [QC Description] There's no online help for TLIB included in BDS2006 I would expect the following:-

a: File/New/Other... b: Select C++ Builder, Static Library. c: Select Project/Options d: Pick any of the "Librarian (tlib)" pages, and use the HELP button. e: You'll get the familiar "Topic Not Found" page.

a: A topic describing the overall purpose, operation, parameters and options of the TLIB command line tool b: Online help -via F1 from the TLIB 'options' pages of the project options. Currently these all return "topic not found". QC Entry 22979

QC #: 22980 - Status: Closed

QC #: Project Date Reported: Area: 22980 C++Builder 1/1/2006 Documentation

Description Steps:[QC Short Description] No online help for TLIBIMP included in BDS2006 [QC Description] There's no online help for TLIBIMP included in BDS2006. QC Entry 22980 [note] ms-help://borland.bds4/bds4win32devguide/html/cacimportingtypelibraryinformation.htmImport type library information

QC #: 23373 - Status: Closed

QC #: Project Date Reported: Area:23373 C++Builder 1/11/2006 IDE\Code Editor\Code Folding

Description Steps:[QC Short Description] Editing/Entering code causes unfolding [QC Description] In a .cpp file, If I try to enter a new function wile the code is folded, typing the opening { for the new function causes all code following that point to unfold. I realize that the code is ill-formed at the moment I type the opening brace for a new function, but the editor sould let me perform normal functions without getting in my way. I see no reason to ever reevaluate folding dynamicly - anything that's folded or unfolded should stay that way until I invoke folding or unfolding again with a hotkey or menu choice. ADDED AFTER REPORT WAS CLOSED: This report was closed, I suspect due to the steps not being followed closely enough. Step 5 says to type an opening brace, not to type the brace followed by <Enter>. Just to be sure I have attached a simple demo project. I assume that the file will be folded if someone else opens it - if not, Fold Methods. When I add an opening brace { at the start of line 18 of FoldMain.cpp the three buttonClick methods unfold. Automatic block completion will stop this from happening if the { is followed immediately by the Enter key. QC Entry 23373

Updated Steps: - Create a new .c or .cpp file in the IDE - Enter this code // ----- #pragma region #pragma end_region 4| // ----- - Fold the region - Move the cursor to the pipe - type '2' Exp.: '2' is inserted Act.: '2' is inserted and the elided block is un-elided Also: same issue with #if...#endif blocks and #ifdef...#endif blocks. -- Original Steps: -- Open the attached project open FoldMain.cpp right click and Fold Methods type an opening { on line 18 //not all the methods following will unfold -------- File | New | VCL Forms Application - C++ Builder Add several functions to the .cpp file Right-click in editor and Fold | Methods

Add a new method near the top of the file (with several folded methods following it) Type the opening { for the new method (***and don't type anything else***) Code following the { will unfold

QC #: 23482 - Status: Closed

QC #: Project Date Reported: Area: 23482 Delphi 7/24/2009 2:20:41 PM Install\Files Description Steps:1. Name of file: midas source files (list is attached) 2. Source tree location: $(tp)\source\db\midas 3. Delivery location: $(bds)\source\win32\midas 4. What sku does the file(s) belong in? PRO and above 5. What personality does the file(s) belong in? Delphi/C++ 6. What feature does the file(s) belong in? Whatever contains TClientDataset (dclmcn140.bpl). 7. Additional Info? Assuming you can use wildcards for the delivery, use everything in the source directory. If not, the list of files is attached. make.proj changes to copy source files are in rev. 23482

QC #: 23482 - Status: Closed

QC #: Project Date Reported: Area: 23482 C++Builder 1/13/2006 ActiveX\Code Generators\C++

Description Steps:[QC Short Description] Imported ActiveX into new package but package won't install (linker errors) [QC Description] When trying to install a package with the imported flash activex control the linker generates 8 errors: [Linker Error] Error: Unresolved external '__stdcall Shockwaveflashobjects_tlb::IDispatchEx::GetDispID(wchar_t *, unsigned long, long *)' referenced from D:\RICHARD'S DOCUMENTS\BORLAND STUDIO PROJECTS\DEBUG_BUILD\SHOCKWAVEFLASHOBJECTS_OCX.OBJ:: QC Entry 23482 [D2006 : RTM : true] [D2006 : update1 : true ] [10.0.2210.36300 : true ] [11.0.2672.6372 : true ]

1. tregsvr attached .tlb 2. File | New C++ Package 3. Component | Import Component 4. Select Type Library 5. Find and select this type library in the list: "Shockwave flash", click Next 6. Check the Generate Component Wrapper check box, click Next 7. Add unit to package, click Finsih 8. Ctrl + F9 //res: [Linker Error] Error: Unresolved external '__stdcall Stuffflash_tlb::IDispatchEx::GetDispID(wchar_t *, unsigned long, long *)' referenced from ..\DEBUG_BUILD\STUFFFLASH_OCX.OBJ -- Previous steps -- 1. Open up attached project in Package1.zip 2. Build 3. Get Error that the linker can't find GetDispID

Note: if you comment out __declspec (package) then it works. -- Old steps -- 1) Launch Borland C++Builder 2006 2) Select 'File->New->Package - C++Builder' 3) Select 'Component->Import Component' 4) Select 'Import ActiveX Control' radio button 5) Choose 'Shockwave Flash' from the list 6) Click 'Next' 7) Accept default options: Class Name(s): = TShockwaveFlash Palette Page: = ActiveX Unit Dir Name: = c:\program files\borland\bds\4.0\Imports\ Search Path: = $(BDS)\Include\Indy9;$(BDS)\Lib\Indy9;c:\windows\system32'Generate Component Wrappers' is checked and click 'Next' 8) Select 'Add unit to Package1.bdsproj project' 9) Click 'Finish' 10) In 'Project Manager' right-click on 'Package1.bpl' and select Install

QC #: 23580 - Status: Closed

QC #: Project Date Reported: Area: 23580 Delphi 1/15/2006 IDE\Object Inspector Description Steps:[QC Short Description] Object Inspector shows incomplete / mangled event handler list [QC Description] On inherited Forms with overriden event handlers, Object inspector shows incomplete list of event handlers in dropdown which also contains duplicates. See steps and attached test case. Say you have TForm3 inherited from TForm2 inheriting from TForm1. Then, if TForm1 declares an Button1Click, TForm2 does not override it, but TForm3 overrides it, Button1Click will show up twice while you design TForm3. All events you created new in TForm3 which didn't exist in anchestors won't show up in Object Inspectors drop down list. QC Entry 23580 Added by Sysop <<<<<<<<<<<<<<<<<<<<<<<<<<< From a comment of QC --------------- Version: Delphi 2010 Update 4/5 Still this problem persists... --------------- >>>>>>>>>>>>>>>>>>>>>>>>>>>

1. Open attached project (project1.*, unit1.*, unit2.*, unit3.*) 2. Open Form3, select any button, open Inspector, open OnClick event list Problem - a) Button1Click shown twice !!!! b) Button3Click exists in a form, but can`t be shown in list event list But in runtime all works fine, strangely enough ;))

QC #: 23836 - Status: Closed

QC #: Project Date Reported: Area: 23836 C++Builder 1/24/2006 IDE\Structure Pane Description Steps:ClassExplorer from older BCB versions has been removed. A new class explorer is a feature described in Caliber which has not yet been implemented.

***HIGHEST VOTED C++ REQUEST IN QC***

QC #: 23954 - Status: Closed

QC #: Project Date Reported: Area: 23954 Delphi 1/22/2006 RTL Description Steps:[QC Short Description] TWideStrings.Text doesn't take LineBreak into account [QC Description] Doing s := someWideStrings.Text is supposed to collate the strings using the LineBreak property. Instead, sLineBreak is used and the strings are always collated with #13#10. QC Entry 23954

The problem is in both TWideStrings.GetTextStr AND TWideStrings.SetTextStr.

QC #: 23959 - Status: Closed

QC #: Project Date Reported: Area: 23959 C++Builder 1/22/2006 IDE\Structure Pane Description Steps:[QC Short Description] Double click on method goes to declaration and not to implementation [QC Description] In the structure pane using the object in structure tree you go to declaration of function and not to the implementation. To go to the implementation yon need to look in the "fuction" folder which has a lot of entry. In BCB5 class explorer was more functional. QC Entry 23959

1) open a a C++ project 2) open a class (myclass for example) 3) click on a method (mymethod for example) The editor will show only include and for look for implementation you need search the method in the "Function" folder

QC #: 24305 - Status: Closed

QC #: Project Date Reported: Area:24305 C++Builder 1/30/2006 IDE\Code Editor\Syntax Highlighting

Description Steps:[QC Short Description] Syntax highlighter does not recognise long long literals [QC Description] type the following code into the code editor: long long x = 42ll; This valid code compiles fine, but shows as invalid code in the syntax highlighter. QC Entry 24305

type the following code into the code editor, with syntax highlighting enabled. long long x = 42ll; Syntax highlighting is found under Tools->Options->Editor Options->Source Options->Syntax Highlighting Go to Tools->Options->Editor Options->Color Select Number under Element: Note the color chosen. erase the final l and note the color change.

QC #: 24959 - Status: Closed

QC #: Project Date Reported: Area:

24959 C++Builder 2/15/2006 Documentation\IDE Help Contexts

Description Steps:[QC Short Description] C++ examples missing from help files [QC Description] C++ examples that were available in BCB6 are not included in the C++ help for BDS 2006. One missing example is listed in steps, but I basically don't see any. QC Entry 24959

Help | Borland Help Click "Index" tab Type "MessageDlg" into "Look for:" box and hit enter Double-click on "Developer Studio 2006 C++ Builder Reference" There is no example of using MessageDlg although there is an example in BCB6. Please note that this is only an example of a problem that seems to be missing in all help topics for C++, not just this one.

QC #: 25122 - Status: Closed

QC #: Project Date Reported: Area: 25122 Delphi 2/19/2006 IDE\Object Inspector Description Steps:[QC Short Description] Object Inspector event seclection fails on deep frame inheritance [QC Description] It's impossible to select an existing event in Object Inspector when the frame is inherited more than four levels deep. QC Entry 25122

- open the attached sample project - open Frame6 (unit6) in designer - select Frame6 in Object Inspector (should be anyway) - show the events page - double click on the OnEnter event - select the drop down list of the OnEnter event -> list is empty, even if Frame6Enter was just created - repeat the steps for Frame5 -> everything is working as expected

QC #: 25162 - Status: Closed

QC #: Project Date Reported: Area:25162 C++Builder 2/20/2006 IDE\Project Management\Project Manager

Description Steps:[QC Short Description] No option to exclude a file from link [QC Description] Under BC++ it was possible to disable a file from linking to the project (btw: also VC has this option). With this feature one could add several versions of one file and simply enable/disable the linkage properly. QC Entry 25162

Under BC++ it was possible to disable a file from linking to the project (btw: also VC has this option). With this feature one could add several versions of one file and simply enable/disable the linkage properly.

QC #: 25442 - Status: Closed

QC #: Project Date Reported: Area: 25442 Delphi 2/26/2006 VCL Description Steps:[QC Short Description] Assigning TCheckBox.Action triggers Action.OnExecute if Action.Checked [QC Description] Assigning TCheckBox.Action triggers Action.OnExecute if Action.Checked <> TCheckBox.Checked QC Entry 25442 bug exist in D7

1. Run the attached project 2. Click the Assign button, which assigns CheckBox1.Action := Action1 Expected: The checkbox becomes checked and changes its caption Actual: The above, plus Action1.OnExecute being fired, causing a beep. Assigning an action to a checkbox should not trigger the action, just like assigning the action to a button doesn't.

QC #: 26200 - Status: Closed

QC #: Project Date Reported: Area: 26200 C++Builder 3/17/2006 International\Translation Description Steps:[QC Short Description] Using Localised (German) IDE, but building english-localised applications [QC Description] Hello! I'm using the german version of Borland C++ 2006. So when I linked the rtl and vcl complete into my exe-file, I get all exceptions in german language. Is there a existing workaround, to use the german IDE, but linking the english libraries to get the english exception texts? Thank you. QC Entry 26200

Hello! I'm using the german version of Borland C++ 2006. So when I linked the rtl and vcl complete into my exe-file, I get all exceptions in german language. Is there a existing workaround, to use the german IDE, but linking the english libraries to get the english exception texts? Thank you.

QC #: 26801 - Status: Closed

QC #: Project Date Reported: Area: 26801 Delphi 3/30/2006 Compiler\Delphi Description Steps:[QC Short Description] RTTI functionality for private and protected sections in classes [QC Description] Today, it's only possible to get RTTI information through a published section. Any published section is always public. This is also true for any components placed on any design surface (TForm, TDatamodule, TWebModule etc.). Because of the current RTTI all components must be placed inside a public section, violating the object creation rules. If RTTI is upgraded to also have possibilities to save variables etc. inside private and or at least protected section, we may eliminate this problem, and also create new possibilites for persistence. They would need some new sections for this, something like TYourClass = class private published protected published public published // today "published" The old "published" could be marked as deprecated, to preserve pattern, but it's not the most important issue. TypeInfo blocks could be adjusted to have visibility information. After the changes, TReader, TWriter needs to be updated with these new RTTI features. See QC 26833 for the changes to design surface automation behaviour.QC Entry 26801

See description (JJS: This concern may have been address with the introduction of {$METHODINFO ON}

QC #: 27240 - Status: Closed

QC #: Project Date Reported: Area:27240 C++Builder 4/11/2006 Documentation\Online Help Description Steps:[QC Short Description] C++ Builder Development Guide missing [QC Description] In C++ Builder 6, the C++ Builder Development Guide provided important information that is simply not available in the online documentation provided with BDS 2006. A prime example is Chapter 13 of the C++ Developers Guide - "C++ language support for the VCL". The new Borland help information does not include this type of information. (Or if it does, I can't find it). Not understanding such detail can lead to subtle, hard-to-find bugs. In general, I beleive the online help is not a replacement to the "C++ Developers Guide" but rather a complement to it. As a minimum, an updated version of the PDF version of the "C++ Builder Development Guide" should be provided, and in the meantime provide the version 6 version for those not fortunate enough to have upgraded from a prior version. In an ideal world, the "C++ Developers Guide" would be integrated into the online help. QC Entry 27240

The book PDF file is found, but not the source. There's not enough time to reverse-engineer the PDF and update it for Cogswell AND make it into the Help. We may be able to put it on the web. -Dee

QC #: 27556 - Status: Closed

QC #: Project Date Reported: Area:27556 C++Builder 4/20/2006 Compiler\C++\Front End\Language

Description Steps:[QC Short Description] The C++ compiler interprets -2147483648 as an unsigned value [QC Description] The C++ compiler and preprocessor interpret -2147483648 (= INT_MIN) as an unsigned value. QC Entry 27556 (NOTE: This is a higher priority issue now because the SyncObjs.hpp unit in VCL contains the following declaration... static const int SignalMask = -2147483648; static const int EventSignaled = -2147483648; ... that highlight the compiler's error).

bcc32 -I"\Program Files\Borland\BDS\5.0\include" -c 239927.cpp //exp : no W8041 //res : Warning W8041 239927.cpp 4: Negating unsigned value in function main() Warning W8041 239927.cpp 5: Negating unsigned value in function main() Warning W8041 239927.cpp 6: Negating unsigned value in function main() [Problem seems to be in convertnum(..) in scan.c: switch (oldType) { case T_INT: if (radix == DECIMAL_CON) { if ((unsigned long)Token.i.icon > (unsigned long)TypeRange[T_LONG - 1].ty_max) { Token.i.itype = T_ULONG; } When Token.i.icon = -2147483648, we remap Token.i.type to T_ULONG - which then results in the warning of negating an unsigned number. We should allow -2147483648 with no problem but warn about

truncation for -2147483649.]

QC #: 28624 - Status: Closed

QC #: Project Date Reported: Area: 28624 Delphi 4/30/2006 Demos\Other Description Steps:[QC Short Description] docking demo is broken, was ok in delphi7 [QC Description] the docking demo behaves strangely sometimes, is broken other times, compared to delphi7 version of the docking demo. tab-sheet host: using the delphi7 demo, create a floating host with some tabs. drag a new client over the tabsheets, and you get only one dock-rect allowed -drop the new client and it's added as a new page. good. now try with the d2006 demo. when you drag the new client over, you get additional possibilities for dock-rects: top, bottom, left, right, centre. all of those do weird stuff. the new client is not added in a logical way to the others. instead, the new client and one of the old ones gets combined, and kicked out as a floating pair. conjoin host: using delphi7 demo, create the following arrangement of tiles in a floating host: wide rectangle on top, tall rectangles underneath on the left and on the right: AA BC BC now dock a new client into the bottom half of rectangle C, to make this arrangement: AA BC BD works fine. now try with the D2006 demo. when dropping D onto C, the host ejects C, and we're left with two floating hosts, one containing A and B, the other containing C and D. i am very nervous about tapping into the docking provisions of the VCL on account of these differences. if i add docking to my app, will i need to rewrite it with each new update of the VCL? QC Entry 28624

1. open ($BDS)\Demos\DelphiWin32\VCLWin32\Docking\dockex.dpr 2. click the "White" toolbutton. 3. move the "White" window to a convenient location 4. click the "Blue" toolbutton. 5. dock the"Blue" window into the Right-hand Half of the white window. 6. click the "Green" toolbutton 7. dock the "Green" window into the Right-hand Half of the docked blue window. 8. click the "Lime" toolbutton 9. dock the "Lime" window into the Right-hand Half of the docked blue window. Exp: All four windows will be docked together Act: The green and lime windows jump out of the other docked group (See image attachments 1_xxxx 2_xxxx 3_xxxx) Note that if the lime window is into either the white or the blue window results are as expected. Close app and retry with tabbed docking: 1. click the "White" toolbutton. 2. move the "White" window to a convenient location 3. click the "Blue" toolbutton. 4. dock the"Blue" window into the center of the white window to tab-dock. 5. click the "Green" toolbutton 6. dock the "Green" window into the center of the tab-docked blue window to add as a tab. Exp: The green window will be added as a third tab to the group Act: The blue and green windows jump out of the white window and form their own tabbed duo. (See image attachments A_xxxx - D_xxxx) Tested in RAD Studio 2007 with identical results (using the demo from BDS2006, since I don't see it in the RAD Studio distribution)

QC #: 28823 - Status: Closed

QC #: Project Date Reported: Area: 28823 Delphi 5/6/2006 RTL\Delphi\ConvUtils Description Steps:[QC Short Description] Non inlining of AnsiSameText function [QC Description] The function DescriptionToConvFamily in ConvUtils.PAS uses the

Add {$IFDEF MSWINDOWS} Windows, {$ENDIF} to the uses clause

inline function AnsiSameText. Because Windows is not specified in the uses clause, this will never be inlined QC Entry 28823

QC #: 28824 - Status: Closed

QC #: Project Date Reported: Area: 28824 Delphi 5/6/2006 RTL\Delphi\Other RTL Description Steps:[QC Short Description] Non inlining of AnsiSameText function in VarCmplx.pas [QC Description] The functions TComplexData.SetAsString and TComplexData.Equals in VarCmplx.PAS use the inline function AnsiSameText. Because Windows is not specified in the uses clause, this will never be inlined QC Entry 28824

Add {$IFDEF MSWINDOWS} Windows, {$ENDIF} to the uses clause

QC #: 29086 - Status: Closed

QC #: Project Date Reported: Area: 29086 C++Builder 5/14/2006 CodeGuard Description Steps:[QC Short Description] Problem with ostringstream and CodeGuard [QC Description] The attached program does not work with CodeGuard fully enabled (-vG) . CodeGuard reports an error in file sstream, line 125: _Seekhigh = _Seekhigh - _Mysb::eback() + _Ptr; The error message looks like: 14.05.2006 16:52:29 hat einen CodeGuard(tm)-Prozess gestartet: Project2.exe(2532) Zeiger in freigegebenem Speicher im Prozess: Project2.exe(2532) - c:\programme\borland\bds\4.0\include\dinkumware\sstream#125 0x00CE4494-0x00CE4494. 0x0040603C - c:\programme\borland\bds\4.0\include\dinkumware\sstream#125 0x00405AEF - c:\programme\borland\bds\4.0\include\dinkumware\streambuf#465 0x00402499 - c:\programme\borland\bds\4.0\include\dinkumware\streambuf#151 0x004016C8 - c:\programme\borland\bds\4.0\include\dinkumware\ostream#679 0x00401210 - C:\Dokumente und Einstellungen\Michael\Eigene Dateien\Borland Studio-Projekte\Unit2.cpp#9 0x3276CDC2 Objekt (0x00CE4494) [Gr e: 32 Byte] war erstellt mit new 0x00403E7C - c:\programme\borland\bds\4.0\include\dinkumware\xmemory#28 0x0040358C - c:\programme\borland\bds\4.0\include\dinkumware\xmemory#143 0x00405F23 - c:\programme\borland\bds\4.0\include\dinkumware\sstream#105 0x00405AEF - c:\programme\borland\bds\4.0\include\dinkumware\streambuf#465 0x00402499 - c:\programme\borland\bds\4.0\include\dinkumware\streambuf#151 0x004016C8 -

bcc32 -vG qc29086.cpp qc29086.exe notepad qc29086.cgl (verify no errors)

c:\programme\borland\bds\4.0\include\dinkumware\ostream#679 Objekt (0x00CE4494) war Gel scht mit delete 0x004039A2 - c:\programme\borland\bds\4.0\include\dinkumware\xmemory#138 0x00405F7C - c:\programme\borland\bds\4.0\include\dinkumware\sstream#111 0x00405AEF - c:\programme\borland\bds\4.0\include\dinkumware\streambuf#465 0x00402499 - c:\programme\borland\bds\4.0\include\dinkumware\streambuf#151 0x004016C8 - c:\programme\borland\bds\4.0\include\dinkumware\ostream#679 0x00401210 - C:\Dokumente und Einstellungen\Michael\Eigene Dateien\Borland Studio-Projekte\Unit2.cpp#9 QC Entry 29086

QC #: 29110 - Status: Closed

QC #: Project Date Reported: Area: 29110 C++Builder 5/15/2006 Compiler\C++ Description Steps:64-bit constants causing W8056 : Integer Arithmetic Overflow treated differently between IDE and command line. QC Entry 29110

Download RD240083.cbproj and RAID240083.cpp open RD240083.cbproj in IDE CTRL-F9 to build project go to command line and run RD240083.exe that was just generated. There should be no output. touch RAID240083.cpp msbuild RD240083.cbproj run newly built RD240083.exe exp: no output as above act: Fail

QC #: 29989 - Status: Closed

QC #: Project Date Reported: Area: 29989 Delphi 6/9/2006 RTL\Delphi Description Steps:[QC Short Description] TFilestream.Create cannot create shareable files. [QC Description] You cannot use the "fmCreate" mode with any of the "fmSharexxx" options. If you use fmCreate, the file is always opened for exclusive access. TFileStream.Create should allow the creation of shareable files. Currently, the workaround is to 'create' the file, close it, and then re-open it shareable. In sysutils.hpp: static const Shortint fmShareExclusive = 0x10; static const Shortint fmShareDenyWrite = 0x20; static const Shortint fmShareDenyRead = 0x30; static const Shortint fmShareDenyNone = 0x40; But, in classes.hpp, static const Word fmCreate = 0xffff; so - for example - (fmCreate | fmShareDenyWrite) == fmCreate QC Entry 29989

1. bcc32 -tCV 241068.cpp 2. 241068.exe (leave running until after step 2) 3. Try and open foo.txt (which should be in the same directory as your .exe) //exp : you can open it //res : access denied despite the flags you set when creating the file

QC #: 30231 - Status: Closed

QC #: Project Date Reported: Area: 30231 Delphi 6/17/2006 RTL\Delphi\Math Unit Description Steps:(JJS: Fix made to rev. 25227) [QC Short Description] ArcCscH returns incorrect result [QC Description] ArcCscH returns an incorrect result. This seems to be caused by incorrect placement of parentheses. The correct method of calculating the inverse cosecans hyperbolicus is described here: http://mathworld.wolfram.com/InverseHyperbolicCosecant.html Delphi uses this calculation: function ArcCscH(const X: Extended): Extended; begin Result := Ln(Sqrt(1 + (1 / (X * X)) + (1 / X))); end; The correct calculation according to MathWorld would be: function ArcCscH(const X: Extended): Extended; begin Result := Ln(Sqrt(1 + (1 / (X * X))) + (1 / X)); end; QC Entry 30231

Display the result for ArcCscH(0.5) from a Delphi app: ShowMessage(FloatToStr(ArcCscH(0.5))); This displays the result as being 0,972955074527657. Calculate the ArcCscH in any other way (such as the Windows calculator, using the identity ArcCscH(x) = ArcSinH(1/x)) to find that ArcCscH(0,5) = 1,4436354751788103424932767402731. program BTS240611; {$APPTYPE CONSOLE} uses Math; const ExpectedValue = 1.4436354751788103424932767402731; var RetVal: Real; begin RetVal := ArcCscH(0.5); if abs(RetVal - ExpectedValue) > 0.00001 then WriteLn('FAIL - Expected Value not found') else WriteLn('PASS'); end.

QC #: 30648 - Status: Closed

QC #: Project Date Reported: Area: 30648 Delphi 6/27/2006 Midas\TClientDataSet Description Steps:[QC Short Description] Operation not applicable when deleting records. [QC Description] When having a combination of deletes and EmptyDataSet with LogChanges set to false, you get an "Operation not applicable" exception when deleting a record. The exception does not occur if LogChanges is true or less deletes are made. Furthermore, this same record that cannot be delete is not saved by .SaveToFile, and disappears when the active index is changed QC Entry 30648

TDBXFulcrumBugsSuite.Native.DB.Test.exe connection=ibconnection -s:TestRaid_240544 -OR- 1. Create a new VCL W32 application. 2. Add a ClientDataSet and the following code on an event handler: procedure TForm1.Button1Click(Sender: TObject); begin with ClientDataSet1 do begin Close; FieldDefs.Clear; FieldDefs.Add('Codigo', ftInteger); CreateDataSet; LogChanges := False; Insert; FieldByName('Codigo').AsInteger := 1; Post;

Insert; FieldByName('Codigo').AsInteger := 2; Post; Delete; EmptyDataSet; Insert; FieldByName('Codigo').AsInteger := 3; Post; Insert; FieldByName('Codigo').AsInteger := 4; Post; Delete; Delete; end; end; 3. Run it and see the exception getting raised.

QC #: 30722 - Status: Closed

QC #: Project Date Reported: Area: 30722 Delphi 6/28/2006 IDE\Search\Find in Files Description Steps:[QC Short Description] Find in Files Regular Expression fails when using "BRIEF Regular Expressions" [QC Description] A regular expression that works for "Find" fails with "Find in Files", even though the value was located in "Find" and the file is part of the project/part of the project group/in an open file. QC Entry 30722

Open a pas file in a project and place the line: "AddSections(SOME_VALUE, False);" in the file and <ctrl>+<home>. Go to Tools | Options | Editor Options and turn BRIEF regular expressions on. OK the dialog then <ctrl>+f check the "Regular Expressions" checkbox and search for the string "AddSections\(*, False". Click OK and the expression will be found in the current file. Now try <ctrl>+f click on the "Find in Files" tab and search for the same string, ensure that "Regular Expressions" is still checked and "Search all files in project" is checked then click OK. After apparently scanning all files in the project the search comes up without results!

QC #: 30802 - Status: Closed

QC #: Project Date Reported: Area:30802 C++Builder 6/30/2006 Compiler\C++\Front End\Exception Handling

Description Steps:[QC Short Description] Program hang with try-catch block inside __finally block [QC Description] This is the second report derived from the original QC report 2666. (which contained multiple bugs) Function Finally2 contains the example with try-catch block inside __finally block. The second exception is successfully handled in nested try-catch block and then program hangs up (return address from __finally block is apparently lost). QC Entry 30802

1. bcc32 241390.cpp 2. 241390.exe //exp : output: TRY CATCH INT FINALLY FIN_CATCH_CHAR OUT //res : output and AV TRY FINALLY FIN_CATCH CHAR * * * CRASHED * * *

----------------------------------------------------------------- Note that the above is wrong, since the finally must execute first. The correct expected is: TRY FINALLY CATCH CHAR OUT or (variant 241390a) TRY FINALLY FIN_CATCH CHARs OUT

QC #: 30921 - Status: Closed

QC #: Project Date Reported: Area:30921 C++Builder 7/4/2006 Compiler\C++\Front End\Diagnostics

Description Steps:[QC Short Description] Warn 8026 appears without reason [QC Description] Warn 8026 "Funcions with exception specifications are not expanded inline" appears in constructors without function specification QC Entry 30921

1) Download the attached file 2) from the command line type bcc32 qc30921.cpp note the warning: Warning W8026 qc30921.cpp 10: Functions with exception specifications are not ex panded inline

QC #: 31390 - Status: Closed

QC #: Project Date Reported: Area: 31390 Delphi 7/18/2006 IDE\Form Designer Description Steps:[QC Short Description] Ide Crash when delete TGridPanel [QC Description] The Ide crash when delete TGridPanel. Into TGridPanel there are Tlabelededit and TColorBox Component QC Entry 31390 See also 240175 stack: + $2D[00363264]{rtl110.bpl } Classes.Classes.TCollectionItem.GetNamePath (Line 3926, "common\Classes.pas" + 5) + $2D + $0[00336B47]{rtl110.bpl } System.System.@HandleAnyException (Line 9980, "sys\system.pas" + 13) + $0 + $41[7C903786]{ntdll.dll } RtlConvertUlongToLargeInteger + $41 + $9[7C90EAF5]{ntdll.dll } KiUserExceptionDispatcher + $9 + $E[00468A2B]{vcl110.bpl } Controls.Controls.TControl.WndProc (Line 5141, "Controls.pas" + 81) + $E + $10[0046CA09]{vcl110.bpl } Controls.Controls.TWinControl.WndProc (Line 7241, "Controls.pas" + 100) + $10 + $4[004686B8]{vcl110.bpl } Controls.Controls.TControl.Perform (Line 5018, "Controls.pas" + 5) + $4

1) Insert TGridPanel into FormDesigner 2) Insert TLabeledEdit into TgridPanel on first square 3) Insert TColorBox into TGridPanel on third square Note: The second square is also used by the TLabeledEdit because it is treated as 2 controls. 4) Delete TGridPanel

QC #: 31575 - Status: Closed

QC #: Project Date Reported: Area: 31575 C++Builder 7/21/2006 RTL\C++\Header Files Description Steps:[QC Short Description] Invalid comments in wsnwlink.h cause compiler errors [QC Description] wsnwlink.h contains: typedef struct _IPX_NETNUM_DATA { UCHAR netnum[4]; /* input: IPX network number */ USHORT hopcount; /* output: hop count to this network, in machine order */ USHORT netdelay; /* output: tick count to this network, in machine order */ INT cardnum; /* output: 0-based adapter number used to route to this net; /* can be used as adapternum input to IPX_ADDRESS */ UCHAR router[6]; /* output: MAC address of the next hop router, zeroed if /* the network is directly attached */ } IPX_NETNUM_DATA, *PIPX_NETNUM_DATA; Note the lack of a closing '*/' at the end of both the "INT cardnum" and "UCHAR router[6]" lines, which causes the compiler to fail with: "Unexpected end of file in comment started on line nnn" "Unexpected end of file in conditional started on line nnn" This problem exists in BCB5, BCB6, and BDS 2006. QC Entry 31575

QC #: 31614 - Status: Closed

QC #: Project Date Reported: Area:31614 Delphi 7/23/2006 Documentation\Online Help\Object Pascal

Description Steps:[QC Short Description] Delphi Language Guide typos [QC Description] The Delphi Language Guide has some typos and things that could be clarified. See Steps. QC Entry 31614

The page ms-help://borland.bds4/bds4ref/html/NestedTypes.htm says, "Nested type declarations are terminated by the first occurance of a non-identifier token, for example, procedure, class, type, and all visibility scope specifiers." The word "occurance" should be "occurrence". The page ms-help://borland.bds4/bds4ref/html/StructuredTypes.htm says var Int1: array[1..10] of Integer; array[1..10] of Integer; ... Int1 := Int2; The second declaration should be Int2: array[1..10] of Integer; The page ms-help://borland.bds4/bds4ref/html/StructuredTypes.htm in the "Records (advanced)" section discusses constructors for records. However, it is not clear how to use these since records are not normally constructed. More explanation and an example would be good. The page ms-help://borland.bds4/bds4ref/html/DeclarationsAndStatements.htm in the "Iteration Over Containers Using For statements" section gives an example that has the statement "IDynArray := IArray1;". This won't compile. The compiler says, "Error: E2010 Incompatible types: 'TGenericIntArray' and 'Array'". The page ms-help://borland.bds4/bds4ref/html/DeclarationsAndStatements.htm#ForStmts has an example containing the lines TMyIntArray = array of Integer; ... Values := TMyIntArray.Create(100, 200, 300); However, the TMyIntArray.Create syntax doesn't seem to be documented. The page ms-help://borland.bds4/bds4ref/html/CallingProceduresAndFunctions.htm says, "No inlining will be done between units that are circularly dependent. This included indirect circular dependencies". The word "included" should be "includes".

QC #: 31670 - Status: Closed

QC #: Project Date Reported: Area:31670 Delphi 7/24/2006 IDE\Code Editor\Error Insight Description Steps:[QC Short Description] Error Insight flags record helper declarations that compile fine [QC Description] Error Insight flags the for and public as red/underlined in this record helper declaration: TRectHelper = record helper for TRect public function Width: Integer; function Height: Integer; end; QC Entry 31670

Test this console application that compiles: program Project14; {$APPTYPE CONSOLE} uses SysUtils, Windows; type TRectHelper = record helper for TRect public function Width: Integer; function Height: Integer; end; function TRectHelper.Height: Integer; begin Result := 0; end; function TRectHelper.Width: Integer; begin Result := 0; end; begin end. See Error Insight Errors: On for: Expected : but received FOR at line X On public: Expected : but received an identifier at line X

QC #: 31857 - Status: Closed

QC #: Project Date Reported: Area: 31857 C++Builder 7/28/2006 IDE\Code Completion Description Steps:[QC Short Description] Cursor should be placed after the closing paren for methods with no parameters [QC Description] CI, after member invokation displays 'no parameters expected' for a member function with no arguments. But it places the cursor between the parens. This means I have to move it manually before I can place the ';'. It would be very nice if the cursor was placed after the closing paren. QC Entry 31857

QC #: 32115 - Status: Closed

QC #: Project Date Reported: Area:32115 Delphi 8/4/2006 IDE\Project Management\Project Manager

Description Steps:[QC Short Description] Please add capability to drag & drop from an editor tab to the project manager [QC Description] If an external file is opened in the editor, I would like to be able to add the file to the project by draging and dropping from the editor tab to the project manager. QC Entry 32115

Try to drag an editor file to the project manager Project manager shows insertion point as if ready to accept file, but the mouse cursor remains the don't symbol

QC #: 32142 - Status: Closed

QC #: Project Date Reported: Area: 32142 Delphi 8/5/2006 IDE\Code Browsing

Description Steps:[QC Short Description] Find Unit throws "Object reference not set to an instance of an object" [QC Description] 'Find declaration (ctrl-click)' of an Interface gives the error: Object reference not set to an instance of an object There are more bugs on this subject, but they are for Delphi.net or closed with resolution 'can't reproduce'. Below a very simple steps to reproduce. QC Entry 32142

Open attached project.; procedure TForm1.DoThings; var LInterface1: Interface1; begin ... 'Find declaration' of Interface1 fails. Interface1: Interface1 = interface(IDispatch) ... end; Declared in the apps tlb, Project1_TLB.pas.

QC #: 32152 - Status: Closed

QC #: Project Date Reported: Area: 32152 Delphi 8/5/2006 VCL\Graphics Description Steps:[QC Short Description] Please provide an ArcTo function in TCanvas class [QC Description] Please provide an ArcTo function in TCanvas class. ArcTo is similar to the Arc function, except that the current position is updated. Please have a look at the GDI Reference from Microsoft: http://msdn.microsoft.com/library/default.asp?url=/library/en-us/gdi/linecurv_8f3j.asp QC Entry 32152

n/a

QC #: 32440 - Status: Closed

QC #: Project Date Reported: Area:32440 Delphi 8/8/2006 IDE\Code Editor\Keymapping Description Steps:[QC Short Description] Using alt + numpad to enter international characters does not work with Num Lock off [QC Description] If you hold down the ALT key and type the ASCII code for a character on the numeric keypad while Num Lock is off, then it doesn't work as expected. Steps: 1) Make sure Num Lock is off 2) Click somewhere inside the code editor to give it the keyboard focus3) Hold down the ALT key 4) Type '130' on the numeric keypad. Expected: The character 'e' with an accent on top (or some other international character depending on your locale) Actual: The IDE opens up the history view It works as expected in Notepad, Wordpad, etc. Most applications I have seen does not require Num Lock to be on to be able to use

1) Make sure Num Lock is off 2) Click somewhere inside the code editor to give it the keyboard focus 3) Hold down the ALT key 4) Type '130' on the numeric keypad. Expected: The character 'e' with an accent on top (or some other international character depending on your locale) Actual: The IDE opens up the history view

ALT+XXX (where XXX is a character number typed on the numpad) to enter international characters. QC Entry 32440

QC #: 32477 - Status: Closed

QC #: Project Date Reported: Area: 32477 Delphi 8/8/2006 IDE\File Handling Description Steps:F. Piette updated for Highlander: build 2459 still has that behaviour. Important info from Francois Piette as his QC report has been marked a duplicate of a closed report: Please read MY QC report. It has full steps to reproduce the problem. I have checked it again today with highlander and the problem is still perfectly reproductible with MY steps. Marking my QC report as duplicate without even reading it correctly is not fair. [See also 238423 as it might be related] [QC Short Description] Secondary edit window do not reopen after restart [QC Description] When using undocked window IDE, and having two edit windows with different opened files in each window, after closing and reopening the IDE, only the main edit window is reopened with his files. The files which where opened in the secondary window are not visible nor in the list of recent files (reopen menu). When you do a File/Open and browse to one of the files which where opened in the secondary window, this file is shown again in the secondary window along with all previously opened files in the secondary windows. QC Entry 32477

1) Launch the IDE 2) Select undocked layout 3) Open 3 source files in the code editor 4) Menu view/New Edit Window 5) Open 3 more files in that secondary window 6) Close the file in the secondary which is also opened in the primary edit window 7) Shutdown the IDE 8) Launch the IDE again 9) Note that the primary window is opened with all the files which where opened there. 10) Note the secondary window is not reopened (a bug in my opinion) 11) Menu File /open one of the file you opened in the secondary window at step 3 above 12) Note that the secondary edit window reopen not only with the file you selected but also with the 2 others you opened at step 3.

QC #: 32677 - Status: Closed

QC #: Project Date Reported: Area: 32677 Delphi 8/14/2006 IDE\Code Editor Description Steps:[QC Short Description] With "persistent blocks" hitting [space] will deselct code [QC Description] When you have the option "persistent blocks" set, the selected text will be deselected when hitting [space] key. QC Entry 32677

1. Start BDS (2006/Highlander) 2. Open any project / new project 3. Menu: Tools -> Options... -> Editor Options 4. Mark the check box "Persistent blocks" (3rd on the right column) 5. press okay 6. go into the code editor 7. press [Shift] and [Cursor keys] to select some text (one or more lines does not matter) 8. create a new line (or go to the *end* of another line of code) 9. write hello world in to the line. ACT: after hitting space on "hello" the selection disappears EXP: selection should stay

QC #: 32851 - Status: Closed

QC #: Project Date Reported: Area:32851 Delphi 8/18/2006 IDE\Packages\Installing Components

Description Steps:[QC Short Description] IDE deadlock on remove package [QC Description] Removing a package can cause entire IDE to become unresponsive - need to kill with Task Manager This is with Patch2 and HotFixes 1-6 applied Tested in winxp sp2 / dual monitors tried on 2 machines with all other apps closed - happens every time I try this. QC Entry 32851 [ This happens with Delphi only personality as well. It's NOT a C++ bug, it's a floating designer / package install bug - MD ] [Any time the designer is floating and you uninstall a package via the project options dialog (Delphi Win32 or C++, probably .NET too), the *modal* project options dialog gets hidden as well as any design windows. - MD]

Disabled the embedded form designer in the VCL Form Designer options. (restart as needed). Open a VCL forms app or create a new one. Click on the designer form to activate. Project | Options | Packages Click on the checkbox for the ActionBar components package. At this point you'll get a list index error and the IDE is no longer responding to input. [Original steps] Set to floating designer Restart IDE if necessary to activate floating designer File | New | VCL Forms app Resize form without clicking on editor (or anything else) Project | Options | Packages Click on "Borland ActionBar Components" - not on the checkbox - leave that checked Click "Remove" Click "Yes" Options dialog disappears - IDE is deadlocked <sysop> you can switch back and forth between applications, but you cannot interact with IDE in any other way </sysop> Kill IDE with Task Manager

QC #: 32903 - Status: Closed

QC #: Project Date Reported: Area: 32903 Delphi 8/20/2006 VCL\Graphics Description Steps:[QC Short Description] Please provide an AngleArc function in TCanvas class [QC Description] Please provide an AngleArc function in TCanvas class. Please have a look at the GDI Reference from Microsoft: http://msdn.microsoft.com/library/default.asp?url=/library/en-us/gdi/linecurv_6ijn.asp BOOL AngleArc( HDC hdc, // handle to device context int X, // x-coordinate of circle's center int Y, // y-coordinate of circle's center DWORD dwRadius, // circle's radius FLOAT eStartAngle, // arc's start angle FLOAT eSweepAngle // arc's sweep angle ); QC Entry 32903

QC #: 33107 - Status: Closed

QC #: Project Date Reported: Area:33107 C++Builder 8/24/2006 Compiler\C++\Front End\access

Description Steps:[QC Short Description] Private nested class name in a base class is acccessible in a derived class [QC Description] class A { class R { }; }; class B : A { R r; // R is inaccessible here }; compiles without any warning/error. QC Entry 33107

bcc32 -c 241599.cpp //exp : error that R is not accessable //res : clean compile

QC #: 33223 - Status: Closed

QC #: Project Date Reported: Area: 33223 C++Builder 8/29/2006 IDE\Code Editor Description Steps:[QC Short Description] Code Insight for macros should be implemented in #define directives [QC Description] It is very nice that symbol insight lets me see the expansion of a macro as well as the line on which it is defined. Problem is that most macros (coming from windows headers as they so often do) are actually defined in terms of other macros. But symbol insight is not active for preprocessor directives, so it will not help to locate the macro used to define a macro. (Although it is possible to trace back by typing the second macro into your source file.) I would like to see either: a) Activate symbol insight for #define directives so that macros that they contain can be traced. or b) Include a full trace of nested defines in the original symbol insight popup for the macro and allow navigation to any of the the listed definitions. QC Entry 33223

QC #: 33280 - Status: Closed

QC #: Project Date Reported: Area: 33280 Delphi 8/30/2006 IDE\Dialogs Description Steps:[QC Short Description] Escape and About

Open Ide Select About Borland HighLander... from menu Press Esc ----> closing as exp. Before press esc click on line of version (and build)

[QC Description] The About Box of the help not close itself by Escape in some cases QC Entry 33280

or into Product info-box (they are editors) ----> Esc ineffective

QC #: 33767 - Status: Closed

QC #: Project Date Reported: Area: 33767 Delphi 9/10/2006 VCL\Printing Description Steps:[QC Short Description] incorrect DeviceCapabilities constants [QC Description] some constants for use with WinSpool.DeviceCapabilities are incorrectly defined in windows.pas: DC_COLORDEVICE = 23 (clashes with DC_MANUFACTURER, should be 32) DC_NUP = 24 (clashes with DC_MODEL, should be 33) QC Entry 33767

use WinSpool.DeviceCapabilities to check for color support, or get the N-Up definitions. <sysop> Compare DC_COLORDEVICE in $BDS\Source\Win32\RTL\Win\Windows.pas and $BDS\include\wingdi.h </sysop>

QC #: 33838 - Status: Closed

QC #: Project Date Reported: Area:33838 Delphi 9/12/2006 IDE\Code Editor\Error Insight Description Steps:[QC Short Description] Error insight confused with pasted text containing mixed CR/LF and LF only terminated lines [QC Description] Error insight display false syntax error after pasting text which contain both CR/LF delimited lines and LF only delimited lines. You can find such a text file in attachement and also a screen dump. Note that the behaviour of error insight seems to depends on the code around your insertion point. If error insight doesn't give any error, then undo and paste the text elsewhere in your code. QC Entry 33838

1) Check that the file I provided is 581 bytes in length and is named "SomeTextFile.txt". 2) Open any real project in the IDE 3) Open "SomeTextFile.txt" in the IDE (in another edit window). Do not change it ! 4) Do CTRL-A CTRL-C to copy the text into the clipboard 5) Switch to your source code 6) Put the text cursor somewhere in the middle of a function code, just before an assignment to a local variable (see screen dump). 7) CTRL-V to paste the text (which is only pascal comments). The code around the insertion point doesn't always show errors, so if you don't see the wavey red line, insert elsewhere ! 8) See the IDE shoing syntax error 9) See the structure pane showing error 10) Compile the project and see it compile OK Errror seen : // CRLF // // chunk = chunk-size [ chunk-extension ] CRLF // the second // pair the second / is highlighted with red squiggle the error in the structure pane is "Expected INITIALIZATION but received / at line .."

QC #: 33931 - Status: Closed

QC #: Project Date Reported: Area: 33931 Delphi 9/14/2006 IDE\Code Editor Description Steps:[QC Short Description] Numeric keypad does not work if same number is used as shortcut [QC Description] In code editor, sometimes the keys on the numeric keypad 1 through 5 do not work. Pressing these keys does nothing. The other keys, including 0, 6, 7, 8 and 9 work as expected. See Steps for details. If I switch the numlock off, all keys work fine, i.e. the move the cursor. However, when I switch the numlock key back on, the problem reappears.

Set Tools | Options | Environment | VCL Designer | Embedded designer to checked 1) Close and reopen BDS if needed to enable embedded designer 2) Download and Open the attached project 3) F12 to go to editor if designer is showing 4) Set NumLock on on keyboard 5) Number pad keys 1, 2, and 3 don't work 6) Top row keys 1, 2 and 3 do work [sysop: copied from comments, easy to reproduce] 1) Create a New VCL Form Application (Win32 in this Case) 2) Add a TButton onto the Form 3) Change the Caption of the TButton to "&1"; 4) Switch to Code Editor 5) Try to write a "1" with the numeric keyboard.. nothing happens 6) If you change the Button Caption to &2 then you can not write with the "2" in the numeric keyboard and so

This behavior only occurs in the Code Editor, I have not encountered it in any other part of Delphi IDE, such as Object Inspector. The bug occurs on other computers as well. "Normal" keys (above qwerty) work well all the time. QC Entry 33931

On.

QC #: 34006 - Status: Closed

QC #: Project Date Reported: Area: 34006 Delphi 9/15/2006 VCL\Action Classes Description Steps:[QC Short Description] TSearchFind action doesn't work with more than 64k bytes text [QC Description] If you add a standard action of Search category, the search function returns "Text not found" if it exists beyond the 64k boundary. Function SearchEdit in unit StdActns uses a variable called Size of type word to store the result of EditControl.GetTextLen. Although GetTextLen returns an Integer. The type of the Size variable should be changed to an integer. QC Entry 34006

QC #: 34360 - Status: Closed

QC #: Project Date Reported: Area: 34360 Delphi 9/22/2006 IDE\Dialogs Description Steps:[QC Short Description] Make the Tools | Options dialog sizeable [QC Description] I have noticed that many of the dialogs in BDS are now sizeable (compared to the same dialogs in BCB6). This is a great improvement. However, the Tools | Options dialog is still not sizeable, but it contains many controls that would greatly benefit from allowing the dialog to be sized. QC Entry 34360

QC #: 34447 - Status: Closed

QC #: Project Date Reported: Area:34447 Delphi 9/26/2006 Database\Data Aware Controls\TDBGrid

Description Steps:[QC Short Description] Data loss in TDBGrid [QC Description] there is data loss if - record is edited using DBEdits and simultaneously shown in a DBGrid - user clicks on the empty are of a DBGrid

1. Download and run the attached test-case 2. Activate the second record by clicking on the cell showing "two" 3. Enter a different text (e.g. "test") into the DBEdit above the grid 4. click on the empty area in the grid below the records exp: updated value ("test") should show up in the grid act: value is cleared, i.e. data loss

See steps and attached test-case This is caused since in TCustomDBGrid.MouseDown there is a call to UpdateData instead of FDataLink.UpdateData (see workaround) QC Entry 34447

QC #: 34774 - Status: Closed

QC #: Project Date Reported: Area: 34774 Delphi 10/3/2006 Compiler\Delphi Description Steps:[QC Short Description] Documentation generation does not produce a valid xml file. [QC Description] The delphi win32 compiler can produce xml documentation if enabled under project options. This xml is sometimes invalid for specific pieces of pascal code. QC Entry 34774

create an empty win32 delphi project. enable xml documentation generation under project options. example: program BTS246097; {$APPTYPE CONSOLE} const a = '&'; b = '$'; c = [a, b]; begin end. Which produces an xml file containing: <const name="a" type="Char"> <value> $26 </value> </const> <const name="b" type="Char"> <value> $24 </value> </const> <const name="c" type="Set"> <value> ['&','$'] </value> </const> This is incorrect, the & should have been escaped to & Also: The generated documentation also does not include the 'low' and 'high' of the first dimension of a multidimensional array TAnArray = array[Char, Byte, 0..12] of TEnum; <array name="TAnArray"> <array name="TAnArray" low="0" high="255"> <array name="TAnArray" low="0" high="12"> <element type="TEnum" /> </array> </array>

</array> Also the manual basicly says nothing about what the comments should look like, we assume it should mimic the visualstudio style ? There seems to be a basic design issue with how type reference are handled btw: Usually an type attribute is added to whateer the type refers tp, but for some types, like pointers and arrays it is added as a childtag, but in some cases a type tag is used for unclear reasons. Also most of the time there is no reference to the namespace of a type, so you need to have global knowledge or a search engine to make links between interfaces. Also : type HRESULT = type Longint; does not yield anything in the xml documentation

QC #: 34805 - Status: Closed

QC #: Project Date Reported: Area:34805 Delphi 10/3/2006 ActiveX\Framework\DAX\RTL

Description Steps:[QC Short Description] Allow DllRegister, DllUnregister (and other affected routines) to call a user-defined procedure [QC Description] Allow DllRegister, DllUnregister (and other affected routines, probably DllGet) to call a user-defined procedure. On Windows 2000 and later, a user account can be a Limited User Account (LUA). In that case, if a Delphi-written in-proc server (written as an EXE, not a DLL) is called, it will attempt to register the OLE classes implemented in the EXE into the registry through HKCR, which is mapped into HKLM\Software\Classes. This will cause an AV when the application is executed in a LUA account. One of the ways to overcome this issue is to use the RegOverridePredefkey to redirect HKCR to HKCU\Software\Classes instead. This can be implemented by defining and calling a OnBefore and OnAfter variable (of procedure). See also Clarify 642168. QC Entry 34805

QC #: 35323 - Status: Closed

QC #: Project Date Reported: Area: 35323 Delphi 10/16/2006 RTL Description Steps:[QC Short Description] AnsiExtractQuotedStr() omits the last char when trailing quote missing [QC Description] If the trailing quote character is missing, the string returned by

Compile and run the attached program below. See the following output instead of the expect output of PASS. FAIL lResult='This is a tes'

AnsiExtractQuotedStr will be shortened by one character. e.g. '"This is a test' will only return 'This is a tes' as the result instead of 'This is a test'. See Steps and attached test case QC Entry 35323

See how the last character of the string is dropped. program BTS242470; {$APPTYPE CONSOLE} uses SysUtils; var lResult: String; lStr: PChar; begin lStr := '"This is a test'; lResult := AnsiExtractQuotedStr(lStr, '"'); if lResult = 'This is a test' then WriteLn('PASS') else WriteLn('FAIL lResult=', lResult); end.

QC #: 35326 - Status: Closed

QC #: Project Date Reported:

Area:

35326 C++Builder 10/16/2006 Linker\ILINK32\Errors/Warnings

Description Steps:[QC Short Description] [Linker Error] Error: Unresolved external 'LresultFromObject' [QC Description] [Linker Error] Error: Unresolved external 'LresultFromObject' referenced from C:\PROGRAM FILES\BORLAND\BDS\4.0\LIB\DEBUG\VCLACTNBAND.LIB|ActnMenus Looks like something wrong in the library. -------------- activeds.dll, 5.1.2600.2180, C:\WINDOWS\system32\ adortl100.bpl, 10.0.2151.25345, C:\WINDOWS\system32\ adsldpc.dll, 5.1.2600.2180, C:\WINDOWS\system32\ ADVAPI32.dll, 5.1.2600.2180, C:\WINDOWS\system32\ appHelp.dll, 5.1.2600.2180, C:\WINDOWS\system32\ asmview100.bpl, 10.0.2151.25345, C:\Program Files\Borland\BDS\4.0\Bin\ ATL.DLL, 3.5.2284.0, C:\WINDOWS\system32\ bcbcoment100.bpl, 10.0.2288.42451, c:\program files\borland\bds\4.0\Bin\ bcbcompro100.bpl, 10.0.2288.42451, c:\program files\borland\bds\4.0\Bin\ bcbent100.bpl, 10.0.2166.28377, c:\program files\borland\bds\4.0\Bin\ bcbide100.bpl, 10.0.2288.42451, C:\Program Files\Borland\BDS\4.0\Bin\ bcbidl100.bpl, 10.0.2288.42451, c:\program files\borland\bds\4.0\Bin\ bcbpro100.bpl, 10.0.2288.42451, c:\program files\borland\bds\4.0\Bin\ bcbsmp100.bpl, 10.0.2288.42451, C:\Program Files\Borland\BDS\4.0\Bin\ bcbvclide100.bpl, 10.0.2288.42451, c:\program files\borland\bds\4.0\Bin\ bccide.dll, 10.0.2288.42451, C:\Program Files\Borland\BDS\4.0\Bin\ bdertl100.bpl, 10.0.2151.25345, C:\WINDOWS\system32\ bds.exe, 10.0.2288.42451, C:\Program Files\Borland\BDS\4.0\Bin\ bdsproj2mak_addin100.bpl, 10.0.2287.36685, c:\program files\borland\bds\4.0\bin\ bdsravereg.dll, 1.0.2284.18210, c:\program files\borland\bds\4.0\bin\ boreditu.dll, 10.0.2288.42451, C:\Program Files\Borland\BDS\4.0\Bin\ Borland.Caliber.IDE100.bpl, 10.0.2288.42451, c:\program files\borland\bds\4.0\Bin\ borland.data.common.dll, 10.0.2288.42451, c:\windows\assembly\gac\borland.data.common\2.5.0.0__91d62ebb5b0d1b1b\ borland.data.datasync.dll, 2.5.0.0, c:\windows\assembly\gac\borland.data.datasync\2.5.0.0__91d62ebb5b0d1b1b\ borland.data.provider.dll, 10.0.2288.42451,

c:\windows\assembly\gac\borland.data.provider\2.5.0.0__91d62ebb5b0d1b1b\ borland.data.web.dll, 10.0.2288.42451, c:\windows\assembly\gac\borland.data.web\2.0.0.0__91d62ebb5b0d1b1b\ borland.data.web.eco.dll, 10.0.2151.25345, c:\windows\assembly\gac\borland.data.web.eco\2.0.0.0__91d62ebb5b0d1b1b\ borland.delphi.dll, 10.0.2151.25345, c:\windows\assembly\gac\borland.delphi\10.0.4143.0__91d62ebb5b0d1b1b\ borland.eco.handles.dll, 10.0.2288.42451, c:\windows\assembly\gac\borland.eco.handles\10.0.4143.0__91d62ebb5b0d1b1b\ borland.eco.interfaces.dll, 10.0.2288.42451, c:\windows\assembly\gac\borland.eco.interfaces\10.0.4143.0__91d62ebb5b0d1b1b\ borland.eco.persistence.bdp.dll, 10.0.2151.25345, c:\windows\assembly\gac\borland.eco.persistence.bdp\10.0.4143.0__91d62ebb5b0d1b1b\ borland.eco.persistence.dll, 10.0.2288.42451, c:\windows\assembly\gac\borland.eco.persistence\10.0.4143.0__91d62ebb5b0d1b1b\ borland.eco.persistence.sqlserver.dll, 10.0.2151.25345, c:\windows\assembly\gac\borland.eco.persistence.sqlserver\10.0.4143.0__91d62ebb5b0d1b1b\ borland.eco.persistence.xml.dll, 10.0.2151.25345, c:\windows\assembly\gac\borland.eco.persistence.xml\10.0.4143.0__91d62ebb5b0d1b1b\ borland.eco.web.dll, 10.0.2288.42451, c:\windows\assembly\gac\borland.eco.web\10.0.4143.0__91d62ebb5b0d1b1b\ borland.eco.windows.forms.dll, 10.0.2288.42451, c:\windows\assembly\gac\borland.eco.windows.forms\10.0.4143.0__91d62ebb5b0d1b1b\ borland.globalization.dll, 10.0.2151.25345, c:\program files\borland\bds\4.0\bin\ borland.sci.dll, 10.0.2151.25345, c:\program files\borland\bds\4.0\bin\ borland.starteam.core.dll, 8.0.0.69, c:\windows\assembly\gac\borland.starteam.core\8.0.0.69__c4c57974ea1e3017\ borland.starteam.ide.dll, 8.0.0.28, c:\program files\borland\bds\4.0\bin\ borland.starteam.ui.dll, 8.0.0.103, c:\program files\borland\bds\4.0\bin\ borland.studio.cpp.dll, 10.0.2288.42451, c:\program files\borland\bds\4.0\bin\ borland.studio.delphi.dll, 10.0.2288.42451, c:\program files\borland\bds\4.0\bin\ borland.studio.delphi.gate.dll, 10.0.2151.25345, c:\program files\borland\bds\4.0\bin\ borland.studio.host.dll, 10.0.2288.42451, c:\program files\borland\bds\4.0\bin\ borland.studio.interop.dll, 10.0.2341.30612, c:\program files\borland\bds\4.0\bin\ borland.studio.refactoring.dll, 10.0.2288.42451, c:\program files\borland\bds\4.0\bin\ borland.studio.starteam.dll, 10.0.2288.42451, c:\program files\borland\bds\4.0\bin\ borland.studio.toolsapi.dll, 10.0.2151.25345, c:\program files\borland\bds\4.0\bin\ borland.studio.toolsets.dll, 10.0.65535.34930, c:\program files\borland\bds\4.0\bin\ borland.studio.typemappings.dll, 10.0.2151.25345, c:\program files\borland\bds\4.0\bin\ borland.studio.vcl.design.refactoring.dll, 10.0.2288.42451, c:\program files\borland\bds\4.0\bin\ borland.vclrtl.dll, 10.0.2288.42451, c:\windows\assembly\gac\borland.vclrtl\10.0.4143.0__91d62ebb5b0d1b1b\ borlndmm.dll, 10.0.2288.42451, C:\Program Files\Borland\BDS\4.0\Bin\ BrcIde.Dll, 10.0.2151.25345, C:\Program Files\Borland\BDS\4.0\Bin\ browseui.dll, 6.0.2900.2937, C:\WINDOWS\system32\ c1.c1printdocument.dll, 1.0.20033.142, c:\windows\assembly\gac\c1.c1printdocument\1.0.20023.101__1a6f4158ebe6d3b8\ c1.common.dll, 1.0.20042.118, c:\windows\assembly\gac\c1.common\1.0.20031.116__e272bb32d11b1948\ c1.data.dll, 1.0.20033.92, c:\windows\assembly\gac\c1.data\1.0.20022.0__900b028620cd3a1b\ c1.data.express.dll, 1.0.20033.92, c:\windows\assembly\gac\c1.data.express\1.0.20022.0__253763f1c3e4ceec\ c1.win.c1chart3d.dll, 1.0.20033.13155, c:\windows\assembly\gac\c1.win.c1chart3d\1.0.20033.13147__a22e16972c085838\ c1.win.c1command.dll, 1.0.20033.31, c:\windows\assembly\gac\c1.win.c1command\1.0.20023.1__e808566f358766d8\ c1.win.c1flexgrid.classic.dll, 2.1.20033.144, c:\windows\assembly\gac\c1.win.c1flexgrid.classic\2.1.20031.104__c9c7ad9c0a5706c9\ c1.win.c1flexgrid.dll, 2.1.20033.144, c:\windows\assembly\gac\c1.win.c1flexgrid\2.1.20031.104__c9c7ad9c0a5706c9\ c1.win.c1input.dll, 1.0.20033.53, c:\windows\assembly\gac\c1.win.c1input\1.0.20031.0__7e7ff60f0c214f9a\ c1.win.c1list.dll, 1.1.20033.23, c:\windows\assembly\gac\c1.win.c1list\1.1.20023.6__6b24f8f981dbd7bc\ c1.win.c1printpreview.dll, 1.0.20033.142, c:\windows\assembly\gac\c1.win.c1printpreview\1.0.20023.101__3af768410ba0a64f\ c1.win.c1report.dll, 1.1.20033.100, c:\windows\assembly\gac\c1.win.c1report\1.1.20023.28__c9c7ad9c0a5706c9\ c1.win.c1spell.dll, 1.2.20033.38, c:\windows\assembly\gac\c1.win.c1spell\1.2.20023.29__f6f2c1ef135ddbd4\ c1.win.c1thesaurus.dll, 1.2.20033.38, c:\windows\assembly\gac\c1.win.c1thesaurus\1.2.20023.29__c644e6d97aec9e47\ c1.win.c1truedbgrid.dll, 1.2.20033.30829, c:\windows\assembly\gac\c1.win.c1truedbgrid\1.2.20033.30829__75ae3fb0e2b1e0da\

CC3270MT.DLL, 7.0.0.2, C:\WINDOWS\system32\ CLBCATQ.DLL, 2001.12.4414.308, C:\WINDOWS\system32\ codeguardide100.bpl, 10.0.2288.42451, c:\program files\borland\bds\4.0\Bin\ codetemplates100.bpl, 10.0.2288.42451, c:\program files\borland\bds\4.0\Bin\ comcore100.bpl, 10.0.2288.42451, C:\Program Files\Borland\BDS\4.0\Bin\ comctl32.dll, 5.82.2900.2982, C:\WINDOWS\system32\ comctl32.dll, 6.0.2900.2982, C:\WINDOWS\WinSxS\x86_Microsoft.Windows.Common-Controls_6595b64144ccf1df_6.0.2600.2982_x-ww_ac3f9c03\ comdlg32.dll, 6.0.2900.2180, C:\WINDOWS\system32\ comentcore100.bpl, 10.0.2288.42451, C:\Program Files\Borland\BDS\4.0\Bin\ COMP32X.DLL, 5.8.2.0, C:\Program Files\Borland\BDS\4.0\Bin\ COMRes.dll, 2001.12.4414.258, C:\WINDOWS\system32\ coreide100.bpl, 10.0.2445.40105, C:\Program Files\Borland\BDS\4.0\Bin\ coreproide100.bpl, 10.0.2288.42451, c:\program files\borland\bds\4.0\Bin\ CRYPT32.dll, 5.131.2600.2180, C:\WINDOWS\system32\ CRYPTUI.dll, 5.131.2600.2180, C:\WINDOWS\system32\ CSCDLL.dll, 5.1.2600.2180, C:\WINDOWS\System32\ cscui.dll, 5.1.2600.2180, C:\WINDOWS\System32\ DataExplorer100.bpl, 10.0.2151.25345, c:\program files\borland\bds\4.0\Bin\ dbexpress100.bpl, 10.0.2288.42451, C:\WINDOWS\system32\ dbkdebugide100.bpl, 10.0.2288.42451, c:\program files\borland\bds\4.0\Bin\ dbkdebugproide100.bpl, 10.0.2288.42451, c:\program files\borland\bds\4.0\Bin\ dbrtl100.bpl, 10.0.2288.42451, C:\WINDOWS\system32\ dbx100.bpl, 10.0.2151.25345, C:\Program Files\Borland\BDS\4.0\Bin\ dbxcds100.bpl, 10.0.2151.25345, C:\WINDOWS\system32\ dcc100.dll, 10.0.2418.27083, C:\Program Files\Borland\BDS\4.0\Bin\ DCIMAN32.dll, 5.1.2600.2180, C:\WINDOWS\system32\ dcl31w100.bpl, 10.0.2151.25345, c:\program files\borland\bds\4.0\Bin\ dclact100.bpl, 10.0.2288.42451, c:\program files\borland\bds\4.0\Bin\ dclado100.bpl, 10.0.2151.25345, c:\program files\borland\bds\4.0\bin\ dclbcbsmp100.bpl, 10.0.2092.21476, c:\program files\borland\bds\4.0\Bin\ dclbde100.bpl, 10.0.2151.25345, C:\Program Files\Borland\BDS\4.0\Bin\ dcldb100.bpl, 10.0.2288.42451, c:\program files\borland\bds\4.0\Bin\ dcldbx100.bpl, 10.0.2288.42451, c:\program files\borland\bds\4.0\Bin\ dclemacsedit100.bpl, 10.0.2151.25345, c:\program files\borland\bds\4.0\Bin\ dclib100.bpl, 10.0.2151.25345, c:\program files\borland\bds\4.0\Bin\ dclIntraweb_80_100.bpl, , c:\program files\borland\bds\4.0\Bin\ dclmcn100.bpl, 10.0.2151.25345, c:\program files\borland\bds\4.0\Bin\ dclmid100.bpl, 10.0.2151.25345, c:\program files\borland\bds\4.0\Bin\ dclmlwiz100.bpl, 10.0.2151.25345, c:\program files\borland\bds\4.0\Bin\ dclnet100.bpl, 10.0.2288.42451, c:\program files\borland\bds\4.0\Bin\ dclRave.bpl, , c:\program files\borland\bds\4.0\RaveReports\Lib\ dclrx2006.bpl, 1.0.0.0, C:\Program Files\Borland\BDS\4.0\mybpl\ dclsmp100.bpl, 9.0.1655.26747, c:\program files\borland\bds\4.0\Bin\ dclsmpedit100.bpl, 10.0.2151.25345, c:\program files\borland\bds\4.0\Bin\ dclsoap100.bpl, 10.0.2288.42451, c:\program files\borland\bds\4.0\Bin\ dclstd100.bpl, 10.0.2151.25345, c:\program files\borland\bds\4.0\Bin\ dcltee100.bpl, 10.0.2151.25345, c:\program files\borland\bds\4.0\Bin\ dclwbm100.bpl, 10.0.2151.25345, C:\Program Files\Borland\BDS\4.0\Bin\ dclwebsnap100.bpl, 6.0.0.0, c:\program files\borland\bds\4.0\Bin\ DDRAW.dll, 5.3.2600.2180, C:\WINDOWS\system32\ delphicoreide100.bpl, 10.0.2445.40105, C:\Program Files\Borland\BDS\4.0\Bin\ delphidotnetcore100.bpl, 10.0.2151.25345, c:\program files\borland\bds\4.0\Bin\ delphivclide100.bpl, 10.0.2151.25345, c:\program files\borland\bds\4.0\Bin\ deployapi100.bpl, 10.0.2151.25345, C:\Program Files\Borland\BDS\4.0\Bin\ DeployCore100.bpl, 10.0.2288.42451, C:\Program Files\Borland\BDS\4.0\Bin\ deployftptarget100.bpl, 10.0.2151.25345, C:\Program Files\Borland\BDS\4.0\Bin\ deployide100.bpl, 10.0.2151.25345, c:\program files\borland\bds\4.0\bin\ DeployIndy100.bpl, 10.0.2151.25345, C:\Program Files\Borland\BDS\4.0\Bin\ designide100.bpl, 10.0.2288.42451, C:\Program Files\Borland\BDS\4.0\Bin\ dhtmlcomps100.bpl, 10.0.2288.42451, C:\Program Files\Borland\BDS\4.0\Bin\ diasymreader.dll, 7.10.3052.4, C:\WINDOWS\Microsoft.NET\Framework\v1.1.4322\ DotNetCoreAssemblies100.bpl, 10.0.2151.25345, C:\Program Files\Borland\BDS\4.0\Bin\ dotnetcoreide100.bpl, 10.0.2288.42451, C:\Program Files\Borland\BDS\4.0\Bin\ dsnap100.bpl, 10.0.2288.42451, C:\WINDOWS\system32\ dsnapcon100.bpl, 10.0.2151.25345, C:\WINDOWS\system32\ exceptiondiag100.bpl, 10.0.2151.25345, c:\program files\borland\bds\4.0\Bin\ fusion.dll, 1.1.4322.2032, C:\WINDOWS\Microsoft.NET\Framework\v1.1.4322\ GDI32.dll, 5.1.2600.2818, C:\WINDOWS\system32\ gdiplus.dll, 5.1.3102.2180, C:\WINDOWS\WinSxS\x86_Microsoft.Windows.GdiPlus_6595b64144ccf1df_1.0.2600.2180_x-ww_522f9f82\ gds32.dll, 7.5.1.80, C:\WINDOWS\system32\ GLU32.dll, 5.1.2600.2180, C:\WINDOWS\system32\

historyide100.bpl, 10.0.2151.25345, c:\program files\borland\bds\4.0\Bin\ htmide100.bpl, 10.0.2329.20030, c:\program files\borland\bds\4.0\Bin\ HTMLDlgs100.bpl, 10.0.2151.25345, C:\Program Files\Borland\BDS\4.0\Bin\ htmlhelp2100.bpl, 10.0.2151.25345, c:\program files\borland\bds\4.0\Bin\ htmlide100.bpl, 10.0.2288.42451, c:\program files\borland\bds\4.0\Bin\ htmltidy100.bpl, 10.0.2151.25345, c:\program files\borland\bds\4.0\Bin\ ibxml.dll, 7.5.1.80, C:\WINDOWS\system32\ ibxpress100.bpl, 10.0.2288.42451, C:\WINDOWS\system32\ idectrls100.bpl, 10.0.2151.25345, C:\Program Files\Borland\BDS\4.0\Bin\ idefilefilters100.bpl, 10.0.2288.42451, c:\program files\borland\bds\4.0\Bin\ IDETools100.bpl, 10.0.2151.25345, c:\program files\borland\bds\4.0\Bin\ IMAGEHLP.DLL, 5.1.2600.2180, C:\WINDOWS\system32\ ImgUtil.dll, 6.0.2900.2180, C:\WINDOWS\system32\ imm32.dll, 5.1.2600.2180, C:\WINDOWS\system32\ inet100.bpl, 10.0.2151.25345, C:\WINDOWS\system32\ inetdb100.bpl, 10.0.2151.25345, C:\WINDOWS\system32\ inetdbbde100.bpl, 10.0.2151.25345, C:\WINDOWS\system32\ inetdbxpress100.bpl, 10.0.2151.25345, C:\WINDOWS\system32\ Intraweb_80_100.bpl, , C:\WINDOWS\system32\ IntrawebDB_80_100.bpl, , C:\WINDOWS\system32\ iphlpapi.dll, 5.1.2600.2912, C:\WINDOWS\system32\ jscript.dll, 5.6.0.8831, C:\WINDOWS\system32\ kernel32.dll, 5.1.2600.2945, C:\WINDOWS\system32\ libtidy.dll, , C:\Program Files\Borland\BDS\4.0\Bin\ MFC42.DLL, 6.2.4131.0, C:\WINDOWS\system32\ midimap.dll, 5.1.2600.2180, C:\WINDOWS\system32\ mlang.dll, 6.0.2900.2180, C:\WINDOWS\system32\ MLCC100.bpl, 10.0.2151.25345, C:\Program Files\Borland\BDS\4.0\Bin\ mpr.dll, 5.1.2600.2180, C:\WINDOWS\system32\ MSACM32.dll, 5.1.2600.2180, C:\WINDOWS\system32\ msacm32.drv, 5.1.2600.0, C:\WINDOWS\system32\ MSASN1.dll, 5.1.2600.2180, C:\WINDOWS\system32\ mscoree.dll, 1.1.4322.2032, C:\WINDOWS\system32\ MSCORJIT.DLL, 1.1.4322.2032, C:\WINDOWS\Microsoft.NET\Framework\v1.1.4322\ mscorlib.dll, 1.1.4322.2032, c:\windows\microsoft.net\framework\v1.1.4322\ mscorlib.dll, , c:\windows\assembly\nativeimages1_v1.1.4322\mscorlib\1.0.5000.0__b77a5c561934e089_a6ed24c2\ mscorsn.dll, 1.1.4322.573, C:\WINDOWS\Microsoft.NET\Framework\v1.1.4322\ mscorwks.dll, 1.1.4322.2032, C:\WINDOWS\Microsoft.NET\Framework\v1.1.4322\ MSCTF.dll, 5.1.2600.2180, C:\WINDOWS\system32\ mshtml.dll, 6.0.2900.2963, C:\WINDOWS\system32\ mshtmled.dll, 6.0.2900.2937, C:\WINDOWS\system32\ msi.dll, 3.1.4000.2435, C:\WINDOWS\system32\ msimg32.dll, 5.1.2600.2180, C:\WINDOWS\system32\ msimtf.dll, 5.1.2600.2180, C:\WINDOWS\system32\ msls31.dll, 3.10.349.0, C:\WINDOWS\system32\ msv1_0.dll, 5.1.2600.2180, C:\WINDOWS\system32\ MSVCI70.dll, 7.0.9466.0, C:\Program Files\Borland\BDS\4.0\Bin\ MSVCP60.dll, 6.2.3104.0, C:\WINDOWS\system32\ MSVCR70.dll, 7.0.9466.0, C:\Program Files\Borland\BDS\4.0\Bin\ MSVCR71.dll, 7.10.3052.4, C:\WINDOWS\Microsoft.NET\Framework\v1.1.4322\ msvcrt.dll, 7.0.2600.2180, C:\WINDOWS\system32\ msxml3.dll, 8.70.1113.0, C:\WINDOWS\system32\ msxml4.dll, 4.20.9818.0, C:\WINDOWS\system32\ NETAPI32.dll, 5.1.2600.2952, C:\WINDOWS\system32\ ntdll.dll, 5.1.2600.2180, C:\WINDOWS\system32\ ole32.dll, 5.1.2600.2726, C:\WINDOWS\system32\ oleacc.dll, 4.2.5406.0, C:\WINDOWS\system32\ oleaut32.dll, 5.1.2600.2180, C:\WINDOWS\system32\ oledlg.dll, 5.1.2600.0, C:\WINDOWS\system32\ olepro32.dll, 5.1.2600.2180, C:\WINDOWS\system32\ opengl32.dll, 5.1.2600.2180, C:\WINDOWS\system32\ optimizeitide100.bpl, 10.0.2151.25345, c:\program files\borland\bds\4.0\Bin\ plugview100.bpl, 10.0.2151.25345, C:\Program Files\Borland\BDS\4.0\Bin\ pngfilt.dll, 6.0.2900.2937, C:\WINDOWS\system32\ PSAPI.DLL, 5.1.2600.2180, C:\WINDOWS\system32\ RASAPI32.DLL, 5.1.2600.2180, C:\WINDOWS\system32\ rasman.dll, 5.1.2600.2180, C:\WINDOWS\system32\ Rave65VCL100.bpl, , C:\WINDOWS\system32\ refactoride100.bpl, 10.0.2151.25345, c:\program files\borland\bds\4.0\Bin\ RICHED20.dll, 5.30.23.1221, C:\WINDOWS\system32\ RPCRT4.dll, 5.1.2600.2180, C:\WINDOWS\system32\ rsaenh.dll, 5.1.2600.2161, C:\WINDOWS\system32\

rtl100.bpl, 10.0.2288.42451, C:\WINDOWS\system32\ rtutils.dll, 5.1.2600.2180, C:\WINDOWS\system32\ rxctl2006.bpl, 1.0.0.0, C:\WINDOWS\system32\ sanctuarylib.dll, , C:\Program Files\Borland\BDS\4.0\Bin\ SCRRUN.DLL, 5.6.0.8820, C:\WINDOWS\system32\ Secur32.dll, 5.1.2600.2180, C:\WINDOWS\system32\ sensapi.dll, 5.1.2600.2180, C:\WINDOWS\system32\ serwvdrv.dll, 5.1.2600.0, C:\WINDOWS\system32\ SETUPAPI.dll, 5.1.2600.2180, C:\WINDOWS\system32\ shdoclc.dll, 6.0.2900.2180, C:\WINDOWS\system32\ shdocvw.dll, 6.0.2900.2987, C:\WINDOWS\system32\ shell32.dll, 6.0.2900.2951, C:\WINDOWS\system32\ SHFOLDER.dll, 6.0.2900.2180, C:\WINDOWS\system32\ SHLWAPI.dll, 6.0.2900.2937, C:\WINDOWS\system32\ soaprtl100.bpl, 10.0.2288.42451, C:\WINDOWS\system32\ startpageide100.bpl, 10.0.2288.42451, c:\program files\borland\bds\4.0\Bin\ stide100.bpl, 10.0.2288.42451, c:\program files\borland\bds\4.0\Bin\ StSDKOSEnvironment_01.dll, 8.0.0.58, C:\Program Files\Borland\StarTeam SDK 2005 R2\Lib\ StWinProfile.dll, 6.0.0.0, C:\Program Files\Borland\BDS\4.0\Bin\ sxs.dll, 5.1.2600.2180, C:\WINDOWS\system32\ system.data.dll, 1.1.4322.2032, c:\windows\assembly\gac\system.data\1.0.5000.0__b77a5c561934e089\ system.design.dll, 1.1.4322.2032, c:\windows\assembly\gac\system.design\1.0.5000.0__b03f5f7f11d50a3a\ system.design.dll, , c:\windows\assembly\nativeimages1_v1.1.4322\system.design\1.0.5000.0__b03f5f7f11d50a3a_ee37ca55\ system.dll, 1.1.4322.2032, c:\windows\assembly\gac\system\1.0.5000.0__b77a5c561934e089\ system.dll, , c:\windows\assembly\nativeimages1_v1.1.4322\system\1.0.5000.0__b77a5c561934e089_8aab158d\ system.drawing.dll, 1.1.4322.2032, c:\windows\assembly\gac\system.drawing\1.0.5000.0__b03f5f7f11d50a3a\ system.drawing.dll, , c:\windows\assembly\nativeimages1_v1.1.4322\system.drawing\1.0.5000.0__b03f5f7f11d50a3a_f4769dd9\ system.web.dll, 1.1.4322.2037, c:\windows\assembly\gac\system.web\1.0.5000.0__b03f5f7f11d50a3a\ system.windows.forms.dll, 1.1.4322.2032, c:\windows\assembly\gac\system.windows.forms\1.0.5000.0__b77a5c561934e089\ system.windows.forms.dll, , c:\windows\assembly\nativeimages1_v1.1.4322\system.windows.forms\1.0.5000.0__b77a5c561934e089_861171cb\ system.xml.dll, 1.1.4322.2032, c:\windows\assembly\gac\system.xml\1.0.5000.0__b77a5c561934e089\ system.xml.dll, , c:\windows\assembly\nativeimages1_v1.1.4322\system.xml\1.0.5000.0__b77a5c561934e089_437b57a5\ TAPI32.dll, 5.1.2600.2180, C:\WINDOWS\system32\ tee100.bpl, 10.0.2151.25345, C:\WINDOWS\system32\ teedb100.bpl, 10.0.2151.25345, C:\WINDOWS\system32\ teeui100.bpl, 10.0.2151.25345, C:\WINDOWS\system32\ tlbview100.bpl, 10.0.2151.25345, C:\Program Files\Borland\BDS\4.0\Bin\ tlib100.bpl, 10.0.2288.42451, C:\Program Files\Borland\BDS\4.0\Bin\ todoide100.bpl, 10.0.2288.42451, c:\program files\borland\bds\4.0\Bin\ umdmxfrm.dll, 5.1.2600.0, C:\WINDOWS\system32\ URLMON.DLL, 6.0.2900.2960, C:\WINDOWS\system32\ USER32.dll, 5.1.2600.2622, C:\WINDOWS\system32\ USERENV.dll, 5.1.2600.2180, C:\WINDOWS\system32\ uxtheme.dll, 6.0.2900.2180, C:\WINDOWS\system32\ vcl100.bpl, 10.0.2288.42451, C:\WINDOWS\system32\ vclactnband100.bpl, 10.0.2288.42451, C:\Program Files\Borland\BDS\4.0\Bin\ vcldb100.bpl, 10.0.2288.42451, C:\WINDOWS\system32\ vcldbx100.bpl, 10.0.2151.25345, C:\WINDOWS\system32\ vcldesigner100.bpl, 10.0.2151.25345, C:\Program Files\Borland\BDS\4.0\Bin\ vclhie100.bpl, 10.0.2151.25345, C:\Program Files\Borland\BDS\4.0\Bin\ vclib100.bpl, , C:\WINDOWS\system32\ vclide100.bpl, 10.0.2288.42451, C:\Program Files\Borland\BDS\4.0\Bin\ vclie100.bpl, 10.0.2151.25345, C:\WINDOWS\system32\ vcljpg100.bpl, 10.0.2151.25345, C:\WINDOWS\system32\ vclmenudesigner100.bpl, 10.0.2151.25345, c:\program files\borland\bds\4.0\Bin\ VclSmp100.bpl, 9.0.1655.26747, C:\WINDOWS\system32\ vclx100.bpl, 10.0.2151.25345, C:\WINDOWS\system32\ version.dll, 5.1.2600.2180, C:\WINDOWS\system32\

vjscor.dll, 1.1.4322.0, c:\windows\assembly\gac\vjscor\1.0.5000.0__b03f5f7f11d50a3a\ vjscor.dll, , c:\windows\assembly\nativeimages1_v1.1.4322\vjscor\1.0.5000.0__b03f5f7f11d50a3a_3f9de9ad\vjslib.dll, , c:\windows\assembly\gac\vjslib\1.0.5000.0__b03f5f7f11d50a3a\ vjslib.dll, , c:\windows\assembly\nativeimages1_v1.1.4322\vjslib\1.0.5000.0__b03f5f7f11d50a3a_90aaa79b\vjsnativ.dll, 1.1.4322.0, C:\WINDOWS\Microsoft.NET\Framework\v1.1.4322\ vport_r_6.dll, , C:\Program Files\Borland\BDS\4.0\Bin\ wdmaud.drv, 5.1.2600.2180, C:\WINDOWS\system32\ webdsnap100.bpl, 10.0.2151.25345, C:\WINDOWS\system32\ websnap100.bpl, 10.0.2151.25345, C:\WINDOWS\system32\ win32debugide100.bpl, 10.0.2288.42451, C:\Program Files\Borland\BDS\4.0\Bin\ win32debugproide100.bpl, 10.0.2288.42451, c:\program files\borland\bds\4.0\Bin\ winhttp.dll, 5.1.2600.2180, C:\WINDOWS\system32\ wininet.dll, 6.0.2900.2937, C:\WINDOWS\system32\ winmm.dll, 5.1.2600.2180, C:\WINDOWS\system32\ winspool.drv, 5.1.2600.2180, C:\WINDOWS\system32\ WINTRUST.dll, 5.131.2600.2180, C:\WINDOWS\system32\ WLDAP32.dll, 5.1.2600.2180, C:\WINDOWS\system32\ WS2_32.dll, 5.1.2600.2180, C:\WINDOWS\system32\ WS2HELP.dll, 5.1.2600.2180, C:\WINDOWS\system32\ Wship6.dll, 5.1.2600.2180, C:\WINDOWS\system32\ wsock32.dll, 5.1.2600.2180, C:\WINDOWS\system32\ xmlrtl100.bpl, 10.0.2151.25345, C:\WINDOWS\system32\ xpsp2res.dll, 5.1.2600.2180, C:\WINDOWS\system32\ QC Entry 35326

QC #: 35710 - Status: Closed

QC #: Project Date Reported: Area: 35710 Delphi 10/25/2006 RTL\Delphi\Other RTL Description Steps:[QC Short Description] TObjectList.Notify is not optimal [QC Description] The TObjectList.Notify can be improved: - First it tests for OwnsObjects before even testing if the Action is lnDeleted. This costs one memory access for each lnAdd and lnExtracted action. - Second it calls the inherited TList.Notify method which itself doesn't do anything. So this call can be removed. QC Entry 35710

no stops, see Workaround

QC #: 36006 - Status: Closed

QC #: Project Date Reported: Area:36006 Delphi 11/1/2006 IDE\Project Management\Project Manager

Description Steps:[QC Short Description] Highlander does not release folder [QC Description] If save a project in a newly created folder, Highlander does not release the folder after closing the project. Trying to delete the folder in the Windows Explorer will result in an error message: "cannot delete folder: it is being used by another person or program". QC Entry 36006

1. Create a new VCL Win32 project 2. Save All, choose a new folder which has just been created! 3. Close All 4. Change to Windows Explorer and try to delete the folder. "cannot delete folder: it is being used by another person or program".

QC #: 36279 - Status: Closed

QC #: Project Date Reported: Area: 36279 Delphi 11/7/2006 IDE\ToDoList Description Steps:[QC Short Description] Add Todo Item Enhancement [QC Description] If I open the todo list via the speedmenu "Add todo item" then the todo list does not contain old todo entries (ok) and the owner and category combo boxes does not contain any of the old entries. I would like the owner and category combo boxes to be filled with existing items. QC Entry 36279

I have this todo entry //TODO 1 -oDKC -cBug -DKC: Add more validation testsets I open the todolist from the speedmenu and want to make another entry with Owner = DKC and Category = Bug, but cannot select any of these in the boxes.

QC #: 36363 - Status: Closed

QC #: Project Date Reported: Area: 36363 Delphi 11/8/2006 IDE\File Handling Description Steps:[QC Short Description] Inconsistent handling of includes [QC Description] The inculdes like {$I 'global.inc'} could be helpful, but the parser and probably the compiler not handling well in some cases. (sample projects attached and just try to open, compile, save as, etc.) QC Entry 36363

Download attachment Start IDE Open the project c2Project1.bdsproj Compile the project //exp: no error - should find it in the global.inc file //act: --------------------------- Error --------------------------- Error in module c2Unit1: Declaration of class TForm1 is missing or incorrect. --------------------------- OK Help Details >> --------------------------- If you open c1Project1.bdsproj, you'll find the code that was apart of global.inc, in the project. Compiles fine. --------- ORIGINAL -------------------- Drop some components, made eventhandlers for them, and made some own methods, too. Made a new file and save it as global.inc move TForm1's source into this file and save it. Now replace the class-declaration with {$I 'global.inc'} like: {$I 'global.inc'} var Form1: TForm1; See structire-pane ---> no error (of course) Try to compile ---> result an error --------------------------- Error --------------------------- Error in module stufmonstfrm_main2: Declaration of class TForm1 is missing or incorrect. --------------------------- OK Help Details >> --------------------------- Try to copy back TForm1's class decalration {$I 'global.inc'} type TForm1 = class(TForm)..... .............. end; try to compile ---> an error (of course) [Pascal Error] stufmonstfrm_main2.pas(23): E2004 Identifier redeclared: 'TForm1'

QC #: 37344 - Status: Closed

QC #: Project Date Reported: Area:37344 Delphi 6/20/2007 VCL\Win 32 Controls\TComboBoxEx

Description Steps:The destructor of TCustomComboBoxEx calls CoUninitialize. This should only be called if a preceding call to CoInitialize returned success. This is a problem if the application uses COINIT_MULTITHREADED as threading model. Calling CoInitialize with both COINIT_MULTITHREADED + COINIT_APARTMENTTHREADED doesn't make sense, because COINIT_MULTITHREADED = 0; constructor TCustomComboBoxEx.Create(AOwner: TComponent); begin //... if Assigned(CoInitializeExProc) then

Add the following code to a unit: initialization CoInitFlags := COINIT_MULTITHREADED; end. Then add TComboBoxEx to a dynamically created form.

CoInitializeExProc(nil, COINIT_MULTITHREADED or COINIT_APARTMENTTHREADED); //... destructor TCustomComboBoxEx.Destroy; begin //... CoUninitialize; //... See http://blogs.msdn.com/benkuhn/archive/2006/09/15/756401.aspx for more detailed information.

QC #: 37846 - Status: Closed

QC #: Project Date Reported: Area: 37846 Delphi 12/18/2006 VCL Description Steps:[QC Short Description] Add ActiveLineNo property to TRichEdit [QC Description] I would like to have a property for the TRichEdit control that gives me the line number of the active line (the line where the edit cursor sits). This is an often needed feature and such a would prevent having to write more complex Windows API code like this: ActiveLineNo := Perform(EM_LINEFROMCHAR, -1, 0); when this would be easier to read: ActiveLineNo := RichEdit1.ActiveLineNo; The RichEdit1.CaretPos.Y property returns the line number but only for non wrapped lines. It is also less elegant. Regards Dennis Kjaer Christensen

QC #: 38090 - Status: Closed

QC #: Project Date Reported: Area: 38090 Delphi 12/26/2006 IDE\Object Inspector Description Steps:[QC Short Description] Themed IDE: drop down buttons in Object Inspector inconsistent [QC Description] With the IDE now being themed, the custom drawn drop down buttons in Object Inspector look different from typcial combobox drop down buttons. See attached screenshot. QC Entry 38090

1. Create a new VCL Forms project 2. Select e.g. Form.BorderStyle property exp: drop down buttons of BorderStyle property and the component list above OI look the same as e.g. the one from the layout combobox in the main menu act: drop down buttons look different

QC #: 38824 - Status: Closed

QC #: Project Date Reported: Area:

38824 Delphi 1/16/2007 Documentation\Online Help\VCL

Description Steps:[QC Short Description] DrawButtonFace help contains spurious parameter information [QC Description] The help for the DrawButtonFace routine in Buttons.pas - ms-help://borland.bds5/bds5win32api_win32/html/DelphiWin32_ButtonsDrawButtonFaceRoutine.htm - list the parameter correctly in the Syntax section, but then in the Description section omits the Style and IsRounded parameters, but gives help for three non-existent parameters: Flat, FillColor, and FillStyle. QC Entry 38824

confirm fixed in Weaver ms-help://embarcadero.rs2010/vcl/Buttons.DrawButtonFace.html

QC #: 38827 - Status: Closed

QC #: Project Date Reported: Area:38827 Delphi 1/16/2007 Documentation\IDE Help Contexts Description Steps:[QC Short Description] Windows message help topics not context enabled [QC Description] The Window messages (WM_*) are not context linked. See Steps for details. QC Entry 38827

1. File, New VCL Application 2. Add valid code referencing a Windows message constant, such as: procedure TForm1.FormCreate(Sender: TObject); begin Height := WM_MOUSEMOVE; end; 3. Press F1 on the windows messag constant WM_MOUSEMOVE Expected: Help opens with the WM_MOUSEMOVE topic Actual: IDE throws an error: ---------------------------Error --------------------------- The keyword is not defined. --------------------------- OK Details << --------------------------- + $21[027F79F8]{htmlhelp2110.bpl} PasHelp.PasHelp.TBasePascalHelpTraits.ShowEditorHelp (Line 291, "PasHelp.pas" + 187) + $21 + $0[0033A465]{rtl110.bpl } System.System.@CheckAutoResult (Line 18109, "sys\system.pas" + 6) + $0 + $6[209D9271]{coreide110.bpl} EditorControl.EditorControl.TCustomEditControl.HelpKeyword (Line 4428, "EditorControl.pas" + 8) + $6 + $17[209DF0D8]{coreide110.bpl} EditorControl.EditorControl.TCustomEditControl.AutoInvokeCodeCompletion (Line 7255, "EditorControl.pas" + 1) + $17 + $6[0047D115]{vcl110.bpl } Controls.Controls.TWinControl.WndProc (Line 8923, "Controls.pas" + 129) + $6 + $6[0047C8A8]{vcl110.bpl } Controls.Controls.TWinControl.MainWndProc (Line 8659, "Controls.pas" + 3) + $6 + $0[0037107C]{rtl110.bpl } Classes.Classes.StdWndProc (Line 11596, "common\Classes.pas" + 8) + $0 + $6A[77D48731]{USER32.dll } GetDC + $6A + $14A[77D48811]{USER32.dll } GetDC + $14A + $17F[77D4B4BB]{USER32.dll } DefWindowProcW + $17F + $1CD[77D4B509]{USER32.dll } DefWindowProcW + $1CD + $10[7C90EAE0]{ntdll.dll } KiUserCallbackDispatcher + $10 + $44[77D5F3DE]{USER32.dll } SendMessageA + $44 + $1B[209C9C7A]{coreide110.bpl} VClient.VClient.KeyBindingProc (Line 2644, "VClient.pas" + 20) + $1B + $2C[2099A20E]{coreide110.bpl} IDEKbd.IDEKbd.@interpret_bmi_macro$qqrp5BMI_tpcp11CmdMapTableppc (Line 30, "bmi.cpp" + 5) + $2C + $10[20998E0A]{coreide110.bpl} IDEKbd.IDEKbd... (Line 132, "kbpublic.cpp" + 88) + $10 + $18[209C73B0]{coreide110.bpl} VClient.VClient.KbdFileOpen (Line 460, "VClient.pas" + 2) + $18 + $8[20A6EA94]{coreide110.bpl} KbClient.KbClient.TIDEKBDFrameAPI.ProcessKeyStroke (Line 723, "KbClient.pas" + 141) + $8 + $5[20A6E519]{coreide110.bpl} KbClient.KbClient.TIDEKBDFrameAPI.KeyboardChanged (Line 517, "KbClient.pas" + 6) + $5 + $2[20A6E829]{coreide110.bpl} KbClient.KbClient.TIDEKBDFrameAPI.ProcessKeyStroke (Line 585, "KbClient.pas" + 3) + $2 + $2[20A6F55C]{coreide110.bpl} KbClient.KbClient.TIDEKBDFrameAPI.RecordKeyMacro (Line 1248, "KbClient.pas" + 3) + $2 + $6[209DDCE8]{coreide110.bpl} EditorControl.EditorControl.TCustomEditControl.WMTimer (Line 6795, "EditorControl.pas" + 15) + $6 + $6[0047D115]{vcl110.bpl } Controls.Controls.TWinControl.WndProc (Line 8923, "Controls.pas" + 129) + $6 + $6[0047C8A8]{vcl110.bpl } Controls.Controls.TWinControl.MainWndProc (Line 8659, "Controls.pas" + 3) + $6 + $0[0037107C]{rtl110.bpl } Classes.Classes.StdWndProc (Line 11596, "common\Classes.pas" + 8) + $0 + $6A[77D48731]{USER32.dll } GetDC + $6A + $14A[77D48811]{USER32.dll } GetDC + $14A + $17F[77D4B4BB]{USER32.dll } DefWindowProcW + $17F + $1CD[77D4B509]{USER32.dll } DefWindowProcW + $1CD +

$10[7C90EAE0]{ntdll.dll } KiUserCallbackDispatcher + $10 + $44[77D4B8FE]{USER32.dll } SendMessageW + $44

QC #: 38921 - Status: Closed

QC #: Project Date Reported: Area: 38921 C++Builder 1/18/2007 IDE\Performance Description Steps:[QC Short Description] IDE Compiler searching & opening the same file multiple times during compiling [QC Description] This is Technically a duplicate of QC: 13775 but with everything together in a cohesive whole with the reasons why it occurs. Asked for by David Dean. When BDS 10/11 compiles a project the internal compiler re-searches for header (and source) files mulitple times down the entire include path; even though it should know where it found it last time -- this is waisting a lot of time duplicating efforts that it should already know about. All of Code Insight features also uses the internal compiler which then causes CI to be a lot slower than it can be. QC Entry 38921

Attached is Andreas Plugin with my mod to track the stats per compile 1. Load BDS 110 project, Install plugin 2. Run->Load Process 3. Choose BDS.exe and run 4. Open the WPM sample application located in ($BDS)\Demos\CPP\Apps\Wpm 5. Project -> Options 6. Disable ALL pre-compiled headers (otherwise your numbers are not correct) -> OK 7. Project -> Build WPM 8. Switch to BDS where you are debugging IDE and you should have on your eventlog: File In Known: 308, In Missed: 655, Total: 1174 Date In Cache: 140, Total: 279 8. Switch back to BDS, and click in the source 9. Hit CTRL-Space, to activate one of the Code Insight features. File In Known: 86, In Missed: 294, Total: 591 Date In Cache: 139, Total: 139 Now these numbers grow exponentionally (yes, exponentionally) each additional unit you add to a project, so on this small aplication with one form (two CPP files); you have that many file hits. Please note the stats/cache are reset for EVERY compile. The statisics are: Number of files that the plugin cached as already knowing didn't exist in that location from a prior request Number of files that the plugin cached as already knowing existed from a prior request Total number of file requests. If you subtract the two cache counts from the Total, that will leave you with the total number of _unique_ valid file requests (Using the above numbers a total of 211). Second stats that is the number of requests for the date/time of a file, and how many were requests for dates that _weren't_ cached. If you subtract the two numbers, then result is the number of date/times that were cached that BDS should already have had since it asked for it before. (Sorry the Output say "In Cache" but it sould actually be "Added to Cache". Using the above build numbers meaning a 140 unique file/date requests and a total of 139 duplicate file date requests.

QC #: 39162 - Status: Closed

QC #: Project Date Reported: Area:39162 Delphi 1/22/2007 Documentation\Help Output Description Steps:[QC Short Description] Missing Topics for Controls.pas (LIST) [QC Description] The following documentation topics are not included in the TOC / Index for for the Controls.pas unit: Controls.NullDockSite Controls.TAlignPositionEvent Controls.TAnchors Controls.TAnimateWindowProc Controls.TBevelEdges Controls.TCanResizeEvent Controls.TConstrainedResizeEvent Controls.TContextPopupEvent Controls.TDockDropEvent Controls.TDockOverEvent Controls.TDragDropEvent Controls.TDragOverEvent Controls.TEndDragEvent Controls.TGetSiteInfoEvent

======================== Fixed in 2010: http://docwiki.embarcadero.com/VCL/en/Controls

Controls.TKeyPressEvent Controls.TMouseActivateEvent Controls.TMouseMoveEvent Controls.TMouseWheelEvent Controls.TMouseWheelUpDownEvent Controls.TStartDragEvent Controls.TUnDockEvent QC Entry 39162

QC #: 39285 - Status: Closed

QC #: Project Date Reported: Area: 39285 Delphi 1/24/2007 IDE\Object Inspector Description Steps:[QC Short Description] Properties edit area doesn't (auto)select on short click [QC Description] In the object inspector, when you click in the editbox or combobox area of a property with a "short" click (when mouse button stays pressed a very short time), the property will be selected, but the text won't autoselect, and the edit/combobox doesn't react to character entry. QC Entry 39285

Create a new VCL form, the go to its properties. Make a short click on one of the edit areas, if you get a cursor or an autoselected content, it's that you didn't click fast enough, try again on a nearby property

QC #: 39336 - Status: Closed

QC #: Project Date Reported: Area: 39336 Delphi 1/25/2007 Documentation Description Steps:[QC Short Description] No documentation for Creating MTS or COM+ objects [QC Description] Navigate to this page in the help file and read it. ms-help://borland.bds5/devwin32/creating_mts_or_com+_objects_xml.html Win32\Reference\DevGuide\dg\Creating_MTS_or_COM+_objects.xml QC Entry 39336

=================== Doc has been updated since 2007; in 2010 see: http://docwiki.embarcadero.com/RADStudio/en/Writing_Applications_Using_COM http://docwiki.embarcadero.com/VCL/en/Mtx http://docwiki.embarcadero.com/VCL/en/Mtx.CreateSharedPropertyGroupManager

QC #: 39374 - Status: Closed

QC #: Project Date Reported: Area:39374 Delphi 1/25/2007 Documentation\Help Output Description Steps:[QC Short Description] Missing Topics for Buttons.pas [QC Description] The following documentation topics are not included in the TOC / Index for the unit Buttons.pas: Buttons.TBitBtnActionLink

Some is done in Weaver: ms-help://embarcadero.rs2010/vcl/Buttons.TBitBtnActionLink.html ms-help://embarcadero.rs2010/vcl/Buttons.TButtonState.html

Buttons.TButtonState Buttons.TNumGlyphs Buttons.TSpeedButtonActionLink QC Entry 39374

ms-help://embarcadero.rs2010/vcl/Buttons.TSpeedButtonActionLink.html

QC #: 39418 - Status: Closed

QC #: Project Date Reported: Area: 39418 C++Builder 1/26/2007 Documentation Description Steps:[QC Short Description] Need link from error [QC Description] ms-help://borland.bds5/bds5win32guide/html/errbaddirect.htm lack links from/to keywords containg of it. QC Entry 39418

Try to use " #region " in a C++ consol source result an error as expected: [C++ Error] larki_char_session_obj.cpp(7): E2048 Unknown preprocessor directive: 'region' Press F1 on it. the opening page of ms-help://borland.bds5/bds5win32guide/html/errbaddirect.htm is containg a list of valid preprocessor directives define else endif if ifdef ifndef include line pragma undef , but the link is missed from to their pages.

QC #: 39535 - Status: Closed

QC #: Project Date Reported: Area: 39535 Delphi 1/29/2007 IDE\Build Tools Description Steps:[QC Short Description] MSBuild: Warnings and Hints both show up as DCC Warning [QC Description] When using MSBuild, Warnings and Hints thrown by the dcc compiler both show up as [DCC Warning] in the Build tab of the messages window. QC Entry 39535

Enable MsBuild Get some files that generate hints and warnings. Even use the $MESSAGE directive Compile Exp: The build tab shows Warning for warnings and Hint for hints at the beginning of each line respectively Act: They all show as DCC Warning

QC #: 39577 - Status: Closed

QC #: Project Date Reported: Area:

39577 C++Builder 1/29/2007 Documentation\IDE Help Contexts

Description Steps:[QC Short Description] Inaccurate and incomplete documentation for C++ new operator names [QC Description] The bcc32 compiler now supports use of the new compiler names: and and_eq bitand bitor compl not not_eq or or_eq xor xor_eq in C++ by setting the -Vn switch, but the help provided for these operators is inacurate and incomplete. Help provided appears to be from two sources: 1) Help from the Dinkumware library such as: ms-help://borland.bds5/dnk_cpp_help/iso646/xor.html which is documentation for including a header which defines macros to supply the new operators - not a good approach when the keywords are natively

File | New | Console Application - C++ Project | Options | C++ Compiler | C++ Compatibility Check Enable new operator names...(-Vn) Ok insert the following line into the .cpp file: and and_eq bitand bitor compl not not_eq or or_eq xor xor_eq Invoke F1 help for each of the operator names - no accurate and complete help found Look up each in the help index - same result - only MS and Dinkumware help

available from the compiler. 2) Help from MS Vissual Studio, such as ms-help://borland.bds5/vclang/html/_pluslang_Bitwise_Exclusive_OR_Operator.htm which includes the inacurate statement: "There are two ways to access the xor operator in your programs: include the header file iso646.h, or compile with the /Za (Disable language extensions) compiler option." Neither of the two ways is the correct way to do so with the Borland compiler - the first method refers to the Dinkumware macros and the second to a switch for the ms compiler. QC Entry 39577

QC #: 40122 - Status: Closed

QC #: Project Date Reported: Area: 40122 Delphi 2/7/2007 IDE\Code Editor Description Steps:[QC Short Description] "Use Unit" adds unit name to wrong location [QC Description] A unit selected from the "Use Unit" dialog is inserted inappropriately when the USES already exists, but with nothing declared after it. QC Entry 40122

1. Start IDE 2. Create new VCL Forms project 3. Add a second unit (in PM, right click on the exe, Add New, Unit) 4. Switch back to unit1 5. Double click on the form to create a FormCreate event handler 5. Press Alt+F11 and select unit2 -> uses clause correctly added 6. Now clear the "unit2" which was just added, so it only reads "uses" without any names nor a semicolon 7. Press Alt+F11 again and try to add unit2 exp: implementation uses clause should be fixed so it reads "uses Unit2;" again act: "Unit2" is added inside the FormCreate handler, like this: procedure TForm1, Unit2.FormCreate(Sender: TObject); begin end;

QC #: 40262 - Status: Closed

QC #: Project Date Reported: Area: 40262 Delphi 4/20/2009 IDE\History View Description Steps:[QC Short Description] Switch plus and minus signs in "diff" window [QC Description] In the "diff" window, the plus and minus signs are exactly backwards and should be switched. Like in other diff tools, plus should mean "line added" and minus "line deleted", not the other way around. QC Entry 73169 also QC Entry 40262

- click the History tab. - Click the Diff tab at the bottom of the History Manager. - The Differences From and To panes at the top of the page shows the file versions that you can compare. - Select the different file versions in both the Differences From pane and the To pane to see the results in source viewer. - At the bottom of the page, source lines that were deleted are highlighted and marked with a PLUS sign - Lines that were added are highlighted and marked with a MINUS sign it should be the other way around. Documentation is correct on this issue: "To compare file versions using the Diff page Using the file that you created in the previous procedure, click the History tab. Click the Diff tab at the bottom of the History Manager. The Differences From and To panes at the top of the page shows the file versions that you can compare.

At the bottom of the page, source lines that were deleted are highlighted and marked with a minus sign ( ). Lines that were added are highlighted and marked with a plus sign (+). The highlighting colors depend on the Code Editor colors. Select the different file versions in both the Differences From pane and the To pane to see the results in source viewer."

QC #: 40422 - Status: Closed

QC #: Project Date Reported: Area: 40422 Delphi 2/12/2007 Debugger\CPU Description Steps:[QC Short Description] Add ability to close CPU window after program was reset. [QC Description] Add ability to close CPU window after program was reset. When I debug program very often I need CPU view. And very ofren I press Ctrl+F2 when I'm in CPU view. It will be really nice to close CPU view, because it doesn't have any usefull information after program was reset. QC Entry 40422

1. Create new project and press F7 to start debugging. 2. press Ctrl+Alf+C to open CPU window. 3. Press Ctrl+F2 to reset program 4. It will be really nice to close CPU window like in Delphi 6. It doesn't contain any usefull information.

QC #: 40663 - Status: Closed

QC #: Project Date Reported: Area: 40663 Delphi 2/15/2007 IDE\File Handling Description Steps:[QC Short Description] Exception on opening BDS2006 bdsproj files with Read-Only .DPR file [QC Description] If the .DPR file associated with a .BDSPROJ (BDS2006 project) has the READ-ONLY file-attribute set, when you try to open the Project (.bdsproj) in Spacely for the *first time* (as it tries to convert project to new format), you will get this "Exception has been thrown by the target of an invocation." error message. This is *reproducible*. Also, has been confirmed by a couple other people. QC Entry 40663

Steps to reproduce. 1) begin with any D2006 project (e.g., MyProjectName.bdsproj) that has not already been opened with Spacely. Set the associated .dpr file atribute to Read-Only. 2) run Spacely 3) file...open project... (MyProjectName.bdsproj) ==> results in error EXPECTED result: Present the user with a message stating something to the effect of "Sorry, cannot upgrade project file with .DPR that is Read-Only" instead of a cryptic unhandled exception. ACTUAL RESULT (ERROR MESSAGE): "Exception has been thrown by the target of an invocation.", and this comes with the following details: + $43[00355C12]{rtl100.bpl } Classes.Classes.TFileStream.Create (Line 5486, "common\Classes.pas" + 11) + $43 + $B[00355AD0]{rtl100.bpl } Classes.Classes.TFileStream.Create (Line 5468, "common\Classes.pas" + 2) + $B + $B[004094BE]{vcl100.bpl } Graphics.Graphics.TGraphic.LoadFromFile (Line 3724, "Graphics.pas" + 1) + $B + $4[20A1AA69]{coreide100.bpl} ObjectRepos.ObjectRepos.TBaseRespositoryItem.LoadCategory (Line 747, "ObjectRepos.pas" + 5) + $4 + $4[20A1ACA9]{coreide100.bpl} ObjectRepos.ObjectRepos.TBaseRespositoryItem.LoadIcon (Line 785, "ObjectRepos.pas" + 4) + $4 + $50[20A1E3BC]{coreide100.bpl} Template.Template.DefaultAddProjectToRepository (Line 201, "Template.pas" + 31) + $50 + $A2[20A18962]{coreide100.bpl} ObjectRepos.ObjectRepos..TObjectRepository + $A2 + $12[20A1906C]{coreide100.bpl} ObjectRepos.ObjectRepos.TObjectRepository.LoadRepository (Line 281, "ObjectRepos.pas" + 12) + $12 + $8[20A22957]{coreide100.bpl} Gallery.Gallery.LoadWizards (Line 554, "Gallery.pas" + 16) + $8 + $11[20B022A5]{coreide100.bpl} PaletteNewItems.PaletteNewItems.TToolPaletteNewItems.DrawImage (Line 315, "PaletteNewItems.pas" + 0) + $11 + $1D[20B02609]{coreide100.bpl} PaletteNewItems.PaletteNewItems.TToolPaletteNewItems.LoadNewItems (Line 384, "PaletteNewItems.pas" + 25) + $1D + $44[20B01FE3]{coreide100.bpl} Pa

QC #: 40798 - Status: Closed

QC #: Project Date Reported: Area: 40798 Delphi 2/18/2007 RTL\Delphi\DateUtils Description Steps:[QC Short Description] Many of the functions in DateUtils.PAS are ideal candidated for inlining [QC Description] The large majority of the function in DateUtls.PAS are 1 or 2 line pascal function which compile into just a few bytes if code. Converting these functions into inline functions should greatly improved their performance with little or no increase in code size (in many case the code size should actually reduce) Listed in Steps are 133 functions in this unit that should benefit from inlining. QC Entry 40798

Add an inline directive to the following function declarations DateOf TimeOf IsInLeapYear IsPM IsValidDate IsValidTime IsValidDateTime IsValidDateMonthWeek IsValidDateDay IsValidDateWeek DaysInYear DaysInMonth DaysInAMonth WeeksInYear WeeksInYear Today Yesterday Tomorrow IsToday IsSameDay YearOf MonthOf WeekOf DayOf HourOf MinuteOf SecondOf MilliSecondOf StartOfTheYear EndOfTheYear StartOfTheMonth EndOfTheMonth StartOfTheWeek EndOfTheWeek StartOfTheDay EndOfTheDay StartOfAYear EndOfAYear StartOfAMonth EndOfAMonth StartOfAWeek EndOfAWeek StartOfADay EndOfADay MonthOfTheYear WeekOfTheYear DayOfTheYear HourOfTheYear MinuteOfTheYear SecondOfTheYear MilliSecondOfTheYear WeekOfTheMonth DayOfTheMonth HourOfTheMonth MinuteOfTheMonth SecondOfTheMonth MilliSecondOfTheMonth DayOfTheWeek HourOfTheWeek MinuteOfTheWeek SecondOfTheWeek MilliSecondOfTheWeek HourOfTheDay MinuteOfTheDay SecondOfTheDay MilliSecondOfTheDay MinuteOfTheHour SecondOfTheHour MilliSecondOfTheHour SecondOfTheMinute MilliSecondOfTheMinute MilliSecondOfTheSecond WithinPastYears WithinPastMonths WithinPastWeeks WithinPastDays WithinPastHours WithinPastMinutes WithinPastSeconds WithinPastMilliSeconds YearsBetween MonthsBetween WeeksBetween DaysBetween HoursBetween MinutesBetween SecondsBetween MilliSecondsBetween SpanOfNowAndThen YearSpan MonthSpan WeekSpan DaySpan HourSpan MinuteSpan SecondSpan MilliSecondSpan IncYear IncWeek IncDay IncHour IncMinute IncSecond IncMilliSecond EncodeDateTime DecodeDateTime EncodeDateWeek EncodeDateDay DecodeDateDay EncodeDateMonthWeek TryEncodeDateDay RecodeYear RecodeMonth RecodeDay RecodeHour RecodeMinute RecodeSecond RecodeMilliSecond SameDateTime SameDate SameTime NthDayOfWeek EncodeDayOfWeekInMonth JulianDateToDateTime DateTimeToModifiedJulianDate ModifiedJulianDateToDateTime TryModifiedJulianDateToDateTime DateTimeToUnix UnixToDateTime InvalidDateWeekError InvalidDateDayError InvalidDate

QC #: 40805 - Status: Closed

QC #: Project Date Reported: Area:40805 Delphi 2/18/2007 Documentation\Online Help\Main help

Description Steps:[QC Short Description] Help does not describe if the memory returned by MemAlloc/GetMem/New is cleared to zero [QC Description] Help does not describe if the memory returned by MemAlloc/GetMem/New is cleared to zero. Since this is an important issue because of the differences witrh the old memory manager and the new (FastMM), it should be documented. Delphi 7: AllocMem clears to Zero, GetMem does not. Delphi 2007: All allocation is cleared to Zero. QC Entry 40805

QC #: 41186 - Status: Resolved

QC #: Project Date Reported: Area:41186 Delphi 2/22/2007 Database\DBExpress\TSQLQuery

Description Steps:[QC Short Description] LoadFromFile Method InOp [QC Description] When building database from SQL scripts, using SQLQuery.SQL.LoadFromFile. Data that component recieves is corrupted. Method had worked in D7 Ent. QC Entry 41186

[qa update] TDBXBugsSuite.Native.DB.Test.exe -s:oTestRaid_246230 -or- Build an app with Button, OpenDialog, SQLQuery (dbx) and 2 Memos In the Button's OnClick Event : Select and Load a file into the first Memo (Memo.Lines.LoadFromFile() Load the same file into the TSQLQuery (SQLQuery.SQL.LoadFromFile() Then dump the data from SQLQuery into the second Memo Memo2.Text := SQLQuery.SQL.Text or SQLQuery. or any other way to review data that was loaded. The data is not the same.

QC #: 41216 - Status: Closed

QC #: Project Date Reported: Area:41216 Delphi 2/23/2007 Documentation\Online Help\VCL

Description Steps:[QC Short Description] Some bugs in "Using TIniFile and TMemIniFile" examples [QC Description] ms-help://borland.bds5/bds5win32devguide/html/ucbusingtinifile.htm Delphi example listed there doesn't compile because "TIniFile.Free;" is wrong, should read "Ini.Free;" Also lines "WindowState = wsMaximized else WindowState = wsNormal;" should be "WindowState := wsMaximized else WindowState := wsNormal;" QC Entry 41216

Example code is this: procedure TForm1.FormCreate(Sender: TObject); var Ini: TIniFile; begin Ini := TIniFile.Create( ChangeFileExt( Application.ExeName, '.INI' ) ); try Top := Ini.ReadInteger( 'Form', 'Top', 100 ); Left := Ini.ReadInteger( 'Form', 'Left', 100 ); Caption := Ini.ReadString( 'Form', 'Caption', 'New Form' ); if Ini.ReadBool( 'Form', 'InitMax', false ) then WindowState = wsMaximized else WindowState = wsNormal; finally TIniFile.Free; end; end; procedure TForm1.FormClose(Sender: TObject; var Action TCloseAction) var Ini: TIniFile; begin Ini := TIniFile.Create( ChangeFileExt( Application.ExeName, '.INI' ) ); try Ini.WriteInteger( 'Form', 'Top', Top); Ini.WriteInteger( 'Form', 'Left', Left); Ini.WriteString( 'Form', 'Caption', Caption ); Ini.WriteBool( 'Form', 'InitMax', WindowState = wsMaximized ); finally TIniFile.Free; end; end; It should be like this: procedure TForm1.FormClose(Sender: TObject; var Action: TCloseAction); var Ini: TIniFile; begin Ini := TIniFile.Create( ChangeFileExt( Application.ExeName, '.INI' ) ); try Ini.WriteInteger( 'Form', 'Top', Top); Ini.WriteInteger( 'Form', 'Left', Left); Ini.WriteString( 'Form', 'Caption', Caption ); Ini.WriteBool( 'Form', 'InitMax', WindowState = wsMaximized ); finally Ini.Free; end; end; procedure TForm1.FormCreate(Sender: TObject); var Ini: TIniFile; begin Ini := TIniFile.Create( ChangeFileExt( Application.ExeName, '.INI' ) ); try Top := Ini.ReadInteger( 'Form', 'Top', 100 ); Left := Ini.ReadInteger( 'Form', 'Left', 100 ); Caption := Ini.ReadString( 'Form', 'Caption', 'New Form' ); if Ini.ReadBool( 'Form', 'InitMax', false ) then WindowState := wsMaximized else WindowState := wsNormal; finally Ini.Free; end; end;

QC #: 41696 - Status: Closed

QC #: Project Date Reported: Area: 41696 Delphi 6/10/2008 Midas\TClientDataSet Description Steps:Inserting a large amount of rows into a TClientDataSet gets slower and 1. Run attached test case. This adds 200000 rows to a client dataset.

slower. The customer who reported this in Salesforce case 41696 is not using any back end database.

Observe how the form title updates more slowly as more and more rows are added.

QC #: 41750 - Status: Closed

QC #: Project Date Reported: Area:41750 Delphi 3/3/2007 Documentation\Online Help Description Steps:[QC Short Description] Help Button with no topic in Build Steps Editor [QC Description] The dialog for entering a post build event script has a help button, and it won't find any help. QC Entry 41750

None necessary

QC #: 41816 - Status: Closed

QC #: Project Date Reported: Area: 41816 Delphi 3/4/2007 RTL Description Steps:[QC Short Description] TWideStrings does not strip byte order marker when loading files [QC Description] When saving a Unicode text file with Notepad, a byte order marker is added at the start of the file. When loading the text file, Notepad strips the byte order marker. This is the proper behavior for a Unicode application. TWideStrings however leaves the byte order marker as the first character in the first string. QC Entry 41816

The byte order marker could not be converted into an AnsiString, resulting in the question mark Compile and run the attached application below. See the following output. FAIL #1 SL[0]=?one FAIL The byte order marker could not be converted into an AnsiString, resulting in the question mark program BTS247041; {$APPTYPE CONSOLE} uses SysUtils, WideStrings; var SL: TWideStringList; S: WideString; Counter: Integer; begin Counter := 0; SL := TWideStringList.Create; try SL.LoadFromFile(ExtractFilePath(ParamStr(0)) + 'BTS247041.txt'); if SL[0] = 'one' then Inc(Counter) else WriteLn('FAIL #1 SL[0]=', SL[0]); if SL[1] = 'two' then Inc(Counter)

else WriteLn('FAIL #2 SL[1]=', SL[1]); if SL[2] = 'three' then Inc(Counter) else WriteLn('FAIL #3 SL[2]=', SL[2]); if Counter = 3 then WriteLn('PASS') else WriteLn('FAIL'); finally SL.Free; end; end.

QC #: 41821 - Status: Closed

QC #: Project Date Reported: Area:41821 Delphi 3/4/2007 Documentation\IDE Help Contexts

Description Steps:[QC Short Description] F1 Tool Palette - XPManifest [QC Description] TXPManifest component context help not found. QC Entry 41821

QC #: 41823 - Status: Closed

QC #: Project Date Reported: Area:41823 Delphi 3/4/2007 Documentation\IDE Help Contexts

Description Steps:[QC Short Description] F1 Tool Palette - TShellResources [QC Description] TShellResources not found when selecting component in tool palette and pressing F1 QC Entry 41823

QC #: 41824 - Status: Closed

QC #: Project Date Reported: Area:41824 Delphi 3/4/2007 Documentation\IDE Help Contexts

Description Steps:[QC Short Description] F1 Tool Palette - TDBLookupList [QC Description] No help found when selecting TDBLookupList in Tool Palette QC Entry 41824

QC #: 41829 - Status: Closed

QC #: Project Date Reported: Area:

41829 Delphi 3/4/2007 Documentation\Online Help\VCL

Description Steps:[QC Short Description] TEdit Properties Documentation errors [QC Description] The following properties are missing from the TEdit properties list at ms-help://borland.bds5/delphivclwin32/!!MEMBERTYPE_Properties_StdCtrls_TEdit.html AlignWithMargins Cursor Height HelpContext HelpKeyword HelpType Hint Left Margins Name Tag Width The following are events and is incorrectly listed as properties. OnClick This is OnClick, a member of class TEdit. OnContextPopup This is OnContextPopup, a member of class TEdit. OnDblClick This is OnDblClick, a member of class TEdit. OnDragDrop This is OnDragDrop, a member of class TEdit. OnDragOver This is OnDragOver, a member of class TEdit. OnEndDock This is OnEndDock, a member of class TEdit. OnEndDrag This is OnEndDrag, a member of class TEdit. OnEnter This is OnEnter, a member of class TEdit. OnExit This is OnExit, a member of class TEdit. OnKeyDown This is OnKeyDown, a member of class TEdit. OnKeyPress This is OnKeyPress, a member of class TEdit. OnKeyUp This is OnKeyUp, a member of class TEdit. OnMouseActivate This is OnMouseActivate, a member of class TEdit. OnMouseDown This is OnMouseDown, a member of class TEdit. OnMouseEnter This is OnMouseEnter, a member of class TEdit. OnMouseLeave This is OnMouseLeave, a member of class TEdit. OnMouseMove This is OnMouseMove, a member of class TEdit. OnMouseUp This is OnMouseUp, a member of class TEdit. OnStartDock This is OnStartDock, a member of class TEdit. OnStartDrag QC Entry 41829

QC #: 41830 - Status: Closed

QC #: Project Date Reported: Area:

41830 Delphi 3/4/2007 Documentation\Online Help\VCL

Description Steps:[QC Short Description] TMainMenu Help Errors [QC Description] ms-help://borland.bds5/delphivclwin32/!!MEMBERTYPE_Properties_Menus_TMainMenu.html

The following properties are missing: Items Name Tag The following are listed as properties and should be listed as events OnChange Occurs when the menu changes. QC Entry 41830

QC #: 41831 - Status: Closed

QC #: Project Date Reported: Area:

41831 Delphi 3/4/2007 Documentation\Online Help\VCL

Description Steps:[QC Short Description] TLabel Help Errors [QC Description] ms-help://borland.bds5/delphivclwin32/!!MEMBERTYPE_Properties_StdCtrls_TLabel.html The following properties are missing: Cursor Height elpContext HelpKeyword HelpType Hint Left Margins Name Tag Top Width the following events are incorrectly listed and properties: OnClick This is OnClick, a member of class TLabel. OnContextPopup This is OnContextPopup, a member of class TLabel. OnDblClick This is OnDblClick, a member of class TLabel. OnDragDrop This is OnDragDrop, a member of class TLabel. OnDragOver This is OnDragOver, a member of class TLabel. OnEndDock This is OnEndDock, a member of class TLabel. OnEndDrag This is OnEndDrag, a member of class TLabel. OnMouseActivate This is OnMouseActivate, a member of class TLabel. OnMouseDown This is OnMouseDown, a member of class TLabel. OnMouseEnter This is OnMouseEnter, a member of class TLabel. OnMouseLeave This is OnMouseLeave, a member of class TLabel. OnMouseMove This is OnMouseMove, a member of class TLabel. OnMouseUp This is OnMouseUp, a member of class TLabel. OnStartDock This is OnStartDock, a member of class TLabel. OnStartDrag QC Entry 41831

QC #: 41832 - Status: Closed

QC #: Project Date Area:

Reported:

41832 Delphi 3/4/2007 Documentation\Online Help\VCL

Description Steps:[QC Short Description] TMemo Documentation errors [QC Description] ms-help://borland.bds5/delphivclwin32/!!MEMBERTYPE_Properties_StdCtrls_TMemo.html The following properties are missing: Cursor Height HelpContext HelpKeyword HelpType Hint Left Margins Name tag top width The following are listed as properties and should be listed as Events: OnChange Occurs when the text for the edit control may have changed. OnClick This is OnClick, a member of class TMemo. OnContextPopup This is OnContextPopup, a member of class TMemo. OnDblClick This is OnDblClick, a member of class TMemo. OnDragDrop This is OnDragDrop, a member of class TMemo. OnDragOver This is OnDragOver, a member of class TMemo. OnEndDock This is OnEndDock, a member of class TMemo. OnEndDrag This is OnEndDrag, a member of class TMemo. OnEnter This is OnEnter, a member of class TMemo. OnExit This is OnExit, a member of class TMemo. OnKeyDown This is OnKeyDown, a member of class TMemo. OnKeyPress This is OnKeyPress, a member of class TMemo. OnKeyUp This is OnKeyUp, a member of class TMemo. OnMouseActivate This is OnMouseActivate, a member of class TMemo. OnMouseDown This is OnMouseDown, a member of class TMemo. OnMouseEnter This is OnMouseEnter, a member of class TMemo. OnMouseLeave This is OnMouseLeave, a member of class TMemo. OnMouseMove This is OnMouseMove, a member of class TMemo. OnMouseUp This is OnMouseUp, a member of class TMemo. OnStartDock This is OnStartDock, a member of class TMemo. OnStartDrag This is OnStartDrag, a member of class TMemo. QC Entry 41832

QC #: 42018 - Status: Closed

QC #: Project Date Reported: Area:42018 Delphi 3/6/2007 IDE\Structure Pane\Error Insight

Description Steps:[QC Short Description] Error insight doesn't like case when procedure has variable with the same name as procedure itself. [QC Description] Error insight doesn't like case when procedure has variable with the same name as procedure itself. QC Entry 42018

1. Open IDE and close everything. 2. Open attached project. 3. Open structure window and notice that Error Insight complains about Test local variable. 4. Compile project and you will see that it compiles fine. Function TForm2.Test(Index : Integer) : Boolean; Var Test : Integer; Begin End;

QC #: 42022 - Status: Closed

QC #: Project Date Reported: Area:42022 Delphi 3/6/2007 IDE\Structure Pane\Error Insight

Description Steps:[QC Short Description] Error insight doesn't understand directive without semicolon after it (not before). [QC Description] Error insight doesn't understand directive without semicolon after it (not before). QC Entry 42022 [See also 246175]

1. Open IDE and close everything. 2. Open attached project. 3. Open Error Insight panel. 4. Notice error in error insight panel. 5. Compile project and you will see that project compiles.

QC #: 42144 - Status: Closed

QC #: Project Date Reported: Area:42144 Delphi 3/8/2007 Documentation\Online Help\Main help

Description Steps:[QC Short Description] Index for Refactoring says "introdule field" [QC Description] In the index, if you type "Refactoring", you'll see "introdule field" as an item. Expected: "introduce Field" QC Entry 42144

See description ========================= fixed in 2010 http://docwiki.embarcadero.com/RADStudio/en/Index#R

QC #: 42330 - Status: Closed

QC #: Project Date Reported: Area:42330 Delphi 3/11/2007 RTL\Delphi\Format + Float Description Steps:[QC Short Description] WideFormat incorrectly formats %p specifier [QC Description] If a %p format specifier is included in the format string passed to WideFormat, the resulting string contains invalid characters. The reason for this is a simply copy+paste bug in the WideFormatBuf function at the @CvtPointer label. Instead of calling CvtInt at line 8582 ("JMP CvtInt"), the function CvtIntW must be called. This fixes the problem. QC Entry 42330

Compile and run the attached application below. See the following output. FAIL S=???????? if WideFormat were functioning as expected, S would hold the value '00000000' as it does when String and Format are being used. program BTS248721; {$APPTYPE CONSOLE} uses SysUtils; var S: WideString; begin try S := WideFormat('%p', [Pointer(nil)]); WriteLn('S=', S); if S = WideString('00000000') then

WriteLn('PASS') else Writeln('FAIL S=', S); except on E: Exception do begin WriteLn('FAIL - Exception (', E.ClassName, '/', E.Message, ')'); end; end; end.

QC #: 42461 - Status: Closed

QC #: Project Date Reported: Area: 42461 Delphi 3/12/2007 IDE\Code Editor Description Steps:[QC Short Description] Ctrl-Enter does not work on uses clauses for type library files [QC Description] You can use Find Declaration (from the context menu) and Ctrl-Click, but if you position the cursor in the code editor on the TLB unit name and press Ctrl & Enter, nothing happens. QC Entry 42461

1. Create new Active X library. 2. Add new Active X type library. 3. Add new automation object. 4. Go to the code editor for the automation object. 5. Place cursor on StdVcl in the units clause. 6. Press Ctrl & Enter. 7. Goes to StdVCL unit as expected. 8. Go back to automation object unit. 9. Place cursor on the _TLB unit name 10. Press Ctrl-Enter Expected. Code editor shows the _TLB.pas file (not the type library editor). Actual Nothing happens. Notes: Steps 5,6 & 7 are not required, but are just to show that Ctrl-Enter is normally working.

QC #: 42469 - Status: Closed

QC #: Project Date Reported: Area: 42469 Delphi 3/13/2007 RTL Description Steps:[QC Short Description] Memory leak in masks.pas [QC Description] this code: procedure TForm1.Button1Click(Sender: TObject); begin if MatchesMask('1-2-3', '[123]') then ShowMessage('Mask is valid') end; Has memory leak as result --------------------------------2007/3/13 10:52:34-------------------------------- A memory block has been leaked. The size is: 36

Compile and run the attached application below. See the following message in an error dialog after program run. An unexpected memory leak has occured. The unexpected small block leaks are: 29 -36 bytes: Unknown x 1 program BTS258418; {$APPTYPE CONSOLE} uses Masks, SysUtils;

Stack trace of when this block was allocated (return addresses): 402E86 [system.pas][System][@GetMem][2648] 46B0D1 [Masks.pas][Masks][WriteScan][98] 46B264 [Masks.pas][Masks][ScanSet][145] 46B2E5 [Masks.pas][Masks][InitMaskStates][158] 408827 [FastMM4.pas][FastMM4][CalculateHeaderCheckSum][5758]46B708 [Masks.pas][Masks][TMask.Create][288] 46B7FB [Masks.pas][Masks][MatchesMask][311] 45C9FE [Forms.pas][Forms][GetRealParentForm][1747] 46B9F7 [Unit1.pas][Unit1][TForm1.Button1Click] QC Entry 42469

begin ReportMemoryLeaksOnShutDown := True; try if MatchesMask('1-2-3', '[123]') then WriteLn('We are here') except end; end.

QC #: 42555 - Status: Closed

QC #: Project Date Reported: Area:

42555 Delphi 3/13/2007 Documentation\Online Help\Programmers guide

Description Steps:[QC Short Description] Compiling Applications refers to Kylix [QC Description] ms-help://borland.bds5/devwin32/compilingapplications_xml.html Topic refers to Kylix which is not supported with Spacely (or any longer) QC Entry 42555

QC #: 42556 - Status: Closed

QC #: Project Date Reported: Area:

42556 Delphi 3/13/2007 Documentation\Online Help\Programmers guide

Description Steps:[QC Short Description] Deploying Applications refers to Kylix [QC Description] ms-help://borland.bds5/devwin32/deployingapplicationsoverview_xml.html This topic refers to Kylix which is not supported with Delphi 2007. QC Entry 42556

QC #: 42557 - Status: Closed

QC #: Project Date Reported: Area:

42557 Delphi 3/13/2007 Documentation\Online Help\Programmers guide

Description Steps:[QC Short Description] Understanding the Component Library refers to Kylix

[QC Description] ms-help://borland.bds5/devwin32/pcbunderstandingthevcl_xml.html This topic refers to Kylix which is not supported with Delphi 2007. QC Entry 42557

QC #: 42559 - Status: Closed

QC #: Project Date Reported: Area:

42559 Delphi 3/13/2007 Documentation\Online Help\Programmers guide

Description Steps:[QC Short Description] Objects, Components, and Controls refers to Kylix [QC Description] ms-help://borland.bds5/devwin32/idh_useop_objectscomponentscontrols_xml.html This topic refers to Kylix which is not supported in Delphi 2007. QC Entry 42559

QC #: 42560 - Status: Closed

QC #: Project Date Reported: Area:

42560 Delphi 3/13/2007 Documentation\Online Help\Programmers guide

Description Steps:[QC Short Description] TObject Branch refers to Kylix [QC Description] ms-help://borland.bds5/devwin32/pcbthetobjectbranch_xml.html This topic refers to Kylix which is not supported in Delphi 2007. QC Entry 42560

QC #: 42561 - Status: Closed

QC #: Project Date Reported: Area:

42561 Delphi 3/13/2007 Documentation\Online Help\Programmers guide

Description Steps:[QC Short Description] TPersistent Branch refers to Kylix [QC Description] ms-help://borland.bds5/devwin32/pcbthetpersistentbranch_xml.html Topic refers to Kylix which is not supported in Delphi 2007. QC Entry 42561

QC #: 42562 - Status: Closed

QC #: Project Date Reported: Area:

42562 Delphi 3/13/2007 Documentation\Online Help\Programmers guide

Description Steps:[QC Short Description] TControl Branch refers to Kylix [QC Description] ms-help://borland.bds5/devwin32/pcbthetcontrolbranch_xml.html Topic refers to Kylix which is not supported in Delphi 2007. QC Entry 42562

QC #: 42563 - Status: Closed

QC #: Project Date Reported: Area:

42563 Delphi 3/13/2007 Documentation\Online Help\Programmers guide

Description Steps:[QC Short Description] TWinControl/TWidgetControl Branch refers to Kylix [QC Description] ms-help://borland.bds5/devwin32/pcbthetwincontrolbranch_xml.html Topic refers to Kylix which is not supported in Delphi 2007. QC Entry 42563

QC #: 42622 - Status: Closed

QC #: Project Date Reported: Area:42622 Delphi 3/14/2007 Documentation\Online Help Description Steps:[QC Short Description] OpenTools API Topics [QC Description] Would like to get the OpenTools API topics into Delphi 2007. QC Entry 42622

QC #: 42815 - Status: Closed

QC #: Project Date Reported: Area: 42815 Delphi 3/19/2007 RTL\Delphi\Other RTL Description Steps:[QC Short Description] THelpManager.DoTableOfContents may leave Viewer uninitialized [QC Description]

(1) Set up an empty project (2) In the DPR file, add uses HtmlHelpViewer; (3) In the DPR file, specify the help file: Application.HelpFile := ExtractFilePath(ParamStr(0))+'EyeWare.chm'; (4) From the main form, invoke the help file (5) Watch the help file

The logic in THelpManager.DoTableOfContents (HelpIntfs.pas) for ViewerNames.Count = 1 is flawed since it calls ShowTableOfContents directly and leaves the Viewer variable uninitialized. Since Viewer is accessed at the end of the method this might cause an exception! QC Entry 42815

open correctly (6) Witness the annoying (spurious) exception due to the coding error

QC #: 42969 - Status: Closed

QC #: Project Date Reported: Area: 42969 Delphi 3/21/2007 IDE\Code Editor Description Steps:[QC Short Description] Editor looses focus when Alt-Tabbing to another app, then back [QC Description] When using the Classic Undocked layout, the editor will loose the focus when switching to another application and back. QC Entry 42969

1. Start Delphi 2007 and switch to Classic Undocked layout (no need to change to non-embedded designer) 2. make sure another application is running, otherwise start e.g. notepad 3. Create a new project and switch to the code editor (unit1.pas or project1.dpr etc.) 4. Alt+Tab to another application 5. Alt+Tab back to the IDE exp: code editor should have the focus act: layout combobox in the toolbar of the IDEs main form has the focus This problem occurs regardless of how you switch the other application, i.e. clicking on the taskbar button of the other app then the IDE also produces this problem

QC #: 42974 - Status: Closed

QC #: Project Date Reported: Area:42974 Delphi 3/21/2007 IDE\Dialogs\Environment Options

Description Steps:[QC Short Description] Improve Tools, Options UI (allow dialog to resize or other UI changes) [QC Description] I've listed all of the options areas of the Tools Options dialog that I consider more difficult to use because the UI seems cramped inside the existing smallish dialog. I believe an alternate UI for those areas of the settings, or allowing this dialog to resize would make this dialog more usable. The first 4(*) items in the list would give me a significant benefit, because I believe developers use them more frequently. Tools (Environment) Options (Ignoring Together) ------------------------------------------------------------------------------ Significant Benefit (central portion could resize, less scrolling, etc.): - Library Win32 (path lists)* - Environment Variables (variable lists)* - Color (syntax preview)* - Language Exceptions (exception list)* - Native OS Exceptions (exception list) - Event Log (color listbox very cramped) Minor Benefit: - Environment Options (paths) - Object Inspector (color listbox) - Explorer (explorer categories) - CodeGear Debuggers (paths) Little/No Benefit: - Tool Palette - Colors - Type Library - VCL Designer - Editor Options - Source Options (could resize, but large enough now) - Display

Start Delphi 2007 Tools, Options Click around in the options tree and notice some ot the options screens seem cramped in the existing small dialog (see the list in the Description for details) I've attached screenshots of how this dialog looks once it is made resizable, and I think the results are nicer

- Key mappings (could resize, but large enough now) - Code Insight - Debugger Options I'm happy to accept a better/alternate UI instead of resizing, if CodeGear can come up with one that performs the same function in less space, but resizing is the bet option I've imagined so far. QC 9751 kind of requested this (in the title at least), but was marked as a duplicate of an only vaguely related bug. QC Entry 42974

QC #: 43077 - Status: Closed

QC #: Project Date Reported: Area: 43077 Delphi 3/23/2007 RTL\Delphi\Other RTL Description Steps:[QC Short Description] FMTBCD.MoveBytesToRight - in-argument should be const [QC Description] MoveBytesToRight has an input argument, BcdIn, of type TBcd, which is never changed by the procedure, but since it isn't marked with const, the compiler emits code to copy the argument locally, which is unnecessary. QC Entry 43077

QC #: 43080 - Status: Closed

QC #: Project Date Reported: Area: 43080 Delphi 3/23/2007 RTL\Delphi\Other RTL Description Steps:[QC Short Description] WideStrUtils.inOpSet has sub-optimal code [QC Description] The unit-private function inOpSet in WideStrUtils takes as its second argument a CharSet. This 32-byte parameter is never modified, and thus marking it const will prevent the compiler from emitting code to copy the parameter unnecessarily. QC Entry 43080

QC #: 43360 - Status: Closed

QC #: Project Date Reported: Area: 43360 Delphi 3/28/2007 IDE\History View Description Steps:[QC Short Description] Painting problem in History View [QC Description] When following the steps shown below the Diff view of the History view feature remains blank, indicating a painting problem. See attached screenshot. QC Entry 43360

1. Start IDE 2. Create new VCL Forms project 3. Save all 4. Switch to dpr with Project, View Source 5. Make some non-sense modifications to it and save inbetween for say 5 times 6. Switch to the History View (tab at bottom) 7. Activate that Diff View (another set of tabs at the bottom) 8. In the "From" list, select an older revision, e.g. ~2~ 9. In the "To" list, select "~3~" 10. Now click "~3~" in the "To" list again

exp: differences between those revisions should be shown act: empty diff view only showing "1" in the gutter is shown

QC #: 43408 - Status: Closed

QC #: Project Date Reported: Area: 43408 Delphi 3/28/2007 Documentation Description Steps:[QC Short Description] non stream file IO not in help [QC Description] Assignfile, rewrite, append, reset and system.closefile are not found in help when pressing F1, they do not appear in the index either. QC Entry 43408

var afile : file;] astring : string; begin assignfile(afile,'c:\test'); rewrite(afile); writeln(afile,'test'); reset(afile); readln(afile,astring); append(afile); writeln(afile,'test2'); closefile(afile); end; Actual: highlight any of the functions Assignfile, rewrite, reset, append,closefile (a closefile function is found under the IFileIsInUse but thats not the one in question) expected: Many people still use this IO method as its simple for beginners, and with no docs, its hard for them to follow.

QC #: 44557 - Status: Closed

QC #: Project Date Reported:

Area:

44557 C++Builder 4/17/2007 IDE\Build Tools

Description Steps: [QC Short Description] Custom build steps for idl files (or other specific files) [QC Description] For building ACE/TAO/CIA O we do to compile idl files (corba interface definition) with tao_idl. The idl files must be compiled with a customer commadnline and has certain output that depends on it. Below the info like we specifiy this with vs2005, we need something like this for bcb2007 Name="VCCustomBuildTool" Description="Invoking ..\..\bin\tao_idl on BooleanSeq.pidl" CommandLine="PATH=%PATH%;..\..\lib ..\..\bin\tao_idl -Wb,pre_include=ace/pre.h -Wb,post_include=ace/post.h -I.. -Wb,versioning_begin=TAO_BEGIN_VERSIONED_NAMESPACE_DECL -Wb,versioning_end=TAO_END_VERSIONED_NAMESPACE_DECL -SS -Sorb -GA -Gp -Gd -oA AnyTypeCode -Wb,export_macro=TAO_Export -Wb,export_include=tao/TAO_Export.h -Wb,anyop_export_macro=TAO_AnyTypeCode_Export -Wb,anyop_export_include=tao/AnyTypeCode/TAO_AnyTypeCode_Export.h -Sci -Gse "BooleanSeq.pidl"" AdditionalDependencies="..\..\bin\tao_idl.exe" Outputs="AnyTypeCode\BooleanSeqA.cpp;AnyTypeCode\BooleanSeqA.h;BooleanSeqC.cpp;BooleanSeqC.h;BooleanSeqS.h"/> QC Entry 44557

try to have a customer idl file that needs to be compiled using an externa tool which results in cpp files

QC #: 44636 - Status: Closed

QC #: Project Date Reported: Area:44636 Delphi 4/18/2007 IDE\Code Editor\Help Insight Description Steps:[QC Short Description] Internal IDE errors when Tooltip Help Insight is disabled. [QC Description]

Test Case 1: 1) Ensure Tooltip Help Insight is disabled in the Tools -> Options -> Editor Options -> Code Insight menu 2) Open the attached file MyUnit1.pas 2b) Ensure Messages pane is shown by right-clicking editor and clicking Messages if not currently visible; 3) Click on the

When Tooltip Help Insight is disabled some code constructs cause the IDE to report internal errors when the mouse pointer is hovered over it. Attached are two units that cause such errors when the mouse pointer is hovered over the text labeled "hovermousehere". See "Steps" for more detail. QC Entry 44636

editor so it has the keyboard focus 4) Hover the mouse pointer over the text "hovermousehere" on line 6 5) Wait a couple of seconds Expected: Nothing happens Actual: [Error] MyUnit1.pas(6): E2029 ',' or ')' expected but 'kibitz point' found Test Case 2: 1) Ensure Tooltip Help Insight is disabled in the Tools -> Options -> Editor Options -> Code Insight menu 2) Open the attached file MyUnit2.pas 2b) Ensure Messages pane is shown by right-clicking editor and clicking Messages if not currently visible; 3) Click on the editor so it has the keyboard focus 4) Hover the mouse pointer over the text "hovermousehere" on line 9 5) Wait a couple of seconds Expected: Nothing happens Actual: [Fatal Error] MyUnit2.pas(8): F2084 Internal Error: AV21BDF601-R00000000-0

QC #: 44938 - Status: Closed

QC #: Project Date Reported: Area:44938 Delphi 4/24/2007 Documentation\Online Help\VCL

Description Steps:[QC Short Description] Get back the categorized list of functions [QC Description] The categorized list of functions/routinnes/procedures were a very interesting thing to bring back. Sometimes you need a string function and have to remember which unit(s) its located the functions (in the example, string functions are scattered in SysUtils and StrUtils). If a function have to be in two categories, put a link in both categories.QC Entry 44938

QC #: 45300 - Status: Closed

QC #: Project Date Reported: Area:45300 Delphi 5/1/2007 Documentation\IDE Help Contexts

Description Steps:[QC Short Description] Automated Incident Report [QC Description] No help found for (none) No help topic for MessageDlg QC Entry 45300

Press CTRL-F1 over the word 'MessageDlg'

QC #: 45750 - Status: Closed

QC #: Project Date Reported: Area: 45750 Delphi 5/10/2007 VCL\Graphics Description Steps:[QC Short Description] Exception in TJPEGImage.GetBitmap when jpeg image have 1 pixel height. [QC Description] have problem with converting jpeg image to bitmap when height of jpeg equal 1 pixel (use TJPEGImage object, JPEG.PAS) QC Entry 45750

1.JPEGImage.LoadFromStream(Stream); 2.Bitmap.Assign(JPEGImage.Bitmap); when image have height = 1pixel have AV on TJPEGImage.GetBitmap function

QC #: 45861 - Status: Closed

QC #: Project Date Reported: Area: 45861 Delphi 5/11/2007 Documentation Description Steps:[QC Short Description] ComObj.TClassInstancing Enumeration is not documented [QC Description] The TClassInstancing enumeration is not document. ms-help://borland.bds5/delphivclwin32/ComObj_TClassInstancing.html QC Entry 45861

Run help Navigate to the following URL: ms-help://borland.bds5/delphivclwin32/ComObj_TClassInstancing.html

QC #: 45883 - Status: Closed

QC #: Project Date Reported: Area: 45883 C++Builder 5/13/2007 IDE\File Handling Description Steps:[QC Short Description] Cannot save a cpp file with a space in its name [QC Description] If you attempt to save a cpp file with a name that has a space in it e.g. "Fred Blogs.cpp" you get the following error: "'Fred Blogs' is not a valid identifier. Filenames must be a valid identifier in order to generate a correct header guard" 1) The message is unintelligible Why not say that you cannot have a space in the filename? 2) The interface should correct the "error" automatically, by replacing the space with an underscore Filenames become: "Fred_Blogs.cpp" and "Fred_Blogs.h" Header guard becomes: Fred_BlogsH QC Entry 45883

1. Create a new Unit 2. Attempt to save it as "Fred Blogs"

QC #: 46096 - Status: Closed

QC #: Project Date Reported: Area: 46096 C++Builder 5/16/2007 IDE\File Handling Description Steps:[QC Short Description] Enable to overwrite readonly file if user requires so. QC Entry 46096

1. Open a readonly .cpp or .h file 2. Right click in code editor, uncheck "Read Only" item 3. Edit the file 4. Save it. Observation: An error message saying the file is read only. Suggestion: When user explicitely removes "Read Only", IDE should smartly ask if user wants to overwrite, instead of popping up an error. Otherwise, user has to go to Windows Explorer, find that file and remove "Read Only" attribute once again. This is inconvenience, especially if a source control system (e.g., CVS) makes all files read only after checking in. Alternatively, it's also ok to disable "Read Only" menu in this case.

QC #: 46216 - Status: Closed

QC #: Project Date Reported: Area: 46216 C++Builder 5/18/2007 Documentation Description Steps:[QC Short Description] Constructors are missing [QC Description] The online documentation does not contain information about the VCL class constructors (e.g. TPen) QC Entry 46216

QC #: 46483 - Status: Closed

QC #: Project Date Reported: Area:46483 Delphi 10/16/2004 IDE\Refactoring\Extract Method

Description Steps:If I select a begin/end block to be extracted, the redundant begin/end are included in the generated method. The extracted method call is not properly indented as well. [D10 : 10.0.1916.8244 : true ]

1. Create a new W32 VCL application 2. Paste the following code in the FormCreate event: procedure TForm1.FormCreate(Sender: TObject); begin if Tag > 0 then begin Caption := ''; Enabled := False; end; end; 3. Place the cursor in the "begin" line following the if statement, so that the cursor is at the start of the 'begin' (or further right). 4. Invoke "Extracted Method". Exp: The two statements setting Caption and Enabled should be extracted to a new method, and the redundant begin/end removed. The extracted method call indentation should be correct. Act: The following code is generated. Notice the redundant begin/end inside the extracted method and the bad indentation on the ExtractedMethod call. procedure TForm1.FormCreate(Sender: TObject); begin if Tag > 0 then ExtractedMethod; end; procedure TForm1.ExtractedMethod; begin begin Caption := ''; Enabled := False; end; end;

QC #: 46805 - Status: Closed

QC #: Project Date Reported: Area: 46805 C++Builder 5/30/2007 ActiveX\IDE Description Steps:[QC Short Description] Add a menus option to allow registration and unregistration for COM objects [QC Description] There has never been a menu item but it would be a great feature. if these parameters /regserver and /unregserver are added as menu commands to the IDE menu. Would be very usefull to facilitates fast tetting issues QC Entry 46805

Add /regserver and /unregserver menu commands to allows easy registration and unregistration of DCOM objects.

QC #: 46812 - Status: Closed

QC #: Project Date Reported: Area:46812 Delphi 5/30/2007 Documentation\Online Help Description Steps:[QC Short Description] TListSortCompare not described [QC Description] TListSortCompare is included but not described in the help. The help for TListSortCompare is correct in D5 but is incorrect in D6 and D7. It is not included in the help for D9 or D10. QC Entry 46812

Search for TListSortCompare in the BDS 2007 help.

QC #: 46861 - Status: Closed

QC #: Project Date Reported: Area: 46861 Delphi 5/31/2007 Debugger Description Steps:[QC Short Description] IDE Can't execute the compiled exe when the project output path is the root of a hidden share [QC Description] IDE Can't execute the compiled exe when the project destination path contains hidden share QC Entry 46861

Create a new Delphi for Win32 Application Open the project options dialog box Fill the Output path with a remote path having an hidden share : \\192.168.3.134\DebugApp$ for example ----Instructions for creating a hidden share can be found at: http://support.microsoft.com/kb/314984 ----It looks like on XP, you can use \\hostname\c$ Run the Project Act : The run attempt ended wih an exception : Could not find program \\192.168.3.134\DebugApp\MyApp.exe See the missing '$' from the error message Exp : Should run the project

QC #: 47676 - Status: Closed

QC #: Project Date Reported: Area:47676 C++Builder 6/18/2007 IDE\Dialogs\Customize toolbar

Description Steps:[QC Short Description] File | New | VCL Forms App - C++

Flicker after adding "Build Unit" on toolbar [QC Description] BDS2006, CB2007 1) If I add "Project->Build Unit" I see endless flicker of toolbar. It stops only after removing this button. QC Entry 47676 Added by Sysop <<<<<<<<<<<<<<<<<<< Bug still occurs in C++ Builder 14.0.3593.25826 >>>>>>>>>>>>>>>>>>>

Right-click toolbar for context menu Open 'Customize' dialog. Click on Commands Tab Move button "Project->Build Unit" onto toolbar. Close 'Customize' dialog. Observe flicker.

QC #: 47745 - Status: Closed

QC #: Project Date Reported: Area:47745 Delphi 6/19/2007 IDE\Code Editor\Error Insight Description Steps:[QC Short Description] Error insight doesn't see ancestor class if it is _strict private_ [QC Description] 1) SITUATION =========== In this source code <code> unit Unit1; interface type TClassA = class strict private type TClassB = class abstract(TObject) end; TClassC = class public type TClassC = class sealed(TClassB) end; end; end; implementation end. </code> error insight engine doesn't see TClassB in TClassC declaration. Therefore in declaration public <code> type TClassC = class sealed(TClassB) </code> class TClassB is red underlined 2) MY INVESTIGATION =================== As i can see key point is in usage of _strict private_ key word. If line <code> strict private type </code> change to

1) Create new unit with name Unit 1 2) Copy-past this source code <code> unit Unit1; interface type TClassA = class strict private type TClassB = class abstract(TObject) end; TClassC = class public type TClassC = class sealed(TClassB) end; end; end; implementation end. </code> 3) Expected behaviour: there is no red lines Actual behaviour: in declaration <code> public type TClassC = class sealed(TClassB) </code> class TClassB is red underlined

<code> private type </code> then everything is ok. QC Entry 47745

QC #: 48132 - Status: Closed

QC #: Project Date Reported: Area:48132 Delphi 6/26/2007 Documentation\Online Help Description Steps:[QC Short Description] Help topic for "transfer macro" is missing [QC Description] customer reported that the missing topic for "transfer macro". This help topic is available in Delphi7/BCB6, so just port the contents from Delphi7/BCB6. [BCB6HELP] [D7HELP] QC Entry 48132

1. Search help topic for "transfer macro" // in Delphi7/BCB6, it is available // in highlander, the topic is not available.

QC #: 48308 - Status: Closed

QC #: Project Date Reported: Area: 48308 Delphi 6/29/2007 IDE\File Handling Description Steps:[QC Short Description] Automated Incident Report [QC Description] 'C:\Work\namedpipes\ServerMain.dfm' is a read-only file. Both autosave options enabled, open a complete readonly project except for a .dfm and try to F9 it. This report continues the 41145. Handling readonly .dfm became better but still not there, IMO. QC Entry 48308

Use a small project to demo this stuff, one that uses at least one form (so it has a .dfm) and it is of course already a Delphi 2007 project so it won't need conversion when opened. Make sure you have both AutoSave options enabled (editor+desktop) 1. mark all the files used in the project READONLY, except for a .dfm file and .dproj file 2. now open the project and make some minor change to the source file (.pas) coresponding to the .dfm 3. compile or build the project 4. hit Run expected: .pas file gets saved and project should run actual: .pas file gets saved, plus, you get an error box saying the .dfm file is readonly ... and the worst thing: project does NOT run, and it won't run in the IDE unless you disable the Autosave for editor files. For example the biggest problem is: In the project above, after I changed the .pas file, if the .dfm is readonly I am NOT able to close the project and work something else. Practically you get stuck in the loop Close (or Close All) and the exception box, that's when you answer Yes to the question about saving the project. Well, I maybe changed options for the project and want them saved, so I answer Yes. Thus I can not close the project because it fails on the readonly .dfm (as a workaround I can say No, the second time IDE asks about saving the project - but than, if it did save the project first time, why does it ask again?...)

QC #: 48603 - Status: Closed

QC #: Project Date Reported: Area:48603 Delphi 7/5/2007 Documentation\Online Help\Main help

Description Steps:[QC Short Description] Index to "records (advanced), records and records (traditional)" wrong

Start help search for "records" locate "records (advanced)" Note that the order is: records (advanced) records records (traditional) I

[QC Description] There is this in the help index: records (advanced) records records (traditional) I guess it should be records records (traditional) records (advanced) Also, both "records" and "records (traditional)" link to "structured types", and not the the corresponding subtopics. There are subtopics for "records (traditional)" and "records (advanced)", and I guess theyshould be linked to, from the index QC Entry 48603

expected: records records (traditional) records (advanced) Click on "records" or "records (advanced)". exp: subtopic "records (traditional)" or "records (advanced)" is opened act: topic "structured types" is opened, at the top.

QC #: 48645 - Status: Closed

QC #: Project Date Reported: Area: 48645 C++Builder 7/6/2007 IDE\File Handling Description Steps:[QC Short Description] IDE doesn't detect that the main project source file is modified in an external application [QC Description] The IDE sometimes fails to detect that a file has been modified in an external application. QC Entry 48645

Create a new project, select VCL Forms Application Save the project (as project1.cbproj) for instance. Open the project1.cpp file in the IDE Edit the file project1.cpp in an external editor, save it. The IDE doesn't detect that the file is modified. If I instead opens the unit1.cpp file, edits it in an external editor, then the IDE detects this change, but it fails for the main source file.

QC #: 48767 - Status: Closed

QC #: Project Date Reported: Area:48767 C++Builder 7/9/2007 IDE\Project Management\Project Manager

Description Steps:[QC Short Description] Better troubleshooting help with make/build issues. [QC Description] For trouble shooting build/make issues, consider adding one of the following features: 1) Show the current target/file being worked on in the message pane. (For example, if a compilation error occurs in a header file, the message in the messages pane indicates the header file name, but not the C++/C source file name that is including the header; if the problem is the result of the order of #include's in the source file, how can you find the file that needs to be modified?). 2) Add an extra pane to the project options dialog for viewing the full command line arguments applied for a tool (full project options) (similar to what appears in VC) or to a file (local project options). 3) Generate a makefile equivalent from an IDE project (this is the old BC IDE way of doing things; unfortunately, this utility often failed to keep up with new features added to the IDE). QC Entry 48767

QC #: 48976 - Status: Closed

QC #: Project Date Reported: Area: 48976 Delphi 7/12/2007 IDE\Open Tools API Description Steps:[QC Short Description] The EditIntf.pas and FileIntf.pas units should be marked deprecated [QC Description] The units EditIntf.pas and FileIntf.pas are not marked deprecated. Other units such as ExptIntf.pas, ToolIntf.pas, and VirtIntf.pas that are part of the old non-interface based OTA are marked deprecated. The fix is to add deprecated to the unit headers as in ToolIntf.pas: unit ToolIntf deprecated; interface ...... QC Entry 48976

have a look at the *Intf.pas files (except TreeIntf.pas) in source\ToolsAPI

QC #: 49166 - Status: Closed

QC #: Project Date Reported: Area:49166 Delphi 7/17/2007 IDE\Code Editor\Error Insight Description Steps:[QC Short Description] Error Insight doesn't recognize that SeekEOLN and SeekEOF are boolean function [QC Description] Error Insight flags SeekEOLN or SeekEOF with the error "Type of expression must be BOOLEAN" even though these are functions returning a boolean result. QC Entry 49166

The following unit will have these two functions marked as errors, even though the compiler accepts them: unit Unit1; interface implementation begin repeat until seekeoln(); repeat until seekeof(); end.

QC #: 49230 - Status: Closed

QC #: Project Date Reported: Area:49230 C++Builder 7/18/2007 Compiler\C++\Front End\Language

Description Steps:[QC Short Description] nested structure in template with duplicate function name broke [QC Description] Attempting to create a sub-structure within a structure that also has a function of the same name will produce an error, but only if it is a templatised struct. QC Entry 49230

template <class T> struct TM { struct { unsigned __int8 Status; unsigned __int8 Attribute; }; void Ok(unsigned __int8 ib) { if (ib!=Attribute) 1; } int Ok() { return Status; } }; void MyTest() { TM<int> t; t.Ok(); // fails here for error [BCC32 Error] Unit1.cpp(25): E2193 Too few parameters in call to 'TM<int>::Ok(unsigned char)' t.Ok(3); } The following code works fine: struct TM { struct { unsigned __int8 Status; unsigned __int8 Attribute; }; void Ok(unsigned __int8 ib) { if (ib!=Attribute) 1; } int Ok() { return Status; } }; void MyTest() { TM t; t.Ok(); // compiles clean, no warning and no error t.Ok(3); }

QC #: 49237 - Status: Closed

QC #: Project Date Reported: Area:49237 Delphi 7/18/2007 Database\DBExpress\TSQLDataSet

Description Steps:[Interbase] [QC Short Description] Valid SQL produces "field name missing" error [QC Description] Using DBX4 and the InterBase driver the following valid SQL produces EDatabaseError with the message "field name missing". SELECT 1 FROM KEYWORD_NOTE WHERE EXISTS (SELECT NOTE_ID FROM KEYWORD_NOTE WHERE KEYWORD_ID = :KEYWORD_ID) However, the following SQL executes without error. SELECT KEYWORD_ID FROM KEYWORD_NOTE WHERE EXISTS (SELECT NOTE_ID FROM KEYWORD_NOTE WHERE KEYWORD_ID = :KEYWORD_ID) Note that the only difference is that in the SELECT that works the literal 1 in the SELECT clause has been replaced with a field name. Also not that both queries execute without error in IBConsole and isql.QC Entry 49237

TDBXHighlanderBugsSuite.native.db.test.exe connection=IBCONNECTION -s:TestRaid_252579 -or- Using DBX4 connect to any InterBase database and execute a query of the form SELECT 1 FROM KEYWORD_NOTE WHERE EXISTS (SELECT NOTE_ID FROM KEYWORD_NOTE WHERE KEYWORD_ID = :KEYWORD_ID) The error is caused by the literal 1 in the SELECT clause. This is valid SQL and it does execute without error in IBConsole and isql. SYSOP: Sample project attached. The sample project uses an Interbase connection called TEST. This was setup using Database Explorer. I have included a screen capture of its settings. It uses the EMPLOYEE.GDB file The query used is different because the data is different. select CUST_NO from SALES WHERE EXISTS (select PAID from SALES WHERE CUST_NO = :CUST_NO )

QC #: 49302 - Status: Closed

QC #: Project Date Reported: Area:49302 C++Builder 7/19/2007 Compiler\C++\Front End\Diagnostics

Description Steps:[QC Short Description] No compiler diagnostic for conversion from char* to FILE in fprintf() [QC Description] The following code compiles without error in CB2007: #include <stdio.h> int main( int, char* ) { fprintf( "%s", "ASDADA" ); return 0; } The conversion from char* to FILE should emit a diagnostic. tested in BCB6, BDS2006 & Comeau Online and all emit a diagnostic.QC Entry 49302

download attachment bcc32 -c qc49302.cpp Exp: Error E2034 qc49302.cpp 5: Cannot convert 'char *' to 'FILE *' in function main( int,char *) Error E2342 qc49302.cpp 5: Type mismatch in parameter '__stream' (wanted 'FILE *', got 'char *') in function main(int,char *) *** 2 errors in Compile *** Act: Clean compile, no diagnostics

QC #: 49746 - Status: Closed

QC #: Project Date Reported: Area:

49746 Delphi 7/29/2007 VCL\Win 32 Controls\TImageList

Description Steps:[QC Short Description] Image List editor jumps to the last image after a replace [QC Description] This focus loosing is very annoying: the image list editor which is used to manage all images of a TImageList always jumps to the last image after a image has been replaced by the replace command. Act: Jumps to the last image after a replace command Exp: Stay at the replaced image QC Entry 49746

1. start IDE 2. open or create some project with a image list 3. put 10 images or so into it 4. replace the first one 5. watch the editor jump to the last image after the replace 6. be annoyed about this productivity killer

QC #: 49809 - Status: Closed

QC #: Project Date Reported: Area: 49809 Delphi 7/30/2007 RTL\Delphi\WinAPI Description Steps:[QC Short Description] Add MemoryBarrier and YieldProcessor functions [QC Description] Recent Platform SDK headers define MemoryBarrier and YieldProcessor functions. It would be convenient if Windows.pas included them as well. Suggested Pascal implementation: procedure MemoryBarrier; asm push eax xchg [esp], eax pop eax end; procedure YieldProcessor; asm pause // same opcode as "rep nop" end; Original declarations from WinNT.h: FORCEINLINE VOID MemoryBarrier ( VOID ) { LONG Barrier; __asm { xchg Barrier, eax } } #define YieldProcessor() __asm { rep nop } QC Entry 49809

N/A

QC #: 50034 - Status: Closed

QC #: Project Date Reported: Area:50034 C++Builder 8/3/2007 Compiler\C++\MS Compat. Description Steps:[QC Short Description] Compiler generates a wrong error message and aborts compilation [QC Description] When trying to import type libraries via #import, compiler generates an error. [BCC32 Error] stdafx.h(37): E2209 Unable to open include file ' notes32.tlh' QC Entry 50034

1. Open a project or simply create a new VCL application 2. Type #import "notes.tlb in the .cpp file 3. Place notes.tlb in the same folder as the .cpp file 4. Compile. 5. Observe the error [BCC32 Error] Unit3.cpp(5): E2209 Unable to open include file ' notes32.tlh' 6. In the same folder as .tlb file you will find the .tlh and .tli files You can use any .tlb file. Here is the source code. //--------------------------------------------------------------------------- #include <vcl.h> #pragma hdrstop #import "notes32.tlb" #include "Unit3.h" //--------------------------------------------------------------------------- #pragma package(smart_init) #pragma resource "*.dfm" TForm3 *Form3; //--------------------------------------------------------------------------- __fastcall TForm3::TForm3(TComponent* Owner) : TForm(Owner) { } //---------------------------------------------------------------------------

QC #: 50079 - Status: Closed

QC #: Project Date Reported: Area:50079 Delphi 8/5/2007 Database\DBExpress\TSQLConnection

Description Steps:[QC Short Description] TSQLConnection.CloneConnection does not work. [QC Description] Attempting to open a TSQLDataSet connected to a cloned connection causes the following Access Violation. Project Project2.exe raised exception class EAccessViolation with message 'Access violation at address 0042035A in module Project 2.exe. Read of address 00000008. QC Entry 50079

TDBXHighlanderBugsSuite.Native.Db.Test.exe connection=ibconnection -s:TestRaid253629 or Run the attached sample application which connects to the InterBase sample EMPLOYEE.GDB database. Click the button. The access violation occurs when the SqlDataSet2.Open is executed in the code below. procedure TForm2.Button1Click(Sender: TObject); begin Clone := Conn.CloneConnection; if Clone.Connected then ShowMessage('Clone connected') else Clone.Open; SqlDataSet2.SQLConnection := Clone; SqlDataSet2.Open; ClientDataSet2.Open;; end;

QC #: 50142 - Status: Closed

QC #: Project Date Reported: Area: 50142 C++Builder 8/7/2007 RTL\C++ Description Steps:[QC Short Description] Multi different definitions of time_t

bcc32 qc50142 exp: clean compile act: Error E2316 C:\Program Files\CodeGear\RAD Studio\5.0\Include\time.h 141: 'time_t ' is not a member of 'std'

[QC Description] typedef long time_t is definend in different files in utime.h as #ifndef _TIME_T #define _TIME_T typedef long time_t; #endif and in the files time.h sys\types.h io.h #ifndef _TIME_T typedef long time_t; #ifdef __cplusplus # define _TIME_T std::time_t #else # define _TIME_T time_t #endif /* __cplusplus */ #endif QC Entry 50142

QC #: 50350 - Status: Closed

QC #: Project Date Reported: Area: 50350 C++Builder 8/10/2007 RTL\C++ Description Steps:[QC Short Description] memmgr.lib auto-inclusion, links by ordinal [QC Description] bds2006 projects apparently automatically include "memmgr.lib" as an item to be linked, with no way to change it, and it appears to precede all user-specified libraries. memmgr.lib specifies linking to routines by ordinal. If one wishes to link to a replacement library calling some of the memory management functions directly (fastmm or other), since the ordinal values for the functions in the replacement library do not necessarily match, one will wind up linking to and calling an incorrect function. The memmgr.lib, should A)preferably be removeable in some obvious fashion (if it is I haven't figured out how), or B)minimally, and maybe even in addition to, provide linking by name, rather than by ordinal. QC Entry 50350

Create a simple vcl forms project. Make sure BDS is configured to show command lines. Build the project. Examine the command line and see that a memmgr.lib is part of the link command, but has not been specified as part of the project. tdump the <bdsinstall>\lib\memmgr.lib, and see that the items are specified as link by ordinal.

QC #: 50386 - Status: Closed

QC #: Project Date Reported: Area: 50386 Delphi 8/11/2007 ActiveX Description Steps:

[QC Short Description] COM libraries created with Delphi cannot be installed under users withno write access to HLM or with UAC turned on (Vista). [QC Description] COM libraries created with Delphi cannot be installed under users with no write access to HLM or with UAC turned on (Vista). The objects must be registered under HKCU\Software\Classes rather than HKCR. When registering a type library, RegisterTypeLibForUser (Windows 2003 or Vista) must be used rather than RegisterTypeLibFor. It is also possible to use RegOverridePredefKey() for Windows XP. The modified VCL files are attached (AxCtrls.pas, ComObj.pas, ComServ.pas) P.S. It seems like I cannot attach files to the report. I will add the changes to the Workaround tab. QC Entry 50386

Create a COM server (a dll will do) and try to register it with regsvr32.exe while running under a Windows account with limited (no write access to HKLM) rights or when UAC on Vista is turned on

QC #: 51777 - Status: Closed

QC #: Project Date Reported: Area: 51777 C++Builder 9/10/2007 Compiler\C++\Back End Description Steps:[QC Short Description] Internal backend error TR1978 compiling ???(0) [QC Description] Trying to compile this fragment of code results in an internal backend error TR1978. class A { public: template <class T> T foo(const char * a, T b = 0); }; int main( int, char* ) { A a; a.foo<int>(""); return 0; } QC Entry 51777

Download attached file bcc32 -c qc51777.cpp Exp: Clean compile Act: Internal backend error TR1978 compiling ???(0)

QC #: 52044 - Status: Closed

QC #: Project Date Reported: Area: 52044 Delphi 9/14/2007 IDE\Help Description Steps:[QC Short Description] No help for the GlassFrame property of TForm [QC Description] Hello, if I like to look up what this new GlassForm property from TForm is in the help I won't get anywhere unless I know that I have to search not

1. open the help 2. open the topic of TForm 3. try to find GlassForm anywhere 4. don't find it 5. be annoyed and look it up under TGlassForm

under TForm (where the property belongs to) but rather TGlassForm (the type of the property). It should at least be listed under TForm and being linked from there, at least! QC Entry 52044 -------- Emeli: F1 works if invoked from Object Inspector property seems listed under TCustomForm but not from TForm

QC #: 52292 - Status: Closed

QC #: Project Date Reported: Area: 52292 Delphi 9/20/2007 RTL\Delphi\Date - Time Description Steps:[QC Short Description] DateTimeToString thread-safety issue [QC Description] The second (thread-safe) overload of the SysUtils.DateTimeToString() procedure has a slight issue: It mistakenly accesses the global variables instead of the FormatSettings field when processing the date/time separators. The offending part is in lines 12671-12677: '/': if DateSeparator <> #0 then AppendChars(@FormatSettings.DateSeparator, 1); ':': if TimeSeparator <> #0 then AppendChars(@FormatSettings.TimeSeparator, 1); '''', '"': The DateSeparator and TimeSeparator global variables are checked, instead of the fields from FormatSettings, which makes little sense. These should be instead: '/': if FormatSettings.DateSeparator <> #0 then AppendChars(@FormatSettings.DateSeparator, 1); ':': if FormatSettings.TimeSeparator <> #0 then AppendChars(@FormatSettings.TimeSeparator, 1); '''', '"': This not only will cause the separators to be left out in the unlikely chance that the local machine has them null, but in accessing the global variables it undermines the purported thread-safety of the routine. Also, it fails to protect the code from null separator fields in FormatSettings record, which may cause unintended results. -dZ. QC Entry 52292

QC #: 52310 - Status: Closed

QC #: Project Date Reported: Area: 52310 Delphi 9/20/2007 RTL Description Steps:

[QC Short Description] Add Variant support for UInt64 [QC Description] Request to add native variant support and conversion for UInt64 data type. QC Entry 52310

var v: variant := $FFFFFFFFFFFFFFFF currently produces v = -1 and VarType(v) = varInt64. varWord64 = $0015 is available in System.pas.

QC #: 52315 - Status: Closed

QC #: Project Date Reported: Area: 52315 Delphi 9/20/2007 VCL\Graphics Description Steps:[QC Short Description] Extend TFont with Quality property [QC Description] It would be good to be able to control the quality appearance of a font. At the moment the application has to use the system settings. Applications like Internet Explorer 7 can use ClearType even if it is disabled in the system settings. QC Entry 52315

feature request

QC #: 52639 - Status: Closed

QC #: Project Date Reported: Area:52639 C++Builder 9/27/2007 Compiler\C++\Front End\Templates

Description Steps:[QC Short Description] template static data member multiply defined [QC Description] The following report applies to BCB 6.0 update #4: If you unzip the attaced files and do first "make error" then "make noerror", you will see that in the former case, a simple template static data member like template <class T, int N> class Foo { public: static T arr[N]; }; can be multiply defined in an object file depending on whether the first reference to it comes before or after its definition in the source code. When the error appears, the object file contains both a PUBDEF and a COMDEF record for the template static data member, and the PUBDEF record unfortunately contains an incorrect offset. This seems to confuse the linker when creating the final executable. We have also understood that a COMDEF (or actually a VIRDEF record, in the present case) is normally incompatible with the presence of a PUBDEF for the same symbol. But the compiler apperently doesn't comply with this rule. The error has been reproduced in the IDE as well. QC Entry 52639

bcc32 -DPROVOKE_ERROR qc52639.cpp 52639.cpp qc52639 res: The following exhibits the error reported: Direct access to Foo4::arr 16 [0]: 1 [1]: 2 [2]: 3 [3]: 4 Indirect access to Foo4::arr through getInt() [0]: 0 [1]: 0 [2]: 0 [3]: 0 exp: Direct access to Foo4::arr 16 [0]: 1 [1]: 2 [2]: 3 [3]: 4 Indirect access to Foo4::arr through getInt() [0]: 1 [1]: 2 [2]: 3 [3]: 4

QC #: 53056 - Status: Closed

QC #: Project Date Reported: Area:53056 Delphi 10/5/2007 IDE\Object Inspector Description Steps:[QC Short Description] An AV occurs when dynamically changing a TPersistent type property in the Object Inspector [QC Description] Added by Sysop <<<<<<<<<<< This issue still occurs on Delphi 2010. Please take a look at comments for more information.>>>>>>>>>>> QC Entry 53056

1. Open MyProjectGroup.groupproj 2. Compile and install MyPackage. 3. Open Form1 from Project1. 4. Expand and collapse the Persistent property in the Object Inspector. 5. Toggle the UseBasePersistent property value. 6. Expand the Persistent property in the Object Inspector. Repeat steps 4-6 several times until an AV occurs. =============================================================== The bug can be reproduced now in Delphi 2009 with installed update packs 1-3 (see the updated project in the attachment). In this project, I added a property ComponentValue of type TComponent to a persistent TDescendantPersistent. An exception is still raised in Delphi 2009 when taking the following steps: 1. Open MyProjectGroup.groupproj 2. Compile and install MyPackage. 3. Open Form1 from Project1. 4. Expand and collapse the Persistent property in the Object Inspector. 5. Toggle the UseBasePersistent property value. 6. Expand the Persistent property in the Object Inspector.

QC #: 53321 - Status: Closed

QC #: Project Date Reported: Area: 53321 Delphi 10/11/2007 IDE\Memory Issues Description Steps:[QC Short Description] Memory leak - Closing a project or project group doesn't release memory. [QC Description] Here the result of a simple test, highly visible and easy to reproduce. (ICS sample group, any other projects will work as well) --------------------------------------------------- Project built Priv. virtual bytes after built --------------------------------------------------- IcsDel110.Bpl 118.308 K .. Client7.exe 140.960 K ConCli1.exe 150.124 K ConCli2.exe 170.584 K .. ConUdpLstn.exe 214.352 K --------------------------------- After *Closed All* 214.680 K --------------------------------- MailSendAsync.exe 225.048 K .. Note that the cache memory is never released, it grows infinite. My 1 GB system starts swapping to disk heavily at ~500-600 MB priv. bytes. Even closing all and starting some processes doesn't release it, I'm forced to exit and restart the IDE. Comment: If I haven't dreamed that, I saw it fixed in in one of the late FT drops. QC Entry 53321

See description

QC #: 53645 - Status: Closed

QC #: Project Date Reported: Area:53645 Delphi 10/17/2007 RTL\Delphi\File Management Description Steps:[QC Short Description] On a platform where "GetProcAddress(GetModuleHandle(kernel32),

FileAge may no longer be thread-safe on D2007 (possible access violation) [QC Description] If two threads enter FileAge() simultaneously, it is possible for an access violation to occur on the call to the procedural variable GetFileAttributesExFunc. Initially, GetFileAttributesExFunc points to a function called "GetFileAttributesExPreload": function GetFileAttributesExPreload(lpFileName: PChar; fInfoLevelId: TGetFileExInfoLevels; lpFileInformation: Pointer): BOOL; stdcall; begin GetFileAttributesExFunc := GetProcAddress(GetModuleHandle(kernel32), 'GetFileAttributesExA'); if not Assigned(GetFileAttributesExFunc) then GetFileAttributesExFunc := GetFileAttributesExEmulated; Result := GetFileAttributesExFunc(lpFileName, fInfoLevelId, lpFileInformation); end; Can you spot the race condition? If GetProcAddress returns nil, there's a window in which GetFileAttributesExFunc will be set to nil. If, prior to reaching the "GetFileAttributesExFunc := GetFileAttributesExEmulated" line, a second thread enters FileAge(), the second thread will fail with an access violation when it attempts to call GetFileAttributesExFunc, because it will be jumping into a nil function pointer. This race condition can be eliminated by changing the code to read as follows: function GetFileAttributesExPreload(lpFileName: PChar; fInfoLevelId: TGetFileExInfoLevels; lpFileInformation: Pointer): BOOL; stdcall; var P: Pointer; begin P := GetProcAddress(GetModuleHandle(kernel32), 'GetFileAttributesExA'); if Assigned(P) then GetFileAttributesExFunc := P else GetFileAttributesExFunc := GetFileAttributesExEmulated; Result := GetFileAttributesExFunc(lpFileName, fInfoLevelId, lpFileInformation); end; QC Entry 53645

'GetFileAttributesExA')" returns nil, call FileAge from two threads simultaneously.

QC #: 54205 - Status: Closed

QC #: Project Date Reported: Area: 54205 Delphi 10/31/2007 IDE\History View Description Steps:[QC Short Description] Block indent/Tab stops not handled the same way in the History view as in the Editor [QC Description] The setup for "Block indent" and "Tab stops" in Options/Editor Options only handle Editor windows not the windows for History view. Other setups as color does. QC Entry 54205

QC #: 54283 - Status: Closed

QC #: Project Date Reported: Area:54283 C++Builder 11/1/2007 Compiler\C++\Front End\Diagnostics

Description Steps:[QC Short Description] Invalid (useless) Warning 8071 when math is performed on same type [QC Description] A warning is being generated when the following: unsigned short a = 0; unsigned short b = 1; a = -a; // 8071 generated unsigned short r = a + b; // 8071 generated a += b; // 8071 not generated (inconsistent with a + b) QC Entry 54283

download attached file bcc32 -c -w qc54283.cpp Exp: clean compile Act: Warning W8071 qc54283.cpp 5: Conversion may lose significant digits in function main(int,char *) Warning W8071 qc54283.cpp 6: Conversion may lose significant digits in function main(int,char *)

QC #: 54358 - Status: Closed

QC #: Project Date Reported: Area: 54358 Delphi 11/3/2007 IDE\Desktop Layouts Description Steps:[QC Short Description] IDE loses focus after editor window is closed [QC Description] This issue was first introduced in BDS 2006: With the Classic Undocked desktop layout active, if you close the editor window (via Alt+F4 or the window's close button), the keyboard focus in some cases will move away from the IDE and onto another application's window. Only the editor window appears to be affected by this problem. The focus doesn't leave the IDE when other windows like Structure or Object Inspector are closed in the same manner. QC Entry 54358

1. Start the IDE with the Classic Undocked desktop layout selected. 2. Click File | New | VCL Forms Application - Delphi for Win32. 3. Activate the editor window for Unit1, and make sure the Code tab is selected. 4. Click the Windows Start button, then Programs, Accessories, Notepad. 5. With Notepad active, click directly back onto the IDE's editor window. (Do NOT switch to any other windows in between!) 6. Close the editor window by pressing Alt+F4. Answer No when asked to save changes. Actual results: The focus leaves the IDE. Notepad is brought back to the foreground. Expected results: Like in Delphi <=2005, the focus should move to another IDE window. It doesn't really matter which particular one is activated; what's important is that subsequent keystrokes to access menus/etc. are seen by the IDE, and not some other application that unexpectedly popped into the foreground.

QC #: 54367 - Status: Closed

QC #: Project Date Reported: Area:54367 C++Builder 11/4/2007 Compiler\C++\Front End\Diagnostics

Description Steps:[QC Short Description] Internal Compiler Error from bad typedef [QC Description] typedef (void *Callback)( ); causes an ICE QC Entry 54367

download attached file bcc32 -c qc54367.cpp Exp: Error E2040 qc54367.cpp 1: Declaration terminated incorrectly Act: Error E2091 qc54367.cpp 1: Functions cannot return arrays or functions Fatal F1004 qc54367.cpp 1: Internal compiler error at 0x47a7c1 with base 0x400000 Fatal F1004 qc54367.cpp 1: Internal compiler error

QC #: 54591 - Status: Closed

QC #: Project Date Reported: Area: 54591 Delphi 11/8/2007 IDE\Help Description Steps:[QC Short Description] No help topic for TIBDataSet [QC Description] There is no help topic for TIBDataSet in the help. It is being reported that it was still there in BDS2006. QC Entry 54591

1. open the help 2. look for TIBDataSet 3. experience that it can't be found

QC #: 54731 - Status: Closed

QC #: Project Date Reported: Area:54731 Delphi 11/12/2007 IDE\Code Editor\Error Insight Description Steps:[QC Short Description] ErrorInsight reports error for compilable code [QC Description] Sometimes the ErrorInsight reports source as faulty which is perfectly compiled. In steps you find a unit with two examples. QC Entry 54731 // Francois Piette First issue fixed in Delphi 2007. I still see the second issue in build 2870.10108.1 Actually second issue is a syntax error so ErrorInsight is right but compiler compile it without problem (It already did with D7).

unit Unit2; interface type TMyType = record MyVar2: Integer // no ; before end [1st issue] ///NOTE: this now gives no error. end; implementation procedure MyProcedure( a,b,c: Integer ); begin end; initialization MyProcedure( 1,2,3, ); // additional , at end of list [2nd issue] end.

QC #: 54822 - Status: Closed

QC #: Project Date Reported: Area:54822 Delphi 11/14/2007 Documentation\Online Help\VCL

Description Steps:[QC Short Description] VCL properties and methods are not indexed [QC Description] When you press F1 and go into the index tab and search for a method or property of a vcl component, let us say TControl for example, you will get a bunch of useless references to Windows documentation and other non relevant pages. I would expect that since the VCL is the primary programming library in Delphi, that I would be able to find all the methods and properties of all components indexed and easily available for quick reference. QC Entry 54822

For example I want to find the documentation of TControl.Parent. Press F1. Go into the Index tab. Type in "Parent" in the Look for: edit. Expected result: All references to Parent method displayed. What I got: A bunch of useless stuff.

QC #: 55044 - Status: Closed

QC #: Project Date Reported: Area: 55044 C++Builder 11/20/2007 ActiveX Description Steps:[QC Short Description] IsComPlusPlatform bug [QC Description] In utilcls.h the function IsComPlusPlatform fails because the dwOSVersionInfoSize member of the OSVERSIONINFO variable is not set before the call to the Win API function GetVersionEx. The SDK documentation clearly states this should be done. This problem has been around since at least BCB6. Demo code: #include <windows.h> #include <utilcls.h> #include <iostream> class A{}; int main( int, char* ) { bool a( IsComPlusPlatform<A>() ); std::cout << (a ? "Pass" : "Fail"); return a ? 0 : 1; } QC Entry 55044

in winxp or other COM+ enabled OS download attached file bcc32 qc55044.cpp qc55044 Exp: Output "Pass" / return code 0 Act: output "Fail" / return code 1

QC #: 55176 - Status: Closed

QC #: Project Date Reported: Area: 55176 Delphi 11/22/2007 RTL\Delphi\Other RTL Description Steps:[QC Short Description] BcdCompare return invalid result [QC Description] Please run the test cases in "steps to reproduce". QC Entry 55176

Compile and run the attached application below. See the following output at runtime indicating failure. FAIL #2 FAIL #4 program bts256691; {$APPTYPE CONSOLE} uses Variants, FmtBCD; var Counter: Integer = 0; procedure Add; var B: TBcd; i: integer; begin B := StrToBcd('1'); BcdAdd(B, StrToBcd('-1'), B); if BcdCompare(B, VarToBcd(0)) = 0 then Inc(Counter) else WriteLn('FAIL #1'); B := StrToBcd('-1'); BcdAdd(B, StrToBcd('1'), B); if BcdCompare(B, VarToBcd(0)) = 0 then

Inc(Counter) else WriteLn('FAIL #2'); end; procedure Subtract; var B: TBcd; begin B := StrToBcd('1'); BcdSubtract(B, StrToBcd('1'), B); if BcdCompare(B, VarToBcd(0)) = 0 then Inc(Counter) else WriteLn('FAIL #3'); B := StrToBcd('-1'); BcdSubtract(B, StrToBcd('-1'), B); if BcdCompare(B, VarToBcd(0)) = 0 then Inc(Counter) else WriteLn('FAIL #4'); end; begin Add; Subtract; if Counter = 4 then WriteLn('PASS'); end.

QC #: 55303 - Status: Closed

QC #: Project Date Reported: Area:55303 Delphi 11/27/2007 Documentation\Online Help\VCL

Description Steps:[QC Short Description] TBrowseForFolder documentation missing [QC Description] TBrowseForFolder is a standard action available in TActionManager. The documentation is missing. (This is foo of bar, standard error). Futhermore the following properties are not documented (more - this is foo of bar): public property - Folder published properties - BrowseOptions DialogCaption RootDir published events - OnAccept OnCallback OnCancel OnValidate QC Entry 55303

QC #: 55472 - Status: Closed

QC #: Project Date Reported: Area:55472 Delphi 12/1/2007 Compiler\Delphi\Errors - Warnings

Description Steps:[QC Short Description] Cryptic message when an Interface isn't implemented fully [QC Description] Hi, if an interface isn't implemented fully then a misleading (imho) message pops up saying 'E2003 Undeclared identifier: '<identifier name>'. A much more usefull message would be 'Interface <intf name> not implemented fully in class <class name> - <identifier name> is missing'. This will save us many time of hunting for non-existent identifiers especially when we work in teams and especially if the interface definition is in another unit. To make things harder, the 'Undeclared identifier' is used also when we have a typo on an existing one, a syntax error etc. so one cannot track the real cause of the message. QC Entry 55472

Compile the attached program below. See the following compile time error message. Error: E2003 Undeclared identifier: 'F3' (JJS): Note that recompiling with the .NET compiler the following error message is seen. Error: E2291 Missing implementation of interface method IMyInterface.F3 This error is much more descriptive and useful to the programmer. program BTS256656; {$APPTYPE CONSOLE} type IMyInterface = interface procedure F1; procedure F2; procedure F3; end; type TMyClass = class(TInterfacedObject, IMyInterface) procedure F1; procedure F2; end; procedure TMyClass.F1; begin end; procedure TMyClass.F2; begin end; begin WriteLn('FAIL - Compile time error expected'); end.

QC #: 55849 - Status: Closed

QC #: Project Date Reported: Area:55849 Delphi 12/11/2007 RTL\Delphi\Null-terminated strings

Description Steps:[QC Short Description] StrScan is slow (unnecessary jump) [QC Description] The StrScan function can be optimized. The current implementation executes an unnecessary jump for each iteration. function StrScan(const Str: PAnsiChar; Chr: AnsiChar): PAnsiChar; begin Result := Str; while Result^ <> Chr do begin if Result^ = #0 then // conditional jump to "Inc(Result)" begin Result := nil;

see workaround for the faster function

Exit; end; Inc(Result); end; end; QC Entry 55849

QC #: 56957 - Status: Closed

QC #: Project Date Reported: Area: 56957 Delphi 1/14/2008 RTL\Delphi\DateUtils Description Steps:[QC Short Description] A Fix for DateUtils Date-Time Compare Functions [QC Description] Programmers have problems with most of the "time-between" functions in Delphi's DateUtils module. The problems (all that I have heard about) are what I call "hidden-value" problems. These problems are due to the fact that the common time values like minute and second do not have exact representations in the TDateTime variable commonly used to store and manipulate date-time values. The TDateTime values would usually be a tiny amount above or below the value that the module's programmer thought his code was working with. Thus the true value of the date-time is "hidden" from the programmer. The long-term, best solution for relieving the programmers' misery is probably to replace the use of TDateTime with something like SQL's TIMESTAMP with its selectable number of seconds decimal fraction resolution or better yet with the SQL TIMESTAMP_WITH_TIMEZONE. However the most expedient solution, which is an easy fix to make and a good one I believe, is to keep the TDateTime variable, but wherever is used for comparisons, convert its value to milliseconds in an Int64 format, similar to what is presently used in the time formatting functions. The Deplhi program sources attached to this QC report are for demonstrating the problem, and testing the millisecond solution to the hidden-time-value problem. The milliseconds used are referenced to the same reference date 0001-01-01 as is used for the SysUtils.TTimeStamp record. The TTimeStamp record and the standard SysUtils' DateTimeToTimeStamp and TimeStampToDateTime routines seem to work perfectly as demonstrated by these tests. This QC report is a duplicate of earlier report #4430; but this newer report contains much more information about the proposed fix and a lot of testing to prove its effectiveness. See QualityCentral report #4430 for more info. In particular, see my comments in that report posted around 2006-12-11 and 2006-12-13. The included module DateUtils_SuggestedChanges_2.pas contains a sample of the DateUtils routines and the suggested modifications and additions for comparison testing. For the reader's further information, here are the QC reports possibly related to DateUtils or this "hidden value" problem: 3240 (C) EndOfADay long format returns value 1 month out 3820 (O) HoursBetween fails to return the good value 4430 (O) Errors using MinutesBetween function 5953 (O) Some functions that use TFormatSettings are not independant of SysLocale & thread's locale 9184 (D) Incorrect Value returned by MinutesBetween function in the DateUtils Unit 27191 (O) DateTime is loosing precision when accessed as Double from DateTime utils functions

To use this program (developed with D7), compile and open it. T_MinutesBetween from QC4430 will test the DateUtils.MinutesBetween function, or if the "Use new and improved" box is check, the T_HiddenTimeValue_2_Unit2 version of MinutesBetween will be used. T_MinutesBetween(X,Y) will run both versions of MinutesBetween and compare the results. ShowExactDateTime will show you the exact value for any date-time that you enter in the upper-left boxes. T_DateTimeToTimeStampAndBack test will test the conversion between TDateTime and TTimeStamp for every millisecond of the whole day specified in the upper-left. T_MilliSecondsToDateTime will test the conversions between Int64 milliseconds and TDateTime by the functions MilliSecondsToDateTime and its inverse around crossovers between days around the date in the upper left. T_MilliSecondsToDateTime displays and tests function by same name. T_DateTimeToMilliseconds displays and tests function by same name.

36551 (C) TryEncodeDateTime 37174 (O) CompareDate function in DateUtils.pas use Trunc and can wrong compare 40798 (O) Many of the functions in DateUtils.PAS are ideal candidates for inlining 56957 (R) A Fix for DateUtils Date-Time Compare Functions QC Entry 56957

QC #: 57030 - Status: Closed

QC #: Project Date Reported: Area: 57030 Delphi 1/16/2008 IDE\Code Completion Description Steps:[QC Short Description] *Overloaded* methods are not in CodeCompletion's pulldown suggestion list [QC Description] Here is another example of inconsistency in the CodeCompletion area: As shown by the attached snapshot, certain public methods don't appear in the suggestion combobox (Ctrl-Space), although the IDE does know about them and if I manually type in the method name, Ctrl-Shift-Space correctly shows parameters for the method. The entire project has been compiled just prior to observing this behaviour. ADDED: this happens to OVERLOADed methods. QC Entry 57030

- Add the attached form to a new or existing project. - Look at the two similar classes defined there, one with OVERLOADed methods, another without them. - At the end of the form unit you will see the following code, intentionally left unfinished: obj1.AddSQL( // press Ctrl-Shift-Space obj1.a // press Ctrl-Space obj2.a // press Ctrl-Space - go to the end of each line and press the appropriate Code Completion hot keys - you will see that CodeCompletion knows about the overloaded methods (and their parameters), but doesn't show them in the pulldown list. Similar non-overloaded methods in the other class are shown in the list.

QC #: 57174 - Status: Closed

QC #: Project Date Reported: Area:57174 C++Builder 1/20/2008 Compiler\C++\Front End\Templates

Description Steps:[QC Short Description] template function default constructor arguments failure [QC Description] A problem with Quantlib (www.quantlib.org) that I encountered - does not allow a (implicit) default argument. See below: //--------------------------------------------------------------------------- #pragma hdrstop #include <iostream> using namespace std; //--------------------------------------------------------------------------- class LinearInterpolation { public: LinearInterpolation(){}; }; class BlackVarianceCurve { public: template <class Interpolator>

1) Create a new console application 2) copy the code on the left 3) compile

double setInterpolation(const Interpolator& i = Interpolator()) {return 1.0;} }; #pragma argsused int main(int argc, char* argv[]) { BlackVarianceCurve lBVC; cout << "lBVC.setInterpolation<LinearInterpolation>() = " << lBVC.setInterpolation<LinearInterpolation>() << endl; return 0; } //--------------------------------------------------------------------------- The error returned: [BCC32 Error] File1.cpp(19): E2268 Call to undefined function 'Interpolator' QC Entry 57174 C++ Templates

QC #: 57232 - Status: Closed

QC #: Project Date Reported: Area:57232 C++Builder 1/21/2008 ActiveX\Code Generators\C++

Description Steps:[QC Short Description] Unique names for ActiveX wrapper classes, or ability to choose. [QC Description] Frequently, when importing ActiveX controls, the generated wrapper classes conflict with already registered classes and so generated BPL packages can not be loaded (this is especially common when importing Microsoft Windows Common Controls 1, 2, and 3, with classes such as TUpDown and TToolbar). Current solution is to import then refactor (C++ Rename). Refactoring does not always work (see previous Quality Control report) and always involve trial and error (build, install, refactor, build, install). Suggestion 1: Add an "Ax" (or some other prefix) to the beginning of generated wrapper class names to reduce possibility of imported ActiveX wrapper classes conflicting with preexisting classes. This would generate wrapper class names such as TAxUpDown or TAxListView. Suggestion 2: Allow specification of generated wrapper class names in component import wizard. Automate the process of refactoring the generated code. Suggestion 3: Allow specification of a namespace to put wrapper class names in. Add support to design tool box (and to generated code when using a control from the tool box) for design classes in multiple namespaces. Do not add "using" line for name space, leave that up to the programmer -- generated code would always specify namespaces explicitly. I believe the above suggestions are in order from least to most amount of changes that would have to be made to the component import wizard and design tool box. QC Entry 57232

QC #: 57818 - Status: Closed

QC #: Project Date Reported: Area: 57818 Delphi 2/4/2008 IDE\Code Editor Description Steps:[QC Short Description] Column blocks work incorrectly with non-English characters [QC Description] See Steps to Reproduce QC Entry 57818 // Francois Piette Probably related to raid 258286.

Add the following text in the editor: abcd abSd (the second line includes a Polish character). Mark the block as a column block and try to copy that block one column to the right of the first d. Expected result: abcdabcd abSdabSd Actual result: abcd abcd abSdabSd

QC #: 57872 - Status: Closed

QC #: Project Date Reported: Area:57872 C++Builder 2/5/2008 IDE\Project Management\Project Manager

Description Steps:[QC Short Description] Compile to ASM [QC Description] I have only ever been able to get ASM output to work using the command line compiler, but would like to be able to it from the IDE if possible. I think this feature should be added as a context menu option in the project manager like the Preprocess command. It could be a second command below Compile, perhaps labeled "Compile to ASM". It would compile the selected source file to an assembly language file (using the -S option to the command line compiler) and display the resulting ASM file in the IDE. QC Entry 57872

QC #: 58036 - Status: Closed

QC #: Project Date Reported: Area:58036 Delphi 2/9/2008 IDE\Help

Description Steps:[QC Short Description] Index entry for topic Creating DLLs with.... too short [QC Description] The index entry for this topic: ms-help://borland.bds5/devwin32/idh_creatingdllscontainingvclcomponents_xml.htmlis misleading because it is too short. Currently it is only: DLLs, creating which could also mean it's a general topic about creating DLLs, but the topic rather is one about creating DLLs containing VCL forms etc. QC Entry 58036

QC #: 58156 - Status: Closed

QC #: Project Date Reported: Area: 58156 C++Builder 2/12/2008 IDE\Code Editor

Description Steps:[QC Short Description] Incremental search does not search entire document. [QC Description] Incremental search does not search the entire document. It only searches from the current cursor position to EOF. There is no option to search entire documents. The message box that says "Search String Not Found" only has an "OK" button -- it is missing the "Continue search at beginning?" question and the "Yes" and "No" buttons. This may be a bug. The same problem appears to occur in normal searches (Search -> Find). Incremental searching in any text editor has two basic functions: 1) To find an occurence of a string in a document, 2) To allow searching to be performed in a quick and convenient manner, without disrupting other tasks (the incremental search feature in Firefox for example; or in emacs which wraps around to the start of the document without prompt at all). All searching features have function #1, "incremental searching" is unique in it's addition of function #2. However, having to apply the described workaround removes both the quickness and convenience of incremental searching. Thus, this is a basic functionality failure of incremental searching. QC Entry 58156

QC #: 58481 - Status: Closed

QC #: Project Date Reported: Area:58481 C++Builder 2/19/2008 Compiler\C++\Front End\Language

Description Steps:[QC Short Description] Temporary binding to a non-const lvalue reference. [QC Description] The examples opposite show three cases where a temporary object of type B is bound to a lvalue-reference to non-const. Each of the three function calls in main() should report an error. QC Entry 58481

bcc32.exe 257834.cpp res: clean compile exp: Error E2357 257834.cpp 17: Reference initialized with 'B', needs lvalue of type 'B' in function main(int,char * *) Error E2340 257834.cpp 17: Type mismatch in parameter 1 (wanted 'B &', got 'B') in function main(int,char * *) Error E2357 257834.cpp 18: Reference initialized with 'B', needs lvalue of type 'B' in function main(int,char * *) Error E2340 257834.cpp 18: Type mismatch in parameter 1 (wanted 'B &', got 'B') in function main(int,char * *) Error E2357 257834.cpp 19: Reference initialized with 'B', needs lvalue of type 'B' in function main(int,char * *) Error E2340 257834.cpp 19: Type mismatch in parameter 1 (wanted 'B &', got 'B') in function main(int,char * *) *** 6 errors in Compile ***

QC #: 58554 - Status: Closed

QC #: Project Date Reported: Area:

58554 Delphi 2/21/2008 Database\DBExpress Description Steps:[Oracle] [QC Short Description] Calling Mypackage.Myfunction doesn't work in Oracle10 QC Entry 58554 Added by Sysop <<<<<<<<<<<<< From a comment of QC report. -------- I think this is solved since D2009. I don't know why it is still open. -------- >>>>>>>>>>>>>

TDBXFulcrumBugsSuite.Native.Db.Test.exe connection=oracleconnection -s:TestRaid_258571 -OR- Run this script to create a package in Oracle 10g: CREATE OR REPLACE PACKAGE PACKMANYBUGS AS FUNCTION MYFunc(MYPAR NUMBER) RETURN VARCHAR2;PROCEDURE MYPROC(MYPAR IN OUT VARCHAR2); END PACKMANYBUGS; / CREATE OR REPLACE PACKAGE BODY PACKMANYBUGS AS FUNCTION MYFunc(MYPAR NUMBER) RETURN VARCHAR2 IS BEGIN RETURN 'BUG'; END MYFunc; PROCEDURE MYPROC(MYPAR IN OUT VARCHAR2) IS BEGIN MYPAR := 'TEST'; END MYPROC; END PACKMANYBUGS; Then run the attached program, enter a valid user in your database and push Conectar. When it succeeds, push Ejecutar to run the stored procs. The one that calls MyProc works but the one that calls MyFunc gives error ORA-06550. (you should change first SchemaName and the databasename according to your database)

QC #: 58851 - Status: Closed

QC #: Project Date Reported: Area: 58851 C++Builder 2/28/2008 Compiler\C++ Description Steps:[QC Short Description] Address of overloaded member function as parameter not working [QC Description] The compiler isn't able to compile code where the address of an overloaded member function is passed to a template function. Possibly related to QC58849 / RAID257946. Compile the following code: class foo { public: void run() {} void run(int) {} }; template <class C> void bind(void (C::*fn)()) {}

download attachment bcc32 -c qc58851.cpp Exp: Clean compile Act: Error E2285 qc58851.cpp 13: Could not find a match for 'bind<C>(void (foo::*)())' in function main()

int main() { bind(&foo::run); } QC Entry 58851 C++ Templates

QC #: 58864 - Status: Closed

QC #: Project Date Reported: Area: 58864 Delphi 2/28/2008 VCL\Core VCL Classes Description Steps:[QC Short Description] TComboBox.Items.IndexOf cannot find empty string [QC Description] TComboBox.Items.IndexOf does not work correctly for the empty string. Even if the combo box's items do contain an empty string, IndexOf('') will incorrectly return -1. This is inconsistent with the behavior of other TStrings descendants. See Steps. QC Entry 58864 // Francois Piette The behaviour is the same in Delphi 7 so the issue exists for years. I attached the sample project.

(See attached project) 1. Create a new form. 2. Drop a TComboBox, a TButton, and a TMemo onto the form. 3. Add a private method to the form class, and implement it: private procedure TestStrings(AStrings: TStrings); procedure TForm1.TestStrings(AStrings: TStrings); var Idx: Integer; begin AStrings.Clear; AStrings.Add('Foo'); AStrings.Add('Bar'); AStrings.Add(''); AStrings.Add('Baz'); Memo1.Lines.Add('Using ' + AStrings.ClassName + ':'); for Idx := 0 to AStrings.Count - 1 do begin Memo1.Lines.Add(Format(' Item ''%s'': index %d', [AStrings[Idx], AStrings.IndexOf(AStrings[Idx])])); end; Memo1.Lines.Add(''); end; 4. Add a handler for the button's OnClick event, and implement it: procedure TForm1.Button1Click(Sender: TObject); var StringList: TStringList; begin Memo1.Lines.Clear; TestStrings(ComboBox1.Items); StringList := TStringList.Create; try TestStrings(StringList); finally FreeAndNil(StringList); end; end; 5. Run the program and click the button. Expected: the output for the TComboBoxStrings and the TStringList should be identical. Both should be able to find the empty string that's in the list. Actual: TStringList.IndexOf is successfully able to find '', but TComboBoxStrings.IndexOf fails, incorrectly returning -1 even though '' is in the list. Actual output: Using TComboBoxStrings: Item 'Foo': index 0

Item 'Bar': index 1 Item '': index -1 Item 'Baz': index 3 Using TStringList: Item 'Foo': index 0 Item 'Bar': index 1 Item '': index 2 Item 'Baz': index 3

QC #: 59310 - Status: Closed

QC #: Project Date Reported: Area: 59310 Delphi 3/10/2008 RTL\Delphi\DateUtils Description Steps:[QC Short Description] Error on SecondsBetween routine [QC Description] The SecondsBetween routine don t return the correct value for some input values. Probably other similar routines such as MilliSecondsBetween is bugged too QC Entry 59310

Try this code SecondsBetween(0, EncodeTime(0, 0, 11, 0)) It should return 11 seconds, but the result of the routine is 10, this happens because the SecondsBetween routine uses Trunc: Result := Trunc(SecondSpan(ANow, AThen)); In this case we have a precision problem To resolve this problem the routine should use Round instead of Trunc Result := Round(SecondSpan(ANow, AThen)); I have tested the new routine (With round) with a lot of input values and all were correct, using Trunc a lot of input values was wrong

QC #: 60021 - Status: Closed

QC #: Project Date Reported: Area: 60021 C++Builder 3/27/2008 IDE Description Steps:[QC Short Description] New Forms App does not autocreate main form if autocreate forms is turned off [QC Description] This is a regression to a bug that was previously fixed. A new C++ forms app does not include the code to autocreate the main form if autocreate forms is turned off. App will run, but main form is not displayed. The main .cpp file that is created looks like this: //--------------------------------------------------------------------------- #include <vcl.h> #pragma hdrstop //--------------------------------------------------------------------------- USEFORM("Unit12.cpp", Form12); //--------------------------------------------------------------------------- WINAPI WinMain(HINSTANCE, HINSTANCE, LPSTR, int) { try { Application->Initialize(); Application->MainFormOnTaskBar = true; Application->Run(); } catch (Exception &exception) { Application->ShowException(&exception); }

Tools | Options | Environment Options | VCL Designer | Module Creation Options | Auto create forms and data modules - uncheck this option OK File | New | VCL Forms app - C++ Run | Run Exp: Project will compile, run and display a blank main form Act: Project compiles, runs, and exits without ever showing the main form. Look at Project1.cpp file in editor Exp: File will create the main form with a line like this: Application->CreateForm(__classid(TForm1), &Form1); Act: Line to create the main form is missing

catch (...) { try { throw Exception(""); } catch (Exception &exception) { Application->ShowException(&exception); } } return 0; } //--------------------------------------------------------------------------- Note that there is no Application->CreateForm() call. QC Entry 60021

QC #: 60329 - Status: Closed

QC #: Project Date Reported: Area: 60329 C++Builder 4/3/2008 Compiler\C++ Description Steps:[QC Short Description] internal compiler error [QC Description] The sample program included in the the steps triggers an internal compiler error. Note that the snippet looks somewhat unusual (including #pragma push without pop etc.) because it was reduced automatically from a large prreprocessed source. While the original source would crash even with some modifications, this reduced code seem to be fragile, i.e. tiny changes make the crash go away. QC Entry 60329

bcc32 -c qc60329.cpp res: CodeGear C++ 6.10 for Win32 Copyright (c) 1993, 2008 CodeGear qc60329.cpp: Fatal F1004 qc60329.cpp 25: Internal compiler error at 0x48e6cc with base 0x4000 00 Fatal F1004 qc60329.cpp 25: Internal compiler error

QC #: 60420 - Status: Closed

QC #: Project Date Reported: Area:60420 Delphi 4/4/2008 Documentation\IDE Help Contexts

Description Steps:[QC Short Description] RaiseList not properly documented [QC Description] ms-help://borland.bds5/delphivclwin32/!!FUNCTIONS_System.html only says about RaiseList: "This is System.RaiseList" (at least in the german version) QC Entry 60420

QC #: 60492 - Status: Closed

QC #: Project Date Reported: Area: 60492 Delphi 4/6/2008 VCL Description Steps:

[QC Short Description] Adding images to TImage list shows them on the wrong place [QC Description] Adding single immages to a TImageList via it's editor doesn't show them always as the end but as first image when there are already enough images in the list to require a scroll bar. Exp.: add them at the end and scroll there QC Entry 60492

1. create a empty project 2. place a TImageList onto the form 3. start adding images to it one by one until the scrollbar appears You'll notice that first the images are placed in the list in the correct order but as soon as the scrollbar appears things start to fall appart. Especially when using PNG images (16x16 from the Glyph FX collection supplied, e.g. Cut Clipboard icons)

QC #: 60500 - Status: Closed

QC #: Project Date Reported: Area: 60500 Delphi 4/6/2008 Documentation Description Steps:[QC Short Description] TGridPanel.ExpandStyle not describing the different values [QC Description] The description of TGridPanel.ExpandStyle describes the overall purpose of this property, but not how the three ways the individual possible values assignable to it work. This is at leas in the german version QC Entry 60500

1. Open the help page for TGridPanel.ExpandStyle 2. read the topic and wonder what the values mean you can assign to it

QC #: 60550 - Status: Closed

QC #: Project Date Reported: Area: 60550 C++Builder 4/7/2008 Compiler\C++\Back End Description Steps:[QC Short Description] Internal backend error W582 [QC Description] Compiling the following fragment of code causes the compiler to crash with the error: Internal backend error W582 compiling w582.cpp(12) template<typename T> struct Exception { }; template<class T> struct Alpha { virtual void banana() { throw Exception<int>(); } }; void pineapple() { Alpha<float> items; } int main() { try {

bcc32 -c w582.cpp Expected result: clean compile Actual result: CodeGear C++ 5.93 for Win32 Copyright (c) 1993, 2007 CodeGear w582.cpp: Internal backend error W582 compiling w582.cpp(12) *** 1 errors in Compile ***

} catch (Exception<int> & ex) { }; } QC Entry 60550 C++ Templates

QC #: 60588 - Status: Closed

QC #: Project Date Reported: Area:60588 Delphi 4/8/2008 Documentation\IDE Help Contexts

Description Steps:[QC Short Description] SysAllocMem not properly described [QC Description] ms-help://borland.bds5/delphivclwin32/!!FUNCTIONS_System.html only says "This is System.SysAllocMem". QC Entry 60588

QC #: 60611 - Status: Closed

QC #: Project Date Reported: Area:60611 Delphi 4/8/2008 Documentation\Online Help\VCL Description Steps:[QC Short Description] About MaxLength [QC Description] ms-help://borland.bds6/delphivclwin32/StdCtrls_TEdit_MaxLength.html Such as Surrogate pair, 1 character becomes 2 words. ( character <> word ) When MaxLength is 2, only one Surrogate pair can be stored. See Also: http://qc.codegear.com/wc/qcmain.aspx?d=48487 QC Entry 60611

================== seems to be fixed in 2010: http://docwiki.embarcadero.com/VCL/en/StdCtrls.TCustomEdit.MaxLength

QC #: 60651 - Status: Closed

QC #: Project Date Reported: Area: 60651 Delphi 4/9/2008 IDE\Class Completion Description Steps:[QC Short Description] Class completion failure with generics [QC Description] When playing with Generics using the steps outlined, I get a failure on pressing Ctrl Shift C. The message was: 'expected ')' but '<' found'

Open attached project. Try to invoke class completion for this class: test<T> = class(TInterfacedObject,IDictionary<T>,IEnumerable<T>)function GetEnumerator: IEnumerator<T>; function IDictionary<T>.GetEnumerator = IDGetEnumerator; function IDGetEnumerator: IDictionaryEnumerator<T>;

QC Entry 60651

end;

QC #: 60757 - Status: Closed

QC #: Project Date Reported: Area: 60757 Delphi 4/10/2008 RTL\Delphi\Other RTL Description Steps:[QC Short Description] Remove VER_PLATFORM_WIN32_NT checks [QC Description] In SysUtils.pas I can find several checks for VER_PLATFORM_WIN32_NT to implement workarounds for Win9x/ME. Since Tiburon will only support Windows 2000 and later, these should be removed. Particularly the ones in WideUpperCase and WideLowerCase could end up being done very frequently. There are probably many more such checks in other units that need cleaning up. QC Entry 60757

QC #: 61201 - Status: Closed

QC #: Project Date Reported: Area:61201 Delphi 4/21/2008 Documentation\IDE Help Contexts

Description Steps:[QC Short Description] IStringsAdapter topic useless [QC Description] ms-help://borland.bds5/delphivclwin32/Classes_IStringsAdapter.html only says "This is IStringsAdapter" QC Entry 61201

QC #: 61378 - Status: Closed

QC #: Project Date Reported: Area:61378 Delphi 4/24/2008 IDE\Project Management\Project Manager

Description Steps:[QC Short Description] Please add Alphabetize option/options to PM and eliminate all forced alphabetization [QC Description] Please eliminate all automatic and uncontrollable alpahabetization in Project Manager for all personalities. Currently in Delphi alphabetization is automatic and enforced at all times. I prefer to keep libs, resource files, etc together at the bottom of the list since I cannot edit thes files in the IDE. Others may wish to group files by topic. PM does not allow reording files at all in the Delphi personality. In C++, the situation is worse because the order of files in PM controls the build order. User can drag and drop files into a different order, but

see QC61372 and QC61376 for steps showing unexpected behavior in C++ personality.

the files are realphabetized every time a new file is added to the project QC61376 or when the view is changed QC61372. I would like to see all forced reordering of the PM file list eliminated and optional alphabetization implemented instead. Ideally this would include an option to alphabetize now as well as an option to turn on automatic alphabetization as currently enforced in Delphi. QC Entry 61378

QC #: 61412 - Status: Closed

QC #: Project Date Reported: Area: 61412 Delphi 4/25/2008 VCL\Graphics Description Steps:[QC Short Description] TJPEGimage can't read CMYK images [QC Description] If TJPEGimage loads an image with CMYK it crashes with an AV, sometimes the application crashes to. The implementation of IJG does it but the pascal let it crash. QC Entry 61412

Load an JPEG image with CMYK in TJPEGimage and force TJPEGimage to create its internal bitmap (for example let it draw)

QC #: 61594 - Status: Closed

QC #: Project Date Reported: Area:61594 C++Builder 4/30/2008 ActiveX\Code Generators\C++

Description Steps:This Should be fixed for both C++ & Delphi. [QC Short Description] Inability to over-ride imported component names can cause conflict [QC Description] When importing a type library, under at least some previous versions of C++ Builder, it was possible to over-ride the names of the components that would be created. This allows name conflicts to be avoided. However, with C++ Builder 2007, the "Component" > "Import Component" > "Import a type library" wizard tells you what the names are going to be, and does not provide any mechanism to override the names - even if they are clearly in conflict with existing components. For example, when importing the "Microsoft ADO Ext 2.8 for DDL and Security", the suggested names include TTable and TColumn. In at least one previous C++ Builder version, it was possible to override these names (for example, to TADOXTable and TADOXColumn) and so allow the "components" to install without any name conflicts. As it now stands, no ability to override names exists, no conflicts are reported and the conflictingly named "components" are simply silently omitted when the package is installed. It is not possible to simply generate the files and then change the names in the wrapper as the wizard pre-builds the corresponding DCR file, and this has the conflicting component names compiled in. While the example given in the "Steps" is somewhat artificial as this functionality exists in other areas, it serves as a practical example of why the need to be able to override the names exists. QC Entry 61594

Open C++ Builder 2007. Select "Components" from the menu. Click "Import Component". Select "Import a type library". Click "Next". From the list, select "Microsoft ADO Ext 2.8 for DDL and Security".Click "Next". The "Class Name(s)" box will now show "TTable, TColumn, TIndex, TKey, TGroup, TUser, TCatalog" - several of which are in conflict with existing components. The text will be greyed, and the names cannot be modified - unlike the memo field that was shown in C++ Builder 6. Tick "Generate Component Wrappers". Click "Next". ...etc ----- UPDATE --------- Can we bring back some of the functionality we had in D7 at all for this?

QC #: 61658 - Status: Closed

QC #: Project Date Reported: Area: 61658 Delphi 5/1/2008 RTL\Delphi\Pascal Strings Description Steps:[QC Short Description] Unicode AnsiLastChar and AnsiStrLastChar can step past first character [QC Description] When the Unicode versions of AnsiLastChar and AnsiStrLastChar are passed a string containing only a trailing surrogate character (#$DC00..#$DFFF), the functions return a pointer one character before the beginning of the string. The ANSI versions of the functions don't do this when passed only a trail byte. Also, similar to the ANSI versions, I believe they ought to verify that a leading surrogate (#$D800..#$DBFF) actually exists before decrementing Result. That way, a test like: StringEndsInX := (AnsiLastChar(S)^ = 'x'); won't be tricked into returning True if S = 'x'#DC00. Fixes: function AnsiLastChar(const S: UnicodeString): PWideChar; var Len: Integer; begin if S = '' then Result := nil else begin Len := Length(S); Result := @S[Len]; if (Len > 1) and (Result^ >= #$DC00) and (Result^ <= #$DFFF) and(Result[-1] >= #$D800) and (Result[-1] <= #$DBFF) then Dec(Result, 1); end; end; function AnsiStrLastChar(P: PWideChar): PWideChar; var Len: Integer; begin Len := StrLen(P); Result := @P[Len - 1]; if (Len > 1) and (Result^ >= #$DC00) and (Result^ <= #$DFFF) and(Result[-1] >= #$D800) and (Result[-1] <= #$DBFF) then Dec(Result, 1); end; Optimization notes: - For smaller code size, I changed the "Length(S) = 0" check in AnsiLastChar to "S = ''". - I'm storing the string length in a local variable (register) to avoid making multiple calls to Length/StrLen. QC Entry 61658

Compile and run the attached application below. See the following program output indicating failure. FAIL #1 FAIL #3 FAIL #5 program BTS259960; {$APPTYPE CONSOLE} uses SysUtils; var Counter: Integer = 0; Position: Integer = 0; procedure Assert(Expr: Boolean); begin Inc(Position); if Expr then Inc(Counter) else Writeln('FAIL #', Position); end; procedure DoIt; var S: String; P: PChar; begin // Test trailing surrogate only cases S := #$DC00; P := PChar(S); Assert(AnsiLastChar(S) = @S[1]); //#1 Assert(AnsiStrLastChar(P) = P); //#2 // Test trailing surrogate + missing leading surrogate cases S := 'x'#$DC00; P := PChar(S); Assert(AnsiLastChar(S) = @S[2]); //#3 Assert(AnsiStrLastChar(P) = P+1); //#4 // Test valid surrogate pair cases S := #$D800#$DC00; P := PChar(S); Assert(AnsiLastChar(S) = @S[1]); //#5 Assert(AnsiStrLastChar(P) = P); //#6 // Test empty string cases S := ''; P := PChar(S); Assert(AnsiLastChar(S) = nil); //#7 Assert(AnsiStrLastChar(P) = P-1); //#8 the ANSI version returns P-1 in this case too... end; begin try DoIt; except on E: Exception do WriteLN('FAIL Exception=', E.ClassName, '/', E.Message);

end; end.

QC #: 61675 - Status: Closed

QC #: Project Date Reported: Area: 61675 Delphi 5/2/2008 RTL\Delphi\DateUtils Description Steps:[QC Short Description] Wrong return from MinutesBetween [QC Description] MinutesBetween function in DateUtils unit return wrong result in some cases. QC Entry 61675

program BTS259980; {$APPTYPE CONSOLE} uses DateUtils, SysUtils; var Counter: Integer = 0; procedure DoIt; var d1: TDateTime; d2: TDateTime; Minutes: Integer; begin d1 := StrToTime('10:15'); d2 := StrToTime('10:20'); Minutes := MinutesBetween(d1, d2); if Minutes = 5 then Inc(Counter) else WriteLn('FAIL #1'); d1 := StrToTime('10:30'); d2 := StrToTime('10:35'); Minutes := MinutesBetween(d1, d2); if Minutes = 5 then Inc(Counter) else WriteLn('FAIL #2'); d1 := StrToTime('10:30'); d2 := StrToTime('10:31'); Minutes := MinutesBetween(d1, d2); if Minutes = 1 then Inc(Counter) else WriteLn('FAIL #3'); if Counter = 3 then WriteLn('PASS'); end; begin try DoIt; except on E: Exception do WriteLN('FAIL Exception=', E.ClassName, '/', E.Message); end; end.

QC #: 61756 - Status: Closed

QC #: Project Date Reported: Area:

61756 C++Builder 5/5/2008 RTL\C++\Math Description Steps:[QC Short Description] modf(float,float*) gives incorrect result [QC Description] The modf(float __x,float *__y) implementation in math.h sets *__y to wrong value. The inline implementation is { return (float) modf((double)__x,(double*)__y); }. When the double precision modf function writes to __y there is going to be a problem, since y really points to a float. Attached code: #include <cmath> #include <iostream> int main() { float a; float b( std::modf(1.5f, &a) ); std::cout << a; return b; } QC Entry 61756

download attachment bcc32 qc61756.cpp qc61756 Exp: 1 Act: 0

QC #: 61818 - Status: Closed

QC #: Project Date Reported: Area:61818 C++Builder 5/6/2008 Compiler\C++\Front End\Templates

Description Steps:[QC Short Description] Template partial specialization fails [QC Description] The supplied code fails to compile. Comeau compiles this. Attached code: template <typename T> class TestA { public: template <typename C> void f(); }; template <> template <typename C> void TestA<double>::f() {} QC Entry 61818 [Top 10] 15 Votes C++ Templates

download attachment bcc32 -c qc61818.cpp Exp: Clean compile Act: Error E2299 qc61818.cpp 10: Cannot generate template specialization from 'TestA<double>::f<C>()' Error E2316 qc61818.cpp 10: 'TestA<double>::f()' is not a member of 'TestA<double>'

QC #: 62313 - Status: Closed

QC #: Project Date Reported: Area:

62313 Delphi 5/19/2008 Documentation\IDE Help Contexts

Description Steps:

[QC Short Description] Help for TToolbutton EnableDropdown not usefull [QC Description] In ms-help://borland.bds5/delphivclwin32/ComCtrls_TToolButton_EnableDropdown.html there's only the text that "This is..." but no description about the real function of the property. QC Entry 62313

QC #: 62524 - Status: Closed

QC #: Project Date Reported: Area: 62524 C++Builder 5/24/2008 Compiler\C++\Front End

Description Steps:[QC Short Description] Boost related Internal Compiler Error (conversion\lexical_cast_test) [QC Description] Compiling the enclosed preprocessed source results in the following error message: Fatal F1004 QC62524.i 55801: Internal compiler error at 0x46574d with base 0x400000 in function operator lexical_stream_limited_src<char,lexical_streambuf_fake, std::char_traits<char> >::<<(int) Fatal F1004 QC62524.i 55801: Internal compiler error in function operator lexical_stream_limited_src<char,lexical_streambuf_fake,std::char_traits<char>>::<<(int) QC Entry 62524 [Top 10] 15 Votes

bcc32 -c -P QC62524.i exp: completed compilation, possibly with errors act: internal compiler error

QC #: 62544 - Status: Closed

QC #: Project Date Reported: Area: 62544 C++Builder 5/25/2008 Compiler\C++\Front End Description Steps:[QC Short Description] Boost related Internal Compiler Error (dynamic_bitset\dyn_bitset_unit_tests1) [QC Description] Compiling the attached preprocessed file results in an ICE. Note that the conditions that lead to the error are narrow: I don't get an ICE from the IDE, nor from the CodeBlocks open source IDE. Unfortunately I haven't been able to better identify what causes the problem. the error message is the following: Fatal F1004 qc62544.i 46853: Internal compiler error at 0x46574d with base 0x400000 in function void run_test_cases<unsigned char>()Fatal F1004 qc62544.i 46853: Internal compiler error in function void run_test_cases<unsigned char>() QC Entry 62544 [Top 10] 15 Votes

bcc32 -c -P qc62544.i exp: Complete compile, possibly with errrors. act: Internal compiler error

QC #: 62545 - Status: Closed

QC #: Project Date Reported: Area: 62545 C++Builder 5/25/2008 Compiler\C++\Front End Description Steps:[QC Short Description] Boost related ICE (iostreams\array_test) [QC Description] The attached preprocessed source causes an internal compiler error with the following message: Fatal F1004 qc62545.i 177061: Internal compiler error at 0x46574d with base 0x400000 in function array_test() Fatal F1004 qc62545.i 177061: Internal compiler error in function array_test() QC Entry 62545 [Top 10] 15 Votes

bcc32 -P qc62545.i

QC #: 62562 - Status: Closed

QC #: Project Date Reported: Area: 62562 Delphi 5/25/2008 Database\DBExpress Description Steps:[ASE] [QC Short Description] Memory leak when ExecSQL using dbexpress TSQLconnection / TSQLQuery with ASE (dbxase30.dll) [QC Description] When using dbxpress TSQLConnection / TSQLQuery with Sybase ASE (using dbxase30.dll) in Deplhi 2007, a memory leak occurs with each call to ExecSQL. The issue appears to be related to dbxase30.dll (Sybase ASE), as the same test application does not produce a memory leak if the TSQLConnection is instead associated with the 3rd party dbexpca400.dll (from Peter Sawatzki) and connected to an AS/400 database. Including "ReportMemoryLeaksOnShutdown:=true;" in the test application FormCreate, does not report any memory leaks on shutdown, despite the application having consumed and not released additional memory for each ExecSQL call. The leaked memory is also not released even after Free'ing the TSQLQuery object that was used to invoke the ExecSQL call (perhaps further confirming the issue exists with dbxase30.dll?). The memory is only released upon termination of the application. QC Entry 62562

TDBXWeaverBugsSuite.Native.DB.Test.exe connection=aseconnection -s:TestRaid_260834 -or- Simple Delphi 2007 test application source is attached which reproduces the problem. This establishes runtime TSQLConnection and TSQLQuery component, and attempts to truncate then write 1000 unique records to a database table called dse_trpprc, which comprises two char fields (trp, prctyp). This can be easily changed to any table name / field names in the source. Note that using VCL components at design time, or creating runtime components for TSQLConnection or TSQLQuery makes no difference.Example output from the dbxase30.dll ASE connection using the test application is as follows (demonstrating a memory leak): -- Start Mem: 3,988 K - End Mem: 6,204 K - Consumed: 2,216 K Start Mem: 6,212 K - End Mem: 6,216 K - Consumed: 4 K Start Mem: 6,216 K - End Mem: 6,220 K - Consumed: 4 K Start Mem: 6,220 K - End Mem: 6,228 K - Consumed: 8 K Start Mem: 6,228 K - End Mem: 6,232 K - Consumed: 4 K Start Mem: 6,232 K - End Mem: 6,240 K - Consumed: 8 K Start Mem: 6,240 K - End Mem: 6,244 K - Consumed: 4 K Start Mem: 6,244 K - End Mem: 6,252 K - Consumed: 8 K etc. -- Conversely, if the TSQLConnection is changed to use dbexpca400.dll / dbxadapter30.dll to connect to an AS/400 database (instead of Sybase ASE), the following output is logged (noting no memory leak - only the initial component memory consumption): -- Start Mem: 3,256 K - End Mem: 6,504 K - Consumed: 3,248 K Start Mem: 6,508 K - End Mem: 6,512 K - Consumed: 4 K Start Mem: 6,512 K - End Mem: 6,516 K - Consumed: 4 K Start Mem: 6,516 K - End Mem: 6,516 K - Consumed: 0 K Start Mem: 6,516 K - End Mem: 6,516 K - Consumed: 0 K Start Mem: 6,516 K - End Mem: 6,516 K - Consumed: 0 K Start Mem: 6,516 K - End Mem: 6,516 K - Consumed: 0 K Start Mem: 6,516 K - End Mem: 6,516 K - Consumed: 0 K Start Mem: 6,516 K - End Mem: 6,516 K - Consumed: 0 K Start Mem: 6,516 K - End Mem: 6,516 K - Consumed: 0 K etc. --

QC #: 62714 - Status: Closed

QC #: Project Date Reported: Area: 62714 C++Builder 5/29/2008 Compiler\C++\Back End Description Steps:[QC Short Description] F1001 Internal code generation error with templates [QC Description] The following template code should return one or more diagnostics on compile, but instead it causes an ICE when compiled in debug mode. Commented lines do not result in errors, and if compiled withot the -v flag the compiler emits a proper diagnostic. class AnsiString { public: AnsiString( const char* ); }; namespace XXXX { template <class T> struct PFuncSelector { typedef T ResultType; }; template< typename T > inline PFuncSelector<T>::ResultType pippo_fun( const T& defval ) { return PFuncSelector<T>::ResultType(); } } int main() { // char * p = "pippo"; // AnsiString q = XXXX::pippo_fun(p); // int i = XXXX::pippo_fun(1); AnsiString res = XXXX::pippo_fun("Pluto"); return 0; } QC Entry 62714

download attachment bcc32 -c -v qc62714.cpp Exp: Error E2034 qc62714.cpp 17: Cannot convert 'char *' to 'char[6]' in function char[6] pippo_fun<char[6]>(char ( &) const[6]) Act: Internal backend error C10358 compiling qc62714.cpp(29) or, in IDE: [BCC32 Error] qc62714.cpp : F1001 Internal code generator error When compiled without the -v flag the expected diagnostic is emitted.

QC #: 63088 - Status: Closed

QC #: Project Date Reported: Area: 63088 Delphi 6/9/2008 VCL Description Steps:[QC Short Description] Missing INLINE opportunities [QC Description] Control.TWinControl.DisableAlign seems like a good INLINE candidate. Control.TWinControl.GetParentBackground seems like a good INLINE candidate. Graphics.TBrush.GetColor seems like a good INLINE candidate. Graphics.TBrush.GetStyle seems like a good INLINE candidate.

Graphics.TPen.GetColor seems like a good INLINE candidate. Graphics.TPen.GetWidth seems like a good INLINE candidate. Graphics.TFont.GetStyle seems like a good INLINE candidate. Graphics.TFont.GetHeight seems like a good INLINE candidate. Forms.TScreen.GetFormCount seems like a good INLINE candidate. Forms.TScreen.GetCustomFormCount seems like a good INLINE candidate. QC Entry 63088

QC #: 63089 - Status: Closed

QC #: Project Date Reported: Area: 63089 Delphi 6/9/2008 RTL Description Steps:[QC Short Description] Missing INLINE opportunities [QC Description] System.TObject.ClassType seems like a good INLINE candidate. System.TObject.ClassInfo seems like a good INLINE candidate. Classes.TCollection.GetCount seems like a good INLINE candidate. Types.Point seems like a good INLINE candidate. Types.RectWidth and Types.RectHeight seem like good INLINE candidates and are in fact marked INLINE, but only in the IMPLEMENTATION and neither are in fact inlined e.g. when called from Controls.TCustomHint.SetHintSize. QC Entry 63089

QC #: 63090 - Status: Closed

QC #: Project Date Reported: Area: 63090 Delphi 6/9/2008 RTL Description Steps:[QC Short Description] Sub-optimal code [QC Description] Classes.Point calls Types.Point, which has the same signature. However, this call-shell in Classes for Types.Point actually winds up being 4 times as many bytes (24 vs 6) as the called routine (Types.Point). From a performance and code size standpoint, it would be better to simply have a copy of Types.Point in Classes. However, note also that Types.Point seems like a good INLINE candidate (see also QC# 63088). Similarly, Classes.Rect calls Types.Rect. Here, the difference in size isn't quite as pronounced: 38 bytes for the call-shell vs 24 bytes for the routine called. For Types.SplitRect (both variations), the Rect argument should get a const prefix as it's non-trivial and not modified. For Types.CenteredRect, both the SourceRect and the CenteredRect arguments should get const prefixes as they're not modified.

QC Entry 63090

QC #: 63172 - Status: Closed

QC #: Project Date Reported: Area:63172 Delphi 6/11/2008 IDE\Code Editor\Error Insight Description Steps:[QC Short Description] Error Insight incorrectly identifies errors when there are none (when global variable and member names match) [QC Description] There have been several reports of Error Insight underlining an 'error' with red squiggles, and adding an entry to the 'Errors' list - when there is no error and the code compiles correctly. Traditionally they've been hard to track down and provide steps. I've finally managed to identify complete, simple steps to provoke Error Insight into misbehaving - at least in the latest version of Tiburon. Basically, if your code creates an instance of an object which has a published property with the same name as a previously declared global (object) variable, Error Insight will incorrectly display errors. See steps... QC Entry 63172

1. Create a new VCL Forms application. Add an OnShow handler to the main form - like this: procedure TForm1.FormShow(Sender: TObject); begin Application.ProcessMessages end; 2. Add a new unit to the project (File/New/Unit - Delphi for Win32). Make it declare an object with a published property, with the same name as the 'Application' global variable refered to in step 1 - like this: unit Unit2; interface type TTest = class private fApplication: string; published property Application : string read fApplication write fApplication; end; implementation end. 3. Add a reference to Unit2 from the 'interface' section of the application's main form unit, and modify the application's main form object so that it declares a private variable of type TTest. The full source for the application's main form unit should now look like this: unit Unit1; interface uses Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms, Dialogs, Unit2; type TForm1 = class(TForm) procedure FormShow(Sender: TObject); private fTest : TTest; { Private declarations } public { Public declarations } end; var Form1: TForm1; implementation {$R *.dfm} procedure TForm1.FormShow(Sender: TObject); begin Application.ProcessMessages end; end. 4. Notice how when you do this, the 'ProcessMessages' in the Application.ProcessMessages line gets underlined with a red squiggle, and an error appears "'string' does not contain a member function named "ProcessMessages" 5. If you comment out the 'fTest:TTest' line, the message disappears. If you un-comment it, it reappears, and so on until you're bored.

QC #: 63187 - Status: Closed

QC #: Project Date Reported: Area: 63187 Delphi 6/11/2008 RTL\Delphi\Pascal Strings Description Steps:[QC Short Description] _UStrToPWChar change makes PChar(emptystring)^ writable [QC Description] The _UStrToPWChar fix that went into build 3097 for the PChar(emptystring) alignment issue is somewhat of a disappointment. To achieve proper alignment, the empty string structure was moved into a "const" record. As noted in the source, however, this has the undesirable side effect of making the string writable. This now executes successfully: var S: string; begin S := ''; PChar(S)^ := 'x'; end; whereas in all previous Delphi versions, it raised an AV immediately. Without the AV, it becomes much more difficult to track down what is trying to overwrite the character, and all but impossible for a program to continue operating normally following such an attempt. There are two other ways the alignment problem could be solved without making the string writable:

Compile and run the attached application below. See the following program output indicating failure. FAIL program BTS260978; {$APPTYPE CONSOLE} uses SysUtils; var Counter: Integer = 0; procedure DoIt; var S: string; begin try S := ''; PChar(S)^ := 'x'; WriteLn('FAIL'); except

1) Place the empty string structure in a function of its own. All 32-bit versions of Delphi align functions on DWORD boundaries. (The compiler/linker does this by inserting dummy "NOP", "MOV EAX,EAX", and "LEA EAX,[EAX+0]" instructions for 1, 2, and 3 bytes of padding, respectively.) 2) Store the empty string structure within a UnicodeString constant. String data is always DWORD-aligned, and always stored in the read-only code segment. Code attached on Workaround tab. QC Entry 63187

WriteLn('PASS'); end; end; begin try DoIt; except on E: Exception do WriteLN('FAIL Exception=', E.ClassName, '/', E.Message); end; end.

QC #: 63194 - Status: Closed

QC #: Project Date Reported: Area: 63194 Delphi 6/11/2008 IDE\Project Management\ Description Steps:[QC Short Description] No project option to change the value of the $INLINE directive [QC Description] There is no project options dialog setting to modify the value of the $INLINE directive. There should be a dropdown to select between one of these: {$INLINE OFF} {$INLINE AUTO} {$INLINE ON} QC Entry 63194

File, New, VCL Win32 Application Project, Options No inline setting is present in the Compiling/Linking areas

QC #: 63245 - Status: Closed

QC #: Project Date Reported: Area: 63245 Delphi 6/13/2008 IDE\Code Editor Description Steps:[QC Short Description] SHIFT+CTRL+UP OR DOWN dont always work on overided class operators [QC Description] A coluege came and asked me about this bug. If you only have a class operator in a record, SHIFT+CTRL+UP or DOWN will not work properly. However, if you also add a function to the record, then it will start working. I have only tested this on Delphi 2007. It's easy to reproduce, and I don't think it's very critical from a functional pov, but it is one bug among others that makes my coluege wonder about how stable the D2007 is, and he is supposed to recommend the product for our managers... :/ best regards Niclas QC Entry 63245

unit Unit1; interface uses Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms, Dialogs; type TMyRec = record // SHIFT+CTRL+ARROW DOWN will not work on Add class operator Add(A, B : Integer) : Integer; end; TForm1 = class(TForm) private { Private declarations } public { Public declarations } end; var Form1: TForm1; implementation {$R *.dfm} class operator TMyRec.Add(A, B : Integer) : Integer; Begin Result := A + B; End; end.

QC #: 63328 - Status: Closed

QC #: Project Date Reported: Area:

63328 Delphi 6/15/2008 Compiler\Delphi\Code Generation/Optimization

Description Steps:[QC Short Description] _EnsureXXXStrings should be moved to the C++ side, better Delphi string performance [QC Description] The _EnsureXXXString calls should be moved to the C++ side so they do not harm all Delphi developers. These calls slow down every single string access and they are only required if the string comes from the C++ code. So, why not move all these _EnsureXXXString calls into the generated .hpp files? Every function that has a string parameter could call a stub that does the _EnsureXXXString call and then calls the actual Delphi function. This way all Delphi developers would be let alone with this performance hit. QC Entry 63328

(by Pierre le Riche) Consider the following example, used to count the number of occurrences of a given character in a string: function CountChars(const MyStr: AnsiString; TheChar: AnsiChar): Integer; var i: Integer; begin Result := 0; for i := 1 to Length(MyStr) do begin if MyStr[i] = TheChar then Inc(Result); end; end; This code compiles to 40 bytes under Delphi 2007 and executes in 171 clock cycles with an input string of length 10. Compare this to the same scenario under Tiburon: It compiles to 141 bytes and takes 351 clock cycles for the same input. So, the example above is 3.5 times larger and it takes twice as long to execute when compiled with Tiburon. If there was a compiler directive to switch off those _EnsureXXXString calls the performance would be similar.

QC #: 63396 - Status: Closed

QC #: Project Date Reported: Area: 63396 Delphi 6/17/2008 IDE\Search\Find Description Steps:[QC Short Description] [Request] Add Search Previous (SC : Shift + F3) [QC Description] Current IDE has Search Next (SC : F3) , but doesn't have Search Previous(SC : Shift + F3). (Search Previous to say here is searching inverse direction of Search Next) So the users need to open Find Dialog to change Search Direction whenever they want to search previous. Many IDEs support this function and it is so easy to implement. QC Entry 63396

QC #: 63454 - Status: Closed

QC #: Project Date Reported: Area:63454 Delphi 6/18/2008 RTL\Delphi\Format + Float Description Steps:[QC Short Description] Format('%*s', [-10, 'hallo'] does not work [QC Description] Format uses negative width specifier to left align a string within that width: Format('%-10s', ['hallo']) -> 'hallo ' Format('%10s', ['hallo']) -> ' hallo' This works fine, but using the * placeholder for the width, as described in the online help, results in an access violation: Format('%*s', [10, 'hallo']) -> ' hallo' Format('%*s', [-10, 'hallo']) -> crashes

Compile and run the attached test case below. See the following program output indicating failure. FAIL #5 Exception=EAccessViolation/Access violation at address 004057A5 in module 'QC63454.exe'. Write of address 00000004 program BTS261138; {$APPTYPE CONSOLE} uses SysUtils; var Counter: Integer = 0;

QC Entry 63454 procedure DoIt; var S: String; begin S := Format('%-10s', ['hallo']); // -> 'hallo ' if S = 'hallo ' then Inc(Counter) else WriteLn('FAIL #1 S=', S); S := Format('%10s', ['hallo']); // -> ' hallo' if s = ' hallo' then Inc(Counter) else WriteLn('FAIL #2 S=', S); //This works fine, but using the * placeholder for the width, as described in the online help, results in an access violation: S := Format('%*s', [10, 'hallo']); // -> ' hallo' if S = ' hallo' then Inc(Counter) else WriteLn('FAIL #3 S=', S); try S := Format('%*s', [-10, 'hallo']); // -> crashes if S = 'hallo ' then Inc(Counter) else WriteLn('FAIL #4 S=', S); except on E: Exception do WriteLn('FAIL #5 Exception=', E.ClassName, '/', E.Message); end; if Counter = 4 then WriteLn('PASS'); end; begin try DoIt; except on E: Exception do WriteLN('FAIL Exception=', E.ClassName, '/', E.Message); end; end.

QC #: 63505 - Status: Closed

QC #: Project Date Reported: Area: 63505 C++Builder 6/19/2008 Compiler\C++\Front End Description Steps:[QC Short Description] Error including mpl\map.hpp from Boost [QC Description] Including the map.hpp header from the Boost.Mpl library causes the following errors: Error E2109 count.i 28696: Not an allowed type Error E2404 count.i 28818: Dependent type qualifier 'if_<na,na,na>' has no member type named 'type' Error E2402 count.i 28818: Illegal base class type: formal type 'typename if_<C,F1,F2>::type' resolves to 'typename if_<C,F1,F2>::type' Error E2404 count.i 28977: Dependent type qualifier 'na' has no member type named 'first'

bcc32 -c -P 261220 res: CodeGear C++ 6.10 for Win32 Copyright (c) 1993-2008 CodeGear 261220.i: Error E2435 261220.i 38: Too many template parameter sets were specified Error E2293 261220.i 43: ) expected Error E2396 261220.i 32: Template argument must be a constant expression Fatal F1004 261220.i 32: Internal compiler error at 0x5037c0 with base 0x400000 Fatal F1004 261220.i 32: Internal compiler error

Error E2404 count.i 28990: Dependent type qualifier 'na' has no member type named 'second' Error E2404 count.i 29768: Dependent type qualifier 'na' has no member type named 'next' Error E2404 count.i 29777: Dependent type qualifier 'na' has no member type named 'prior' Error E2404 count.i 30388: Dependent type qualifier 'na' has no member type named 'base' Error E2396 count.i 30873: Template argument must be a constant expression Fatal F1004 count.i 30873: Internal compiler error at 0x502aa8 with base 0x400000 Fatal F1004 count.i 30873: Internal compiler error QC Entry 63505

exp: no ICE

QC #: 63508 - Status: Closed

QC #: Project Date Reported: Area: 63508 C++Builder 6/19/2008 Compiler\C++\Front End Description Steps:[QC Short Description] Boost test fails to compile with -v option [QC Description] When compiled with the -v option the enclode example causes the following error: Error E2304 regex_test.i 236316: Constant variable '_Stz' must be initialized Compiling without -v succeeds. This is relevant because Boost uses the -v option. QC Entry 63508

bcc32 -w- -v -P regex_test.i exp: clean compile act: CodeGear C++ 6.10 for Win32 Copyright (c) 1993-2008 CodeGear regex_test.i: Error E2304 regex_test.i 236316: Constant variable '_Stz' must be initialized *** 1 errors in Compile ***

QC #: 63538 - Status: Closed

QC #: Project Date Reported: Area: 63538 C++Builder 6/20/2008 Compiler\C++\Back End Description Steps:[QC Short Description] ICE caused by PACKAGE specification in template function [QC Description] Not sure if this is a proper use for the PACKAGE specification, but I have seen similar code to this compile cleanly. If the code is not valid, however, the compiler should issue a diagnostic rather than an ICE. Note: - Compiles cleanly with the PACKAGE specification removed. - Compiles cleanly if Foo is a non-template function. Attached code: #include <system.hpp> template< class T > void Foo( const T& ) { class PACKAGE Bar {}; } int main()

Download attachment bcc32 -c qc63538.cpp Exp: Clean compile or proper diagnostic Act: Fatal F1004 file17.cpp 6: Internal compiler error at 0x4063aa with base 0x400000 in function void Foo<int>(const int &) Fatal F1004 file17.cpp 6: Internal compiler error in function void Foo<int>(const int &)

{ Foo( 0 ); return 0; } QC Entry 63538

QC #: 63883 - Status: Closed

QC #: Project Date Reported: Area: 63883 C++Builder 6/29/2008 Documentation Description Steps:[QC Short Description] Missing Object Repository Documentation [QC Description] How do I add an object to the Object Repository? Because this page: ms-help://borland.bds5/devwin32/idh_useop_usingtheobjectrepository_xml.html Sure doesn't tell me. Conveniently, that topic is the only disabled link. QC Entry 63883

QC #: 64139 - Status: Closed

QC #: Project Date Reported: Area: 64139 Delphi 7/5/2008 RTL\Delphi Description Steps:[QC Short Description] Wide StrUpper & StrLower optimization [QC Description] Wide StrUpper and StrLower would be 50-75% faster without calls to StrLen: function StrUpper(Str: PWideChar): PWideChar; var Ptr: PChar; begin Result := Str; Ptr := Str; while Ptr^ <> #0 do begin case Ptr^ of 'a'..'z': Ptr^ := WideChar(Word(Ptr^) and $FFDF); end; Inc(Ptr); end; end; function StrLower(Str: PWideChar): PWideChar; var Ptr: PChar; begin Result := Str; Ptr := Str; while Ptr^ <> #0 do begin case Ptr^ of 'A'..'Z': Ptr^ := WideChar(Word(Ptr^) or $0020); end;

N/A

Inc(Ptr); end; end; QC Entry 64139

QC #: 64150 - Status: Closed

QC #: Project Date Reported: Area: 64150 Delphi 7/6/2008 RTL\Delphi Description Steps:[QC Short Description] Warnings in RtlConsts.pas refer to non-existing file SysConsts.pas [QC Description] Warnings below in RtlConsts.pas refer to non-existing file SysConsts.pas. They should be corrected to refer to SysConst.pas, note the missing "s"! SInvalidDate = '''''%s'''' is not a valid date' deprecated 'Use SysConsts.SInvalidDate'; SInvalidDateTime = '''''%s'''' is not a valid date and time' deprecated 'Use SysConsts.SInvalidDateTime'; SInvalidInteger = '''''%s'''' is not a valid integer value' deprecated 'Use SysConsts.SInvalidInteger'; SInvalidTime = '''''%s'''' is not a valid time' deprecated 'Use SysConsts.SInvalidTime'; STimeEncodeError = 'Invalid argument to time encode' deprecated 'Use SysConsts.STimeEncodeError'; QC Entry 64150

QC #: 64258 - Status: Closed

QC #: Project Date Reported: Area: 64258 Delphi 7/9/2008 IDE\File Handling Description Steps:[QC Short Description] "View Unit" displays extra entries for some files [QC Description] This issue can be seen in complicated project groups when several projects use different files with the same name placed in different folders. For example, in my current project group I have 3 projects including "database.pas" file. Each project uses its own file placed in a separate folder. For this case "View Unit" displays 4 entries for "database.pas". This happens not with all files with coinciding names. Only some of them have this extra entry. QC Entry 64258

It is necessary to check "All files in project group" in order to see this issue.

QC #: 64276 - Status: Closed

QC #: Project Date Reported: Area:64276 Delphi 7/9/2008 IDE\Project Management\Project Manager

Description Steps:

[QC Short Description] Missing "View Source" CTRL+V shortcut in Project Manager popup menu [QC Description] In the Project Manager popup menu for a project is the shortcut CTRL+V for "View Source" missing - it is only "&Quelltext anzeigen" and not "&Quelltext anzeigen Strg+V". Well the shortcut does only work if you have selected project item, but it is a difference to the english version. A "nice" side effect of the missing shortcut is that you can add any actually existing file to the project. If you do that with the .dpr or .dproj file and try to remove it then you get this error --------------------------- Fehler --------------------------- Das Hauptmodul des Projekts kann nicht entfernt werden. --------------------------- OK Details >> --------------------------- QC Entry 64276

Steps for missing shortcut: - start german version of RAD Studio 2007 - create a new VCL application - select the project entry (Project1.exe) in the project manager - make sure the project source is closed - press CTRL+V expected: the project source would be opened actual: nothing happens - show the popup menu for the project entry in the project manager - look for "&Quelltext anzeigen" expected: the text is "&Quelltext anzeigen Strg+V" or "... Ctrl+V" (depends on the OS language) actual: the text is only "&Quelltext anzeigen" Steps for bad side effect: - start german version of RAD Studio 2007 - create a new VCL application - save the application for example as c:\CopyMeToClipboard.dproj - put "c:\CopyMeToClipboard.dproj" into the clipboard - select the project entry (CopyMeToClipboard.exe) in the project manager - press CTRL+V expected: nothing happens or the project source would be opened actual: CopyMeToClipboard.dproj will be added to the project - try to remove "CopyMeToClipboard.dproj" from the project --------------------------- Fehler --------------------------- Das Hauptmodul des Projekts kann nicht entfernt werden. --------------------------- OK Details >> ---------------------------

QC #: 64380 - Status: Closed

QC #: Project Date Reported: Area: 64380 Delphi 7/11/2008 Compiler\Delphi Description Steps:[QC Short Description] Excessive calls to InternalLStrFromUStr [QC Description] This code: procedure TForm1.Test(const S: UTF8string); begin Inc(X, Length(S)); Inc(X, Length(S)); end; compiles into: TypedStringsUnit.pas.200: begin 00466D54 55 push ebp 00466D55 8BEC mov ebp,esp 00466D57 51 push ecx 00466D58 53 push ebx 00466D59 8955FC mov [ebp-$04],edx 00466D5C 8BD8 mov ebx,eax 00466D5E 8B45FC mov eax,[ebp-$04] 00466D61 E8BAE4F9FF call @LStrAddRef 00466D66 33C0 xor eax,eax 00466D68 55 push ebp 00466D69 68EA6D4600 push $00466dea 00466D6E 64FF30 push dword ptr fs:[eax] 00466D71 648920 mov fs:[eax],esp TypedStringsUnit.pas.201: Inc(CacheLen, Length(S)); 00466D74 8B45FC mov eax,[ebp-$04] 00466D77 85C0 test eax,eax 00466D79 741A jz $00466d95 00466D7B 8BD0 mov edx,eax 00466D7D 83EA0A sub edx,$0a 00466D80 66833A01 cmp word ptr [edx],$01 00466D84 740F jz $00466d95 00466D86 8D45FC lea eax,[ebp-$04] 00466D89 66B9E9FD mov cx,$fde9 00466D8D 8B55FC mov edx,[ebp-$04]

00466D90 E85BE1F9FF call @InternalLStrFromUStr 00466D95 85C0 test eax,eax 00466D97 7405 jz $00466d9e 00466D99 83E804 sub eax,$04 00466D9C 8B00 mov eax,[eax] 00466D9E 0183AC030000 add [ebx+$000003ac],eax TypedStringsUnit.pas.202: Inc(CacheLen, Length(S)); 00466DA4 8B45FC mov eax,[ebp-$04] 00466DA7 85C0 test eax,eax 00466DA9 741A jz $00466dc5 00466DAB 8BD0 mov edx,eax 00466DAD 83EA0A sub edx,$0a 00466DB0 66833A01 cmp word ptr [edx],$01 00466DB4 740F jz $00466dc5 00466DB6 8D45FC lea eax,[ebp-$04] 00466DB9 66B9E9FD mov cx,$fde9 00466DBD 8B55FC mov edx,[ebp-$04] 00466DC0 E82BE1F9FF call @InternalLStrFromUStr 00466DC5 85C0 test eax,eax 00466DC7 7405 jz $00466dce 00466DC9 83E804 sub eax,$04 00466DCC 8B00 mov eax,[eax] 00466DCE 0183AC030000 add [ebx+$000003ac],eax TypedStringsUnit.pas.203: end; 00466DD4 33C0 xor eax,eax 00466DD6 5A pop edx 00466DD7 59 pop ecx 00466DD8 59 pop ecx 00466DD9 648910 mov fs:[eax],edx 00466DDC 68F16D4600 push $00466df1 00466DE1 8D45FC lea eax,[ebp-$04] 00466DE4 E807DFF9FF call @LStrClr 00466DE9 C3 ret The repeated calls to InternalLStrFromUStr seem excessive. In fact, they shouldn't be needed at all. Yes, I know that even though the parameter is declared as UTF8String, it could technically have a different payload, which could be Unicode or another code page. However, that should only happen if the programmer calls SetCodePage() explicitly. It should be the programmer's responsibility to make sure the payload eventually matches the declared type. I compare this with types that are integer ranges, e.g.: type MyRange = 42..123456; Technically, a variable of type MyRange can hold any integer. But it shouldn't. The compiler does not constantly try to coerce MyRange variables to fit the type. Instead, I have the option to turn on range checking to have the compiler help me catch bugs with incorrect MyRange values. Similarly, I'd like to have a compiler option that would insert an assertion at the start of each function to check that the payload the string passed to function matches the declared type. In my Test() procedure above, the assertion would be: Assert(StringCodePage(S) = CF_UTF8, 'Payload for S must be CF_UTF8'); For functions that return a string, the compiler would insert the same assertion at the end of the call to ensure that the returned string matches the declared type. RawByteString would be exempted from these checks. Also, using InternalLStrFromUStr does not guarantee Length() to return the correct result. If S is passed a CP1252 string instead of a UTF8 string, and the string includes non-ASCII characters, the

returned length will be different. E.g. if my function uses Length() to calculate how many bytes to allocate to save a string in UTF-8 format, but the string is encoded as CP1252, my function will not allocate enough bytes if the string includes characters >= #$80. If another function then writes to that buffer, and that function uses SetCodePage to forcibly convert to UTF-8, I'll be stuck with a mysterious buffer overrun. If instead the compiler added an assertion to my function, the assertion would have caught the incorrect payload. The bug would be obvious, which I could fix by either making the caller pass a proper UTF-8 string, or I could change my function to accept RawByteString, and convert it to UTF-8 as needed inside the function. QC Entry 64380

QC #: 64413 - Status: Closed

QC #: Project Date Reported: Area: 64413 Delphi 7/13/2008 RTL\Delphi\Pascal Strings Description Steps:[QC Short Description] Unnecessary bus locks in new string code in system.pas [QC Description] Since the addition of a code page parameter to many string handling routines in the RTL, the code construct XCHG ECX,[ESP] PUSH ECX was added in many places in order to inject the new code page parameter before the return address. The XCHG instruction with a memory operand locks the bus and is very bad for performance. Much faster code, that does the same thing, is PUSH [ESP] MOV [ESP-4],ECX Please replace the code in the affected routines listed below: _LStrFromPChar _LStrFromPWChar _LStrFromString _LStrFromWStr _WStrFromLStr _UStrFromLStr _LStrFromUStr _WStrFromUStr QC Entry 64413

N/A - Enhancement request

QC #: 64546 - Status: Closed

QC #: Project Date Reported: Area:64546 Delphi 7/17/2008 VCL\Core VCL Classes\TApplication

Description Steps:[QC Short Description] Data lose when LogOff in Windows XP and Vista if Application.MainFormOnTaskBar = False [QC Description] WM_QUERYENDSESSION message and OnDestroy Events of Forms and finalization code of Units are not Called when LogOff in Windows XP and Vista if Application.MainFormOnTaskBar := False

1. Compile and run the attached application 2. Press Hide button 3. Do LogOff in Windows XP See LogOff.log file to analyse.

and Application.Minimize and Application.MainForm.Hide were fulfilled. QC Entry 64546

QC #: 64550 - Status: Closed

QC #: Project Date Reported: Area: 64550 Delphi 7/17/2008 RTL\Delphi Description Steps:[QC Short Description] Encoding property in TStrings [QC Description] When loading a file TStrings.LoadFromFile (aFilename) will try to find out about the Encoding to be used on loading the file. But there seems to be no way to get information about the encoding used. It looks like if you want to know (for saving with the same encoding) you must reopen the file and findout for yourself (like in TMemInifile.LoadValues). So storing the Extend in a property would save a lot of coding!! QC Entry 64550

QC #: 64564 - Status: Closed

QC #: Project Date Reported: Area: 64564 C++Builder 7/17/2008 IDE\Build Tools Description Steps:[QC Short Description] Project Manager Build Configurations Clean Does Compile [QC Description] Right-click on Build Configurations for any project in the ProjectGroup and select Clean from the pop-up menu. A compile is done instead. QC Entry 64564 [Marcio Update:] A clean is done, but the message that appears is "Done: Compiled." This message should be "Done: Clean". The same as when going Project->Clean Project.

Run C+Builder File, New, Other, Console Application, OK Right click Build Configurations and select Clean Resulting dialog caption is Compiling... Done: Compiled... etc.

QC #: 64572 - Status: Closed

QC #: Project Date Reported: Area: 64572 Delphi 7/17/2008 Modeling Description Steps:[QC Short Description] Class explorer ignores existing visibility sections [QC Description] When using the Add property, Add operation, Add field dialogs, new visibility sections are added although the required ones exist. QC Entry 64572

1. File | New | VCL forms application 2. In the Class explorer, right click on TForm1 and choose Add property 3. In the Property name edit, type 'Something' 4. Click OK 5. In the Class explorer, right click on TForm1 and choose Add property 6. In the Property name edit, type 'SomethingElse' 7. Click OK //Exp: one strict private section, one public section //Act: two of each

[not Class Explorer problem. Same behaviour if add properties from diagram context menu]

QC #: 64632 - Status: Closed

QC #: Project Date Reported: Area:64632 Delphi 7/19/2008 IDE\Code Editor\Error Insight Description Steps:[QC Short Description] Error Insight error in if condition using an external function [QC Description] If you declare an external function in a specific way calling that function as the condition of an if statement will confuse error insight.QC Entry 64632

1. Create a new console application. 2. Create a new unit. 3. Add the following: uses Windows, SysUtils; function GetVolumePathName(lpszFileName: PChar; lpszVolumePathName: PChar; cchBufferLength: LongWord): Boolean; stdcall; implementation function GetVolumePathName; external kernel32 name 'GetVolumePathNameW'; function DoesntWork(const APath: string): string; begin setlength(result, length(APath)); if GetVolumePathName(PChar(APath), PChar(result), length(result)) then // <-- Type of expression must be BOOLEAN at line 18 (18:6) setlength(result, StrLen(PChar(result))) else RaiseLastOSError; end; end.

QC #: 64634 - Status: Closed

QC #: Project Date Reported: Area: 64634 Delphi 7/19/2008 IDE\Tool Palette Description Steps:[QC Short Description] Tool Palette icons not working in Vista64 NOTE: I tried on Vista Ultra...non-64 and it fails there as well. [QC Description] ! Please reinvestigate. The problem is that the icons wrap incorrectly, while it looks like each row contain 12 components, when you click them you notice each row only contain 11. ! When resizing the tool palette the icons wrap to a new row 1 pixel after the tool palette think they do. When this happens clicking on a component in the second and third row will select the wrong component. In the attached screenshot ToolPaletteError1, the first 11 components in each category works as intended, the rest does not. Note how several components show the mouseover look, eventhough the cursor is on the row below. This only happens on the second row.The Cursor itself is over the TActionManager icon, eventhough the Hint says it's over TBalloonHint. In the Additional category: 1) The last clickable component on row 1 is TSplitter. 2) The first component of row 2 is TStaticText, not the TLinkLabel you expect. 3) The first component of row 3 is TDockTabSet, not the TTrayIcon you expect. In the Win32 category, to show it's not the missing icons: 1) The last clickable component on row 1 is TMonthCalendar. 2) The first component of row 2 is TTreeView, not the TListView you expect. I've added 3 new screenshots to further illustrate this, it's easily reproducable. I keep the cursor over the TFlowPanel in all three screenshots. [beforewrap.png]

Steps A: 1. Dock the Project Manager, Tool Palette and Messages to the right edge of the IDE. 2. Set all three to autocollapse. 3. Set Tool Palette properties to: Button size: Medium Show button captions: Uncheck Vertical flow layout: Check Vertical category captions: Uncheck Bold captions: Check Caption only border: Check Use +/- icons: Check Auto collapse categories: Uncheck Show button hints: Check Persistent search filter: Check Always show designer items: Uncheck Show palette wizards: Check Lock palette reordering: Uncheck 4. Create a new VCL application. 5. Collapse all but the Additional Tool Palette category. 6. Resize the tool palette so TCheckListBox are on the first row of the Additional category. It should look like beforewrap.png. 7. Now resize it (to be smaller) so it's just about to wrap, notice how you get an empty row just as it wraps, that's the bug. It should look like buggedwrap.png and afterwrap.png.

This shows the tool palette one pixel before it wraps. [buggedwrap.png] Tool palette is now 1 pixel narrower, there's a new empty row in the additional category, it contains 3 components, but the icons don't wrap to show it. [afterwrap.png] Tool palette is now 2 pixels narrower compared to beforewrap.png, and everything works again. QC Entry 64634

QC #: 64640 - Status: Closed

QC #: Project Date Reported: Area:64640 Delphi 7/20/2008 IDE\Project Management\Project Manager

Description Steps:[QC Short Description] The project view does not show the file directories. [QC Description] The project view does not show the absolute location of each file as it used to do so in Delphi 7 and previous versions. QC Entry 64640

The project view does not show the absolute location of each file as it used to do so in Delphi 7 and previous versions. This is important feature that was lost after D 7. It makes it difficult to easily ménage different projects, and find problems with files located at wrong places. 1. Open a Delphi or C++ Builder project. 2. If you set the project manager to Flat as example it will show the files the same way as in Delphi 7, but it will not display the location of the file in a separated column next to the file name. This makes managing projects and finding wrong locations very difficult.

QC #: 64764 - Status: Closed

QC #: Project Date Reported: Area: 64764 Delphi 7/23/2008 IDE\Code Browsing Description Steps:[QC Short Description] BkGnd compiler does not find file included in .dpr but not on search path [QC Description] Win32 / VCL To the .dpr of a project I have added a file that is *not* on the project search path and *not* in the IDE library path or browsing path. IOW: the full file name is only in the .dpr source file. When trying to invoke commands from the IDE like "go to declaration" (Ctrl+Click) or anytying that requires the background compiler I get a series of error in the "build" tab of the messages view with "unit xyz.dcu" not found. Project compiles OK, but until I added the directory to the project search path the IDE was virtually useles to me. QC Entry 64764

See above see \\ussvs-almtest.codegear.net\swap\Jeanne\IncludeFileNotFound.zip do NOT make this project public. steps: 1) unzip the file 2) create a directory called C:\Foo 3)from the base directory from the zip file, move mad.inc, madGraphics.dcu, madGraphics.pas, vssver.scc into c:\Foo 4) in the a directory, open Project1.dpr in Notepad 5) change the directory to madGraphics to be c:\Foo 6) open the project and compile 7) double click the form to get to the handler 8) Ctrl-Space within the handler //exp: code completion //act: File not found: UnitB.dcu

QC #: 64840 - Status: Closed

QC #: Project Date Reported: Area:64840 Delphi 7/25/2008 RTL\Delphi\Memory, Pointer, Address

Description Steps:

[QC Short Description] signature of _FillChar is wrong [QC Description] procedure _FillChar(var Dest; count: Integer; Value: Char); {$IFDEF PUREPASCAL} var I: Integer; P: PAnsiChar; begin P := PAnsiChar(@Dest); for I := count-1 downto 0 do P[I] := Value; end; {$ELSE} _FillChar takes a Char (=WideChar) but then performs the filling as AnsiChar (which is good because there is lots of code which passes abyte number as count and suddenly filling the same number of widechar's would break lots and lots of code). The signature should reflect that and be declared as procedure _FillChar(var Dest; count: Integer; Value: AnsiChar); QC Entry 64840

QC #: 64853 - Status: Closed

QC #: Project Date Reported: Area:64853 Delphi 7/25/2008 IDE\Project Management\Project Source

Description Steps:[QC Short Description] IDE refuses to compile unit if uses clause is inside $IF directive [QC Description] If the uses clause of a unit that has a form is inside a $IF directive, the IDE refuses to compile it, showing a message box: Error in module Unit1: Declaration of class TForm1 is missing or incorrect. The problem only occurs with $IF. $IFDEF works fine. This problem does not occur with Delphi 2007. QC Entry 64853

1. Start a new VCL application 2. Compile and run to test that the blank application works. 3. Change the uses clause to: {$IF DEFINED(WIN32)} uses Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms, Dialogs, StdCtrls; {$IFEND} 4. Try to compile and run again. Exp: Application compiles and runs, because WIN32 is defined in Tiburon Act: Error in module Unit1: Declaration of class TForm1 is missing or incorrect. 5. Change the uses clause to: {$IFDEF WIN32} uses Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms, Dialogs, StdCtrls; {$ENDIF} 6. Compile and run Exp = act: Application compiles and runs While in this simple example using $IFDEF is a viable workaround, this is not true for situations where the $IF directly actually uses the increased expressiveness offered by $IF.

QC #: 64861 - Status: Closed

QC #: Project Date Reported: Area: 64861 Delphi 7/26/2008 IDE\Code Editor Description Steps:[QC Short Description] Undo of space and enter key offsets cursor by one [QC Description] When doing an Undo for a just typed space or pressed enter key, the cursor is offset by one to the left. QC Entry 64861

1. Create a new Console application 2. Set the cursor to the first line second char (Col 2) (between 'p' and 'r') 3. Press 'c' 4. Press Ctrl+Z (Undo) [everything is normal] 5. Press Space 6. Press Ctrl+Z (Undo) [cursor isn't where it should be] Expected: The cursor is between 'p' and 'r' (Col 2) Actual: The cursor is before 'p' (Col 1)

QC #: 64898 - Status: Closed

QC #: Project Date Reported: Area: 64898 Delphi 7/28/2008 VCL\Graphics Description Steps:[QC Short Description] Access violation in FreeDeviceContexts [QC Description] In certain circumstances TControlCanvas.CreateHandle can be called recursively. If this happens it can incorrectly add the canvas to CanvasList twice. When the canvas is freed only one copy is removed, so the next time the message loop calls FreeDeviceContexts it will crash with an access violation. This is a duplicate of 5132 & 6320, but neither of those have a reproducable test case and both have the same incorrect fix that would result in leaked HDCs. QC Entry 64898 Added by Sysop <<<<<<<<<<<<<<< This issue still exists in Delphi 2010. Please workaround of QC report. >>>>>>>>>>>>>>>

Create a new VCL forms application and add a single button with an OnClick handler. Add the following code to the implementation section, then run the application and click the button. type TMyControl = class(TCustomControl) procedure WMSize(var Message: TWMSize); message WM_SIZE; end; procedure TMyControl.WMSize(var Message: TWMSize); begin inherited; Canvas.TextWidth('ABC') end; procedure TForm1.Button1Click(Sender: TObject); var C: TMyControl; begin C := TMyControl.Create(Self); C.Visible := False; C.Parent := Self; C.SetBounds(0, 0, 100, 100); C.Canvas.Lock; C.Canvas.TextWidth('DEF'); C.Canvas.Unlock; C.Free end; In the sample code the window handle hasn't been created when TextWidth('DEF') is called, so the GetDeviceContext call in TControlCanvas.CreateHandle has to create it, which triggers the WM_SIZE message and the nested TControlCanvas.CreateHandle call. The canvas is locked to keep it in the CanvasList until it's all the way out; if it isn't then TWinControl.MainWndProc can remove it, which masks the bug.

QC #: 64919 - Status: Closed

QC #: Project Date Reported: Area: 64919 Delphi 7/29/2008 RTL\Delphi\Date - Time Description Steps:[QC Short Description] DateSeparator is not used by DateToStr for some locale settings [QC Description] (checked on WinXP SP3 Ru) There is a problem with DateSeparator in some environments. The problem is that DateTimeToString expects '/' as date separator in ShortDateFormat: '/': // <--- fixed separator for date if DateSeparator <> #0 then AppendChars(@DateSeparator, 1); ':': if TimeSeparator <> #0 then AppendChars(@TimeSeparator, 1); But when you change date format in Windows, the current separator is used inside format string (not '/' as expected by DateTimeToString), for example: 'yyyy.mm.dd' but not 'yyyy/mm/dd'. So, actually DateSeparator is not used in format string at all. Please, see "Steps to reproduce" to reproduce the problem. Note that ':' is always used in ShortTimeFormat regardless of TimeSeparator. So, this problem is not occured for time (only for date). I suggest to add something like: ShortDateFormat := StringReplace(ShortDateFormat, DateSeparator, '/', [rfReplaceAll]); to GetFormatSettings and GetLocaleFormatSettings routines in SysUtils.pas.

(JJS: If you set the date separator in the windows regional settings, the attached console app can easily reproduce the issue.) 1. Open regional settings in windows and setup the short date format: 'yyyy.mm.dd'. The date separator is '.'. 2. Create new VCL application, write: procedure TForm1.FormCreate(Sender: TObject); begin Caption := DateToStr(Now); // ShortDateFormat is 'yyyy.mm.dd', DateSeparator is '.' end; 3. Run it. You will see '2008.07.29' in form's caption (as expected). 4. Modify it: procedure TForm1.FormCreate(Sender: TObject); begin DateSeparator := '-'; Caption := DateToStr(Now); // ShortDateFormat is 'yyyy.mm.dd', DateSeparator is '-' end; 4. Run it. You will see '2008.07.29' in form's caption. But the expected value is '2008-07-29'. 5. Modify it: procedure TForm1.FormCreate(Sender: TObject); begin DateSeparator := '-'; Caption := DateToStr(Now); // ShortDateFormat is 'yyyy/mm/dd' - see unit's initialization below, DateSeparator is '-' end; initialization

QC Entry 64919 ShortDateFormat := StringReplace(ShortDateFormat, DateSeparator, '/', [rfReplaceAll]); end. 6. Run it. You will see '2008-07-29' - as expected.

QC #: 64933 - Status: Closed

QC #: Project Date Reported: Area:64933 Delphi 7/29/2008 IDE\Code Editor\Error Insight Description Steps:[QC Short Description] Missing quotes in error insight error message [QC Description] The "Expected but found" error message is missing the quotes (in US and in all localizations) QC Entry 64933

1. Create new VCL application 2. Switch to the Code Editor 3. Insert a "," before the "." in "end." 4. Wait for error insight to show the error Expected: Expected '.' but found ',' in line... Actual: Expected . but found , in line...

QC #: 65073 - Status: Closed

QC #: Project Date Reported: Area:65073 C++Builder 7/31/2008 IDE\Project Management\Project Manager

Description Steps:[QC Short Description] Renaming a library in a project fails, and edit box goes peculiar [QC Description] I have a project that includes a library file from ANOTHER projects directory (so that the relative path starts ..\). (If the library is NOT from a relative path to a sibling, it seems to work). I get "error: Cannot open file <path and name or UNCHANGED library name>. The system cannot find the file specified. And the floating edit box for the rename is in a VERY odd state, apparently split into two halves at the point I'm changing it (e.g. if I'm changing "project2.lib" to "project12.lib" it splits into "project1" and "2.lib", which you can navigate between with left and right arrow keys). QC Entry 65073

Open the attached project group (projects\projectgroup1) In project1.exe, use F2 in the tree and try renaming project2.lib to Project12.lib Screenshot attached of what I see! In the rename edit window, note the "2.lib". If try scrolling left, it "flips" to saying just "Project1" - scroll right and it flips back!

QC #: 65167 - Status: Closed

QC #: Project Date Reported: Area: 65167 C++Builder 8/3/2008 IDE\File Handling Description Steps:[QC Short Description] Minus character can't be used in a file name when saving c++ source file. QC Entry 65167

How to reproduce 1. Open IDE 2. File - New - Other - C++ Builder File. 3. Select CPP file File1.cpp is created. 4. File - Save As For example, enter "File-1.cpp" and click "Save" button. Then, an error message is displayed and the file is not saved. Environment - Windows XP SP2 Japanese. - Tiburon Build 3128.

QC #: 65184 - Status: Closed

QC #:

Project Date Reported: Area:

65184 Delphi 8/4/2008 RTL\Delphi\Other RTL Description Steps: [QC Short Description] UTF8* functions "eat" #0 char QC Entry 65184

Compile and run the attached application below. See the following program output indicating failure. FAIL original length=62 unicodestring length=61 ansistring length=60 program BTS263459; {$APPTYPE CONSOLE} uses SysUtils; const aaa : ansistring = 'RO107'#0#0#0#0#0#0#0'S|'#$D'7=L'#$17'I='#2'(Hm.'#$1E'u'#$F#0#0#0'MegaDemoService'#3#0#0#0'Sum'#1#0#0#0#2#0#0#0; var s: unicodestring; s1: ansistring; begin s:= UTF8ToString(aaa); s1:=UTF8Encode(s); if length(s1) <> length(aaa) then begin WriteLn('FAIL' + sLineBreak + 'original length='+ inttostr(Length(aaa))+sLineBreak+ 'unicodestring length='+ inttostr(Length(s))+sLineBreak+ 'ansistring length='+ inttostr(Length(s1)) ); end else WriteLn('PASS'); end.

QC #: 65220 - Status: Closed

QC #: Project Date Reported: Area: 65220 C++Builder 8/4/2008 Compiler\C++\Back End Description Steps:[QC Short Description] Compiled code from BCB2007 is over twice as slow as BCB6 [QC Description] In addition to report# 62169 I too have notice an unacceptable speed reduction between bcb6 and bcb2007. In the attached code (unit1.cpp) this runs with a time of 1.360s for bcb6 compiled code as opposed to 2.816s for bcb2007 compiled code. Both where release builds. I also compiled the code with VC++2008 and this ran with a time of 1.437s. My attached code only uses the STL complex number class. All arrays

"\Program Files\Borland\CBuilder6\bin\bcc32" -O2 qc65220.cpp qc65220 Total time in mS for 100 Simulations 2703 "\Program Files\Borland\BDS\4.0\Bin\bcc32.exe" -O2 qc65220.cpp qc65220 Total time in mS for 100 Simulations 5218 "\Program Files\Codegear\RAD Studio\5.0\Bin\bcc32.exe" -O2 qc65220.cpp qc65220 Total time in mS for 100 Simulations 5641 "\Program Files\Codegear\RAD Studio\6.0\Bin\bcc32.exe" -O2 qc65220.cpp qc65220 Total time in mS for 100 Simulations 7125

are C++ arrays using "new" and math functions from math.h. QC Entry 65220

QC #: 65254 - Status: Closed

QC #: Project Date Reported: Area: 65254 Delphi 8/5/2008 SOAP\WSDL Importer Description Steps:[QC Short Description] WSDL does not import [QC Description] When I start the import wizard with this WSDL (Attachment), than come an error --------------------------- Fehler --------------------------- The system cannot locate the object specified. Linie: 0 --------------------------- OK --------------------------- After the update "24535, Delphi SOAP Runtime and Importer Update" come the same error. QC Entry 65254

The issue here is that there's a misunderstanding that download the patches updates the IDE's importer. No, one must use WSDLImp to get the fixes in the patch.

QC #: 65434 - Status: Closed

QC #: Project Date Reported: Area: 65434 Delphi 8/8/2008 Internet\Indy Description Steps:[QC Short Description] Indy IdUri.URLEncode can't encode '|' (7c) character QC Entry 65434 // Ken Masuyama ---- I compared (I) Indy URLEncode and (J) JavaScript encodeURI. (I) and (J) both encodes: % < > [ ] (I) encodes but (J) doesn't: * # (I) doesn't encode but (J) does: " \ ^ ` { | } JavaScript encodes all "delims" and "unwise" chars in RFC2396 (except '#').

Indy IdUri.URLEncode can't encode '|' (7c) character '|' character should be converted to '%7C' by URLEncode. How to reproduce I will attach the zipped project in attachments tab. Please compile and execute it? Enter an English string such as 'book' in Edit field and push button. The program is as follows. : const ENCODING: PChar = 'UTF-8'; INTERMEDIATE_LANGUAGE: PChar = 'en'; URL_STRING: PChar = 'http://ajax.googleapis.com/ajax/services/language/translate?v=1.0&langpair='; TEXT_VAR: PChar = '&q='; : url := URL_STRING + fromLang + '|'+ toLang + TEXT_VAR + srcText; url := TIdUri.URLEncode(url); : Source URL string is 'http://ajax.googleapis.com/ajax/services/language/translate?v=1.0&langpair=en|ja&q=book' Expected URL string is 'http://ajax.googleapis.com/ajax/services/language/translate?v=1.0&langpair=en%7Cja&q=book'

QC #: 65436 - Status: Closed

QC #: Project Date Reported: Area: 65436 Delphi 8/8/2008 Internet\Indy

Description Steps:[QC Short Description] Indy IdUri.URLEncode can't encode to UTF8-encoded format QC Entry 65436 // Ken Masuyama The fix is quite easy -- first assign the string to UTF8String and then encode the UTF8String just like old way.

Execute the following ines. ===== : url := 'http://ajax.googleapis.com/ajax/services/language/translate?v=1.0&langpair=jp|en&q=?' url := TIdUri.URLEncode(url); : ===== '?' is Japanese word in Unicode. // Ken Masuyama: U+672C "hon" (book) The url becomes 'Unicode-encoded' format as follows, not 'UTF8 encoded' format 'http://ajax.googleapis.com/ajax/services/language/translate?v=1.0&langpair=jp|en&q=%672C' But I need to have 'http://ajax.googleapis.com/ajax/services/language/translate?v=1.0&langpair=jp|en&q=%E69CAC'. // Ken Masuyama: it must be %E6%9C%AC (JavaScript encodeURI returns this) 0x672C is Unicode of the Japanese word and it should be "E69CAC" in UTF8. The URLEncode should have an additional parameter of Encoding type. This is very critical issue. We can't access a lot of webservices. In Japan, some webservices need 'Shift-JIS' encoded format in URL and 'Utf8' encoded format.

QC #: 65447 - Status: Closed

QC #: Project Date Reported: Area:65447 C++Builder 8/8/2008 Documentation\Online Help\VCL

Description Steps:[QC Short Description] Explanation of the UnicodeString::c_str method in a help [QC Description] UnicodeString::c_str method is explained to be a const method which returns wchar_t* by help. However, the nonconst method which returns char* is called in a standard C++Builder project. (It is a project without the macro definition of UNICODE,_UNICODE,USTRING_AS_WCHART.) The explanation about a char* version is required for a help. QC Entry 65447

1 - File | New | C++ VCL Project 2 - Type: UnicodeString:c_str and press F1 for help 3 - Note that the function is explained as: __fastcall wchar_t* c_str() const; 4 - Close the help, position the cursor at the end of UnicodeString::c_str and press ctrl+space for auto completion. 5 - Note that the method appears as: function c_str() char *.

QC #: 65467 - Status: Closed

QC #: Project Date Reported: Area: 65467 Delphi 8/8/2008 IDE\Tool Palette Description Steps:[QC Short Description] Default component icon only in 16x16 format [QC Description] If a component does not specify its own component icon (for the Tool Palette), a default icon is used. This default icon is only in 16x16 format, so that if you use large or medium icons in the ToolPalette, the default icon is stretched.

A 24x24 and 32x32 version of the default icon should be created and used when the Tool Palette is using the larger styles. QC Entry 65467

QC #: 65498 - Status: Closed

QC #: Project Date Reported: Area:65498 Delphi 8/10/2008 IDE\Packages\New Component Wizard

Description Steps:[QC Short Description] When installing to a new package, selecting the name of an existing file causes AV [QC Description] When you use Component | New VCL component, or Component | Install component, select the 'Install into new package' option, and set the package name to a name of an existing file, you get an AV. QC Entry 65498

1. Component | New VCL component 2. Select anything, e.g. TAnimate, and click Next twice 3. Choose Install to New package and click Next 4. For the package name, type: FirstPackage 5. Click Finish, say yes to Save dialog // OK, the package installs 6. Component | Install packages 7. Select FirstPackage and click Remove, then click OK 8. File | Close all, say No to save dialog 9. Repeat steps 1-5. //EXP: the package to be installed, with maybe a warning first about overwriting an existing file //ACT: --------------------------- Error --------------------------- Access violation at address 2177E7D2 in module 'delphicoreide120.bpl'. Read of address 00000000. [2177E7D2]{delphicoreide120.bpl} BaseDelphiProject.TDelphiProjectModuleHandler.Validate (Line 2615, "BaseDelphiProject.pas" + 1) + $3 [21E43897]{delphide120.bpl} DelphiProject.TDelphiPackageProject.AfterConstruction (Line 158, "DelphiProject.pas" + 2) + $2 [20007235]{rtl120.bpl } System.@AfterConstruction (Line 10601, "System.pas" + 2) + $5 [2177926B]{delphicoreide120.bpl} BaseDelphiProject.TBaseDelphiProject.Create (Line 723, "BaseDelphiProject.pas" + 69) + $B9 [21E43C2B]{delphide120.bpl} DelphiProject.TDelphiProjectCreationTrait.CreateMSBProject (Line 229, "DelphiProject.pas" + 2) + $24 [209D9B5B]{coreide120.bpl} ProjectFileUtils.CreateMSBProject (Line 707, "ProjectFileUtils.pas" + 7) + $36 [21E47AF8]{delphide120.bpl} PasReg.TPascalPersonalityTraits.CreatePackageProject (Line 1038, "PasReg.pas" + 5) + $30 [218134E7]{delphicoreide120.bpl} NewComponentWizard.CreateNewPackage (Line 277, "NewComponentWizard.pas" + 10) + $8 [21813CC7]{delphicoreide120.bpl} NewComponentWizard.TNewComponentWizard.Finish (Line 512, "NewComponentWizard.pas" + 57) + $24 [20AD88B1]{coreide120.bpl} Wizard.TWizard.Show (Line 713, "Wizard.pas" + 30) + $8 [2181303E]{delphicoreide120.bpl} NewComponentWizard.CreateNewComponent (Line 169, "NewComponentWizard.pas" + 6) + $5 [21819816]{delphicoreide120.bpl} PasCppCmds.TPasCppCom

QC #: 65522 - Status: Closed

QC #: Project Date Reported: Area:65522 Delphi 8/11/2008 RTL\Delphi\File Management Description Steps:[QC Short Description] TMemoryStream.LoadFromFile throws "Stream read error" [QC Description] I encountered a "Stream read error" using TMemoryStream.LoadFromFile. It was non-deterministic (sometimes it was thrown, sometimes it wasn't.) Some searching led me to a newsgroup-message: borland.public.delphi.vcl.components.using.win32 Re: Help! Stream-Read-Error on TMemoryStream.LoadFromFile Remy Lebeau (TeamB) [Jun 3 2004, 19:34]

Use TMemoryStream.LoadFromFile with a large file (mine is appr. 94 MB)

Where Gambit explains: "if it [TMemoryStream] doesn't read the full data in one try, it throws an exception." I think this asks for a better error description than "Stream read error", e.g. mentioning the file and/or the file size. Besides, I think this would call for better handling, e.g. using TMemoryStream.CopyFrom like Gambit suggests. QC Entry 65522

QC #: 65576 - Status: Closed

QC #: Project Date Reported: Area:65576 Delphi 8/12/2008 Documentation\Online Help Description Steps:[QC Short Description] TFormatSettings member fields not described [QC Description] ms-help://borland.bds5/delphivclwin32/SysUtils_TFormatSettings.html doesn't explain the individual member fields. Some simply aren't clear. How are they encoded? QC Entry 65576

Open ms-help://borland.bds5/delphivclwin32/SysUtils_TFormatSettings.html and wonder how e.g. CurrencyFormat is encoded

QC #: 65595 - Status: Closed

QC #: Project Date Reported: Area:65595 Delphi 8/12/2008 Compiler\Delphi\Execution Description Steps:[QC Short Description] F2084 Internal Error: C12063 (D2007) or C12893 (D2009) [QC Description] F2084 Internal Error: C12063 (D2007) or C12893 (D2009) It happens both for the wrapper class and the wrapper record. QC Entry 65595

Compile the attached application below. See the following compile-time error indicating failure. Fatal: F2084 Internal Error: C12916 program BTS264005; type TNullableDouble = record private function GetIsNull: Boolean; public property IsNull: Boolean read GetIsNull; end; function TNullableDouble.GetIsNull: Boolean; begin end; type TWrapperRecord = record function GetValue: TNullableDouble; end; function TWrapperRecord.GetValue: TNullableDouble; begin end; procedure IsNullUsingWrapperRecord; var Wrapper: TWrapperRecord;

begin if Wrapper.GetValue.IsNull then ; end; begin end.

QC #: 65611 - Status: Closed

QC #: Project Date Reported: Area:65611 C++Builder 8/13/2008 Compiler\C++\Front End\Templates

Description Steps:[QC Short Description] A compile error E2506 occurs with a specialization template function. [QC Description] A compile error E2506 occurs with a specialization template function. CB2007, gcc 3.4.4(cygwin) and VS2008(SP1) succeeded in compile. #include <iostream> template<typename T> void templ_func(const T& v) { std::cout << "templ_func(const T& v) v = " << v << std::endl; } template<typename T> void templ_func(T* v) { std::cout << "templ_func(T* v) v = " << v << std::endl; } template<> void templ_func(const int& v) { std::cout << "templ_func(const int& v) v = " << v << std::endl; } int main() { int int_val = 0; double double_val = 0.0; templ_func(int_val); templ_func(∫_val); templ_func(double_val); return 0; } QC Entry 65611

download attachment bcc32 -c qc65611.cpp Exp: Clean Compile Act: Error E2506 qc65611.cpp 13: Explicit specialization of 'templ_func<T>(const T &)' is ambiguous: must specify template arguments Clean compile in Comeau online and in BDS2006 From the standard doc 14.7/3 [Example] template<class T = int> struct A { static int x; }; template<class U> void g(U) { } ... template<> void g(char) { } // specialize forU == char // U is deduced from the parameter type:

QC #: 65629 - Status: Closed

QC #: Project Date Reported: Area:65629 Delphi 8/13/2008 IDE\Code Editor\Code Folding

Description Steps:[QC Short Description] "Fold/Unfold" popup-menu appears when the block-element is included in the text-file. [QC Description] "Fold/Unfold" popup-menu appears when the block-element is included in the text-file.

[Normal] 1.Execute it again after ending bds.exe. 2.[File | New | VCL Forms Application ] 3.[File | Open... ] 4.Open "test1.txt" <- Use the attachment. 5.Right-click on the code-editor. 6."Fold/Unfold" popup-menu are disabled. [Abnormal] 1.Execute it again after ending bds.exe. 2.[File | New | VCL Forms Application ] 3.[File | Open... ] 4.Open "test2.txt" <- Use the attachment. 5.Right-click on the code-editor. 6."Fold/Unfold" popup-menu are enabled. 7.Select "Nearlest". 8.AV of

Related: [The pop up menu of a code editor] http://qc.codegear.com/wc/qcmain.aspx?d=65627 QC Entry 65629

boreditu.dll is generated. This phenomenon appears when the block-element is included in the text-file. Even if the file is opened again or the block element is deleted, when this phenomenon appears once, it is impossible to solve it any longer.

QC #: 65679 - Status: Closed

QC #: Project Date Reported: Area:65679 C++Builder 8/14/2008 IDE\Project Management\Project Manager

Description Steps:[QC Short Description] No option to disable alphabetic ordering of files in a project [QC Description] C++ Builder has long needed the OPTION to alphabetically order the files in a project - however it has now gone too far, and not got any OTHER option. We need the user ordering back... Even better, allow separate ordering within file type - e.g. main project cpp, res file, then normal project files, then libraries... <sysop> I consider it to be a usability essential to be able to put the files I never edit - lib, res, main project file, etc. at the bottom of the PM list so that they do not take up valuable screen space in the portion of the PM that is always visible without scrolling. Alpha reordering should be an on-demand optoin only IMO. Not averse to having the current implementation as an option, but my preferences in order are: 1. Ability to control order of display in PM - Essential 2. Ability to Alphabetize on demand - Nice addition 3. Ability to alphabetize a selected file type - Even better, but maybe not worth the effort and complication 4. Automatic alphabetization within grouped file types - Only way I might consider an using automatic option, and only if I could specify the order of the groups (.cpp at top, everything else below) 5. Automatic alphabetization as currently implemented - would never use this by choice and think it should be available only if there is a demonstrable demand for it. I consider this a serious impediment to my use of the PM, and under no circumstanced should it be the only option. QC Entry 65679

Just create a project with several files - and try to reorder it manually. You get the drag and drop graphics, but the order stays strict alphabetic.

QC #: 65682 - Status: Closed

QC #: Project Date Reported: Area: 65682 Delphi 8/14/2008 Database\DBExpress Description Steps:[QC Short Description] DBX Informix driver decimal(X,y) as float? [QC Description] This feauture request could solve my earlier report #65680. Please include option to the driver to return decimal data type as FloatField (like in CA400 driver the mapfloat). That way it would be much easier to work with float fields. QC Entry 65682

QC #: 65858 - Status: Closed

QC #: Project Date Reported: Area:65858 Delphi 8/19/2008 IDE\Code Editor\Error Insight Description Steps:[QC Short Description] Declaring a pointer to a method pointer before the method pointer confuses Error Insight [QC Description] If you declare a pointer to a method pointer before the method pointer is declared Error Insight will think the method pointer is an invalid type eventhough the project compiles. If you change the declaration order the error disappears. QC Entry 65858

1. Create a new console application 2. Add the following code after the uses SysUtils section: type POnMyEvent = ^TOnMyEvent; TOnMyEvent = procedure of object; TMyObject = class public Event: TOnMyEvent; end; Expected: No red squiggly lines. Actual: Squiggly lines under TOnMyEvent in Event: TOnMyEvent;

QC #: 65960 - Status: Closed

QC #: Project Date Reported: Area:65960 Delphi 8/21/2008 VCL\Win 32 Controls\TImageList

Description Steps:[QC Short Description] TOverlay = 0..3; [QC Description] in ImgList.pas TOverlay = 0..3; in MSDN ImageList_SetOverlayImage Adds a specified image to the list of images to be used as overlay masks. An image list can have up to four overlay masks in version 4.70 and earlier and up to 15 in version 4.71. The function assigns an overlay mask index to the specified image. ImageList1.Overlay(1, TOverlay(10)); how to fix TOverlay = 0..14; QC Entry 65960

QC #: 66073 - Status: Closed

QC #: Project Date Reported: Area:66073 Delphi 8/26/2008 Documentation\IDE Help Contexts

Description Steps:[QC Short Description] Index for conditional defines should be redone [QC Description] Go into the Look For field and type $R: - it isn't in the index at all - $RANGECHECKS is, but since it's indented, it doesn't receive the focus I suggest that: - all shorthand notations for conditional defines be added to the index- all conditional defines in the index should become unindented so that searching for them is easier QC Entry 66073

QC #: 66105 - Status: Closed

QC #: Project Date Reported: Area:66105 C++Builder 8/26/2008 Compiler\C++\Interaction with the IDE

Description Steps:[QC Short Description] -w! option is ignored in IDE [QC Description] -w! option, which is "Treat Warnings as Errors", is ignored in IDE. On the other hand, bcc32.exe works fine. QC Entry 66105

1) create new application 2) turn on -w! option, which is "Treat Warnings as Errors", at project configuration dialog in IDE 3) write some code which causes Warning(i.e., W8006) 4) build the project within IDE 5) the warning is treated as Warning instead of Error.

QC #: 66113 - Status: Closed

QC #: Project Date Reported: Area: 66113 C++Builder 8/26/2008 IDE\Code Editor Description Steps:[QC Short Description] RMB, Find Declaration does not always work [QC Description] Right mouse button Find Declaration does not always work. From a CPP file, it generally finds the definition in a header file, but from that header file it will fail. This makes it difficult to navigate through the definitions to the base definition. Add to a CPP code module: TCHAR c; Put cursor into TCHAR and right mouse button, Find Declaration. Thiswill open winnt.h and position you on the line: typedef WCHAR TCHAR, *PTCHAR; Put cursor into WCHAR and right mouse button, Find Declaration. Nothing. If you put WCHAR into source code it will find it. QC Entry 66113

Note: the steps here are for a project that maps _TCHAR to wchar_t. Use the attached project and CPP file. Add to a CPP code module: TCHAR c; Put cursor into TCHAR and right mouse button, Find Declaration. This will open winnt.h and position you on the line: typedef WCHAR TCHAR, *PTCHAR; Put cursor into WCHAR and right mouse button, Find Declaration. Nothing. If you put WCHAR into source code it will find it: WCHAR w;

QC #: 66139 - Status: Closed

QC #: Project Date Reported: Area: 66139 C++Builder 8/27/2008 Database\DataSnap\Client Description Steps:[QC Short Description] "Generate DataSnap client classes" in C++Builder generates Delphi code [QC Description] Generate client class code function of SQLConnection would always generates Delphi code, even in C++ project. QC Entry 66139

1. The first half of process is the same as DataSnap demo video of Nick Hodges. 2. When creating client project, select C++ project instead of Delphi project. 3. Put SQLConnection on client main form, and select popup menu "Generate DataSnap client classes". 4. New unit is created, and the name of that unit is UnitXX.cpp, but auto-generated code is not C++ code, but Delphi code.

QC #: 66167 - Status: Closed

QC #: Project Date Reported: Area: 66167 Delphi 8/28/2008 IDE\Object Inspector Description Steps:[QC Short Description] Please add an option to disable automatic adjustment of the divider position when the OI is resized [QC Description] The current behaviour of the OI is to maintain a constant ratio between the property name area and the property value area when the OI is resized. I would like to propose the addition of another setting in the "Options" groupbox of the OI properties dialog called "Fixed Divider Position". When this option is enabled the OI divider should never move around except when it needs to obey the left and right OI margins. The motivation for this request is as follows: I usually set the position of the OI divider quite far to the left such that the names of the properties are barely visible and the bulk of the space is available for the property values (which does tend to require more space than the property names). From time to time I may have to drag the OI wider to see the full property value, and then it is not useful when the divider also moves to the right. QC Entry 66167

N/A - Feature request PropBox.pas patch from Pierre attached

QC #: 66205 - Status: Closed

QC #: Project Date Reported: Area: 66205 Delphi 8/29/2008 IDE\Translation Tools Description Steps:[QC Short Description] External Translation Manager Help file is missing [QC Description] When you launch ETM.exe from the "bin" directory and click on "Help | Contents" you get "Unable to find a Table of Contents" error message and nothing is displayed. QC Entry 66205 //246997 for XML Mapper

Run ETM Help | Contents //Unable to find a Table of Contents error

QC #: 66254 - Status: Closed

QC #: Project Date Reported: Area: 66254 C++Builder 8/31/2008 Compiler\C++\Front End Description Steps:[QC Short Description] ICE when specializing swap in std (from Boost) [QC Description] The attached code causes an internal compiler error. QC Entry 66254

extract the attachement bcc32 -P specialized_in_std.i exp: clean compile act: internal compiler error

QC #: 66382 - Status: Closed

QC #: Project Date Reported: Area:

66382 C++Builder 9/4/2008 VCL\Emulation Classes Description Steps:[QC Short Description] Interface functions cannot be overwritten in derived VCL class [QC Description] When writing a VCL class that derives from an interface, it is not possible to overwrite an interface function in a descendant. This is onlya problem in VCL classes; it works as expected for classes that don't derive from TObject. The following code illustrates the problem. First, we declare an interface: class __declspec (uuid ("{D58EBD98-BEC7-474F-A827-A4CCA0511841}")) IMyInterface : public IInterface { public: virtual void foo (void) = 0; }; Now we want to implement it using a normal C++-style class: class Base { int i; // some non-empty base class }; class Derived1 : public Base, public IMyInterface { // this is just a trivial implementation of the IUnknown functions. _CPPINTF_IMPL_QUERYINTERFACE_BEGIN _CPPINTF_QUERYINTERFACE (IMyInterface) _CPPINTF_IMPL_QUERYINTERFACE_END _CPPINTF_IMPL_ADDREF_RELEASE public: virtual void foo (void) { std::printf ("Derived1::foo()\n"); } }; In addition, we override the definition of foo() in a descendant: class Derived2 : public Derived1 { public: virtual void foo (void) { std::printf ("Derived2::foo()\n"); } }; This works as expected. Now let us try something similar with a VCL class: class VCLDerived1 : public TInterfacedObject, public IMyInterface { // simple redirection to TInterfacedObject::_AddRef() etc. _CPPINTF_IMPL_QUERYINTERFACE_INHERITED_VCL _CPPINTF_IMPL_ADDREF_RELEASE_INHERITED_VCL public: virtual void foo (void) { std::printf ("VCLDerived1::foo()\n"); } }; class VCLDerived2 : public VCLDerived1 { public: virtual void foo (void) { std::printf ("VCLDerived2::foo()\n"); } }; In class VCLDerived1 : public TInterfacedObject, public IMyInterface{ _CPPINTF_IMPL_QUERYINTERFACE_INHERITED_VCL _CPPINTF_IMPL_ADDREF_RELEASE_INHERITED_VCL public: virtual void foo (void) { std::printf ("VCLDerived1::foo()\n"); }

- download the attachment - compile it with bcc32 -WCV qc66382.cpp - run it - Expected output: Derived2::foo() VCLDerived2::foo() Derived2::foo() VCLDerived2::foo() - Actual output: Derived2::foo() VCLDerived2::foo() Derived2::foo() VCLDerived1::foo() Yet worse, if you remove the definition of foo() in Derived1 and VCLDerived1, you receive Derived2::foo() Pure virtual function called

}; class VCLDerived2 : public VCLDerived1 { public: virtual void foo (void) { std::printf ("VCLDerived2::foo()\n"); } }; In this case, every call to VCLDerived2::foo() via an IMyInterface pointer will actually call VCLDerived1::foo(). This implies that it is not possible to partially implement an interface in a class without writing virtual wrapper functions (your program dies with the message "Pure virtual function called" if you try this). QC Entry 66382

QC #: 66386 - Status: Closed

QC #: Project Date Reported: Area:66386 Delphi 9/4/2008 Compiler\Delphi\Other Compiler

Description Steps:[QC Short Description] dynamic array type of generic generates bad C++ code [QC Description] The code generated in HPP files for generic dynamic array types doesn't compile. code type TGenericClass<T> = class(TObject) protected end; TDynamicArray<T> = array of TGenericClass<T>; generates //-- type declarations ------------------------------------------------------- template<typename T> class DELPHICLASS TGenericClass__1; // Template declaration generated by Delphi parameterized types is // used only for accessing Delphi variables and fields. // Don't instantiate with new type parameters in user code. template<typename T> class PASCALIMPLEMENTATION TGenericClass__1 : public System::TObject { typedef System::TObject inherited; public: /* TObject.Create */ inline __fastcall TGenericClass__1(void) : System::TObject() { } /* TObject.Destroy */ inline __fastcall virtual ~TGenericClass__1(void) { } }; typedef DynamicArray<TGenericClass__1<T>*> TDynamicArray__1; which doesn't compile because of undefined T on last line. see steps and attached project. QC Entry 66386

1. create a new C++ console application 2. add a new delphi source file 3. add the following code in the interface section: type TGenericClass<T> = class(TObject) protected end; TDynamicArray<T> = array of TGenericClass<T>; 4. add an include to "Unit1.hpp" in File1.cpp 5. attempt to compile exp: it successes since delphi code is correct act: failure because of undefined T on line: typedef DynamicArray<TGenericClass__1<T>*> TDynamicArray__1;

QC #: 66399 - Status: Closed

QC #: Project Date Reported: Area: 66399 Delphi 9/4/2008 IDE\Class Completion Description Steps:[QC Short Description] Generics - missing private/public keyword breaks class completion [QC Description] A class that is using generics in a field, but does not have a private/public/... keyword breaks class completion in the whole unit. type TGuard<T> = class(TInterfacedObject) wrapper : TWrapper<T>; end; Press Ctrl+Shift+C for class completion, and you'll get the following error: --------------------------- GenericsTest - CodeGear RAD Studio for Microsoft Windows - Unit2--------------------------- Expected ';' but '<' found in class TGuard<T>. --------------------------- OK --------------------------- Of course it is easy to fix the class declaration, but the error message is a bit misleading: type TGuard<T> = class(TInterfacedObject) public wrapper : TWrapper<T>; end; QC Entry 66399

Press Ctrl+Shift+C to complete the following class: unit Unit2; interface type TGuard<T> = class(TInterfacedObject) wrapper : TWrapper<T>; end; implementation end.

QC #: 66446 - Status: Closed

QC #: Project Date Reported: Area: 66446 C++Builder 9/5/2008 RTL\C++\Threads Description Steps:Request for replacing boost 1.35.0 by boost 1.36.0 [QC Short Description] Boost::condition_variable broken in 1.35.0 [QC Description] There are serious issues with boost::condition_variable on Windows in the 1.35.0 release which is included with Tiburon. These issues are fixed in Boost 1.36.0. See https://svn.boost.org/trac/boost/ticket/1803 and https://svn.boost.org/trac/boost/ticket/1834 for details. QC Entry 66446

Assigned to Lee in JIRA: http://vmsfjira:8665/browse/RAD-670

QC #: 66529 - Status: Closed

QC #: Project Date Reported: Area:

66529 C++Builder 9/9/2008 Compiler\C++\Front End\Pre-Compiled Headers

Description Steps:bcc gets ICE on unnamed namspace in precompiled header [QC Description] The attached project always generates a Fatal Error when built for the second time. QC Entry 66529

unzip me.zip bcc32 -c -H=me.pch me.cpp bcc32 -c -H=me.pch me.cpp Exp: Successful build Act: Fatal F1004 C:\Program Files\CodeGear\RAD Studio\6.0\include\boost_1_35\boost/regex/v4/regex_traits.hpp 163: Internal compiler error at 0x485be2 with base 0x400000 ---------------- old steps --------------- Download attachment Bcc32 -c -I"CG_BOOST_ROOT%" -H CommentString.h Bcc32 -c -I"CG_BOOST_ROOT%" -H CommentString.h Exp: Successful build Act: Fatal F1004 C:\Program Files\CodeGear\RAD Studio\6.0\include\boost_1_35\boost/regex/v4/regex_traits.hpp 163: Internal compiler error at 0x485be2 with base 0x400000 Error happens only on second build Deleting the pch file will allow a successful rebuild. My default pch file was: C:\Program Files\CodeGear\RAD Studio\6.0\bin\bc32def.csm

QC #: 66550 - Status: Closed

QC #: Project Date Reported: Area:66550 Delphi 9/9/2008 VCL\Core VCL Classes\TControl

Description Steps:[QC Short Description] Cursor property missing Windows "Link Select" cursor [QC Description] Microsoft Windows has a Link Select cursor under Control Panel > Mouse > Pointers tab. Scroll to the bottom and you'll see Link Select. This is the cursor that is shown when the user is hovering over a clickable link in a browser. The VCL has never had that cursor as an option in the Cursor property's drop-down list of cursor. The closest thing to it is crHandPoint which looks Windows-95-ish. Can the Link Select cursor please be added to the TCursor type? Once that is done, ms-help://borland.bds5/delphivclwin32/Controls_TCursor.html would need to be updated because it has this to say about crHandPoint: "An upward pointing hand cursor. This is normally used to identify a selectable item, such as a web page link." which has false. QC Entry 66550

QC #: 66564 - Status: Closed

QC #: Project Date Reported: Area: 66564 Delphi 9/10/2008 Documentation Description Steps:

[QC Short Description] System.SetCodepage wrong in help and description missing [QC Description] Please add a useful description for SetCodePage. This is a new function in D2009 and should be documented as soon as possible because of this. Also replace AnsiString with RawByteString in help. procedure SetCodePage(var S: AnsiString; CodePage: Word; Convert: Boolean = True); change to: procedure SetCodePage(var S: RawByteString; CodePage: Word; Convert: Boolean); QC Entry 66564

See help for System.SetCodePage 1 - Type System.SetCodePage in code editor 2 - Place the cursor over it and press F1 The description of the function is: "This is function System.SetCodePage." =============================== fixed in 2010 http://docwiki.embarcadero.com/VCL/en/System.SetCodePage

QC #: 66688 - Status: Closed

QC #: Project Date Reported: Area:66688 C++Builder 9/12/2008 IDE\Code Editor\Code Folding

Description Steps:[QC Short Description] you cannot disable code folding [QC Description] Checkbox in the Tools -> Options -> Editor is missing. There is "Gutter visible", "Right margin visible", but "Code folding bar visibe" is not shown. QC Entry 66688 Comment from QC: <<<<<<<< use ctrl+shift+k o for toggling >>>>>>>>

QC #: 66864 - Status: Closed

QC #: Project Date Reported: Area: 66864 Delphi 9/16/2008 SOAP Description Steps:[QC Short Description] Add SOAP 1.2 support to importer and clients [QC Description] Although Win32 web service servers are currently marked as deprecated, it the web service clients are also falling behind with their lack of SOAP v1.2 support. Please add SOAP v1.2 support to the WSDL importer and Delphi Win32 SOAP clients, followed - if possible - by MTOM, the items that are lacking the most in Delphi's Win32 SOAP Framework in order to interoperate with other SOAP solutions/frameworks/stacks out there.QC Entry 66864

Try to import a SOAP v1.2 of WCF server in Delphi 2009. This will become more important, so please add support for this in Win32 clients.

QC #: 66881 - Status: Closed

QC #: Project Date Reported: Area: 66881 Delphi 9/17/2008 IDE\Help Description Steps:[QC Short Description] Delphi 2009 Type Library Options page help wrong [QC Description] The Type Library options page (in Tools | Options) has changed for both Delphi and C++Builder. Unfortunately, there's a little problem with that. First of all, pressing Help when looking at the Delphi Type Library page brings up the C++Builder Type Library page (which you also get if you click on Help from the C++Builder Type Library page, so at least it's consistent). The bigger problem is that the help page is still Delphi 2007 specific: the new options are not documented, yet. The first two groups (Ignore special CoClass Flags when importing, and SafeCall function mapping) are still covered, as well as the Source Refreshing option, but the Type Library Editor and RIDL Options are not. There are three RIDL options: - Lookup referred type libraries in the registry - Store Unicode data as UTF8 in type library - Check for UTF8 data in the type library There are two final Type Library Editor options: - Refresh implementation when renaming type library - Refresh implementation when .ridl file is saved Fortunately, these options are relative easy to understand (the only thing that’s not clear is the alternative for UTF8 data. QC Entry 66881

Start the Tools | Options dialog in Delphi 2009, go to the Delphi Type Library page. Pressing Help when looking at the Delphi Type Library page brings up the C++Builder Type Library page (which you also get if you click on Help from the C++Builder Type Library page, so at least it's consistent). Also note that the actual help pages contain incomplete information (from Delphi 2007).

QC #: 66905 - Status: Closed

QC #: Project Date Reported: Area:66905 Delphi 9/17/2008 VCL\Additional Controls\TCheckListBox

Description Steps:[QC Short Description] Repaint Error. [QC Description] Set the property "DoubleBuffered" to be True. And then check the item in the TCheckListBox(Do not check the first item.). It's seemed that checkbox is paintting error. QC Entry 66905

1.Put a TCheckListBox in a form. 2.Set the DoubleBuffered property to be true. 3.Insert some items into the CheckListBox. 4.Complie and run the program and check the item in the CheckListBox. you will find some checkbox can not been paint as checked status.

QC #: 66909 - Status: Closed

QC #: Project Date Reported: Area: 66909 Delphi 9/17/2008 Compiler\Delphi\Generics Description Steps:[QC Short Description] The compilation error occurred when I use the generic type in a with-sentence in a internal-function or a anonymous method. [QC Description] The compilation error occurred when I use the generic type in a with-sentence in a internal-function or a anonymous method.

Compile the attached application below. See the following compile-time error. program BTS265353; { Generics types and the with statement }

QC Entry 66909 {$APPTYPE CONSOLE} uses Generics.Collections; procedure Test(const o: IEnumerator<string>); begin with o do; //error end; begin WriteLn('PASS'); end.

QC #: 67016 - Status: Closed

QC #: Project Date Reported: Area:67016 C++Builder 9/20/2008 Compiler\C++\Front End\Templates

Description Steps:[QC Short Description] typedef can not define a function pointer type in template, [QC Description] This code compiles without error in gcc and in Comeau but errs in CB 2009: template <int n> class t { public: typedef typename t<n-1>::type_1 type_1; typedef typename t<n-1>::type_2 type_2; typedef typename t<n-1>::type_3 type_3[10]; typedef typename t<n-1>::type_4 (*type_4)(int); }; template<typename T> class A { public: typedef T a; }; typedef A<int>::a (*a)(int); QC Entry 67016

download attachment bcc32 -c qc67016 Exp: Clean compile Act: Error E2091 qc67016.cpp 6: Functions cannot return arrays or functions Error E2089 qc67016.cpp 6: Identifier 'type_4' cannot have a type qualifier

QC #: 67075 - Status: Closed

QC #: Project Date Reported: Area:67075 C++Builder 9/22/2008 Compiler\C++\Front End\Templates

Description Steps:[QC Short Description] Failure to deduce function pointer template parameters [QC Description] The template function parameters can not be calculated if the parameter is a class member function pointer which has overload Attached code: #include <iostream> using namespace std; class A{

download attachment bcc32 -c qc67075.cpp Exp: Clean compile Act: Error E2285 qc67075.cpp 48: Could not find a match for 'fun<R,C,A1,A2>(int (A::*)(int),A,int)' in function main() Error E2285 qc67075.cpp 50: Could not find a match for 'fun<R,C,A1,A2>(int (A::*)(int),A,int,int)' in function main() Code compiles cleanly in Comeau.

public: int f(int a){ return a;} int f(int a,int b) { return a + b; } }; template<typename R,typename C,typename A1> R fun ( R (C::*p)(A1),C& c,A1 a1) { return (c.*p)(a1); } template<typename R,typename C,typename A1,typename A2> R fun ( R (C::*p)(A1,A2),C& c,A1 a1,A2 a2) { return (c.*p)(a1,a2); } int fun2(int (A::* p)(int),A& a,int n) { return (a.*p)(n); } int fun2(int (A::* p)(int,int),A& a,int n,int m) { return (a.*p)(n,m); } int main() { A a; int (A::* p1)(int); int (A::* p2)(int,int); p1 = &A::f; p2 = &A::f; int c = (a.*p1)(10); cout << c << endl; c = (a.*p2)(10,1); cout << c << endl; c = fun2(&A::f,a,10); cout << c << endl; c = fun2(&A::f,a,10,20); cout << c << endl; c = fun(&A::f,a,10); cout << c << endl; c = fun(&A::f,a,10,2); cout << c << endl; system("pause"); return 0; } QC Entry 67075

QC #: 67081 - Status: Closed

QC #: Project Date Reported: Area: 67081 Delphi 9/23/2008 Resourcing\BRCC/BRCC32

Description Steps:[QC Short Description] BRCC32 fails compilation because of readonly .tmp files [QC Description] Either the Delphi compiler or BRCC32 (I can't determine which) creates readonly .tmp files, which aren't removed after the build. After compiling a few hundred units, the filenames start to collide, resulting in failures of the BRCC32 compiler. Output reads like this : [MSBuild Error] The "BRCC32" task failed unexpectedly.

We have these sort of lines in our .dpr files : {$R '..\Shared\version.res' '..\Shared\version.rc'} {$R '..\Shared\Manifests\Vista.res' '..\Shared\Manifests\Vista.rc'} {$R '..\..\General\Shared\Resources\Icons.res' '..\..\General\Shared\Resources\Icons.rc'} Compiling these projects, I see all kinds of .tmp files appear in the "..\Shared", "..\Shared\Manifests" and "..\..\General\Shared\Resources\" folders : When I do this on the command line : D:\Perforce\Work\Sub7\General\Shared\Resources>DIR /AR > tmp.txt I get : 29-05-2006 16:55 77 Icons.rc 02-12-2004 14:34 36 tmp302.tmp 02-12-2004 14:34

System.UnauthorizedAccessException: Access to the path 'D:\Perforce\Work\Sub7\General\Shared\Resources\tmp2E3.tmp' is denied. at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath) at System.IO.File.InternalCopy(String sourceFileName, String destFileName, Boolean overwrite) at Borland.Build.Tasks.Common.CommandLineTask.CreateTempFileIfNecessary(ITaskItem basedOn) at Borland.Build.Tasks.Common.CommandLineTask.Execute() at Microsoft.Build.BuildEngine.TaskEngine.ExecuteTask(ExecutionMode howToExecuteTask, Hashtable projectItemsAvailableToTask, BuildPropertyGroup projectPropertiesAvailableToTask, Boolean& taskClassWasFound) QC Entry 67081

36 tmp305.tmp 02-12-2004 16:24 46 tmp311.tmp 29-05-2006 16:55 78 tmp312.tmp 04-08-2008 14:19 38 tmp315.tmp 12-12-2006 10:14 42 tmp318.tmp 29-05-2006 16:55 77 tmp319.tmp 29-05-2006 16:55 78 tmp31A.tmp 29-05-2006 16:55 77 tmp328.tmp 29-05-2006 16:55 94 tmp329.tmp It's kinda wierd that the file dates are all over the place, whilst I saw them appear only minutes ago. PS: Those files don't disappear when I close the IDE either.

QC #: 67109 - Status: Closed

QC #: Project Date Reported: Area: 67109 Delphi 9/23/2008 Internet\Indy Description Steps:[QC Short Description] idsntp1.synctime doesn't work properly. [QC Description] using tidsntp.synctime changes the local time to 1974 in windows vista. it works well in 2007 and doesn't depend on time servers. QC Entry 67109

just simple code "idsntp1.synctime;" and any time server host(e.g. time.windows.com) in object inspector.

QC #: 67147 - Status: Closed

QC #: Project Date Reported: Area:67147 Delphi 9/24/2008 Documentation\Online Help\Main help

Description Steps:[QC Short Description] Someone did search and replace from Borland to CodeGear [QC Description] Project Options|Compiling: (There never were anything called CodeGear Pascal...) Open parameters Meaningful only for code compiled supporting huge strings, and is provided for backwards compatibility with early versions of Delphi and CodeGear Pascal. This option, (equivalent to $P) controls the meaning of variable parameters declared using the string keyword in the huge strings disabled (equivalent to {$H-}) state. When disabled (equivalent to {$P-}), variable parameters declared using the string keyword are normal variable parameters, but when enabled (equivalent to {$P+}), they are open string parameters. Regardless of the setting of this option, the openstring identifier can always be used to declare open string parameters. Default = True Strict var-strings This option (equivalent to $V directive) is meaningful only for Delphi code that uses short strings, and is provided for backwards compatibility with early versions of Delphi and CodeGear Pascal. The option controls type on short strings passed as variable parameters. When enabled (equivalent to {$V+}), strict type is performed, requiring the formal and actual parameters to be of identical string types. When disabled (equivalent to {$V-}) (relaxed), any short string type variable is allowed as an actual parameter, even if the declared maximum length is not the same as that of the formal parameter. Default = True QC Entry 67147

QC #: 67182 - Status: Closed

QC #: Project Date Reported: Area:67182 Delphi 9/25/2008 RTL\Delphi\File Management Description Steps:[QC Short Description] GetFileAttributesEx() call. [QC Description] In SysUtils.pas: Line 6457 makes call to GetFileAttributesEx(); Line 6488 makes call to GetFileAttributesExFunc(); Please make them consistent. QC Entry 67182

QC #: 67260 - Status: Closed

QC #: Project Date Reported: Area:67260 Delphi 9/28/2008 VCL\Core VCL Classes\TForm

Description Steps:[QC Short Description] TForm.Autosize does not work [QC Description] Even if TForm.Autosize=True, the form is not resized to show its controls. QC Entry 67260

Set Form1.Autosize := True. Place Button1: TButton of this form. In Button1.OnClick: procedure TForm1.Button1Click(Sender: TObject); begin Button1.Height := Button1.Height+30; end; Expected: form has the size of button, when the button size changes, the form size changes. Actually: form size does not change.

QC #: 67276 - Status: Closed

QC #: Project Date Reported: Area: 67276 Delphi 9/28/2008 Compiler Description Steps:[QC Short Description] Error if you try to initialize an anonymous method when declared. [QC Description] If you try to initialize an anymous method where it is declared you get an error :- [DCC Fatal Error] Unit39.pas(34): F2084 Internal Error: AV04A02FC9-W0000002C-1 If it's illegal it needs an error message, or if not, needs to compile properly. QC Entry 67276

write the code: type TMyAnomMethod = reference to procedure; var b: TMyAnomMethod = procedure() begin end; then try to compile + you get an internal error. Same happens if you do something a bit more complex: type TMyAnomMethod = reference to procedure; TMyRecord = record anomMethod: TMyAnomMethod; end; var c: TMyRecord = (anomMethod: procedure() begin end); The same Internal error occurs.

QC #: 67290 - Status: Closed

QC #: Project Date Reported: Area:67290 C++Builder 9/29/2008 Documentation\Online Help

Description Steps:[QC Short Description] No help for "Don't collapse ref-to-ref or ptr-to-ref" in C++ Compiler Compatibility options. [QC Description] There's no help for the option C++ Compiler Compatibility option "Don't collapse ref-to-ref or ptr-to-ref". QC Entry 67290

1: New C++ Application. 2: Mneu: Project/Options 3: Select "C++ Compiler, Compatibility". 4: Note that option "Don't collapse ref-to-ref or ptr-to-ref" is listed in "General". 5: Hit F1 (goes to ms-help://embarcadero.rs2009/devcommon/bcc32_c++compatibility_xml.html) Expected: Page includes help for above option. Actual: It's missing.

QC #: 67371 - Status: Closed

QC #: Project Date Reported: Area: 67371 Delphi 10/1/2008 Documentation Description Steps:[QC Short Description] SCoped Enums is not doucmented. [QC Description] "Scoped Enums" is not doucmented in Delphi 2009 Help. QC Entry 67371

=========== fixed in 2010: http://docwiki.embarcadero.com/RADStudio/en/Scoped_Enums_%28Delphi%29

QC #: 67378 - Status: Closed

QC #: Project Date Reported: Area: 67378 Delphi 10/1/2008 Documentation Description Steps:[QC Short Description] Unicode Identifider is not documented [QC Description] In Delphi 2009, All Identifiers can be composed of Unicode Characters, but Help says they should be Alphabets, Numbers and underscore. QC Entry 67378

QC #: 67390 - Status: Closed

QC #: Project Date Reported: Area:67390 Delphi 10/1/2008 Documentation\Online Help\VCL

Description Steps:[QC Short Description] Some functions in help are poorly documented [QC Description] I've previously written some QC reports about missing documentation of some functions in the help file, but I discovered some more. As I do not intend to write a report for each of them, I've listed them here in this report. CharToElementLen DelegatesEqual ElementToCharIndex ElementToCharLen

========================= fixed in 2010: http://docwiki.embarcadero.com/VCL/en/SysUtils.ElementToCharLen http://docwiki.embarcadero.com/VCL/en/SysUtils.DelegatesEqual http://docwiki.embarcadero.com/VCL/en/SysUtils.ElementToCharIndex http://docwiki.embarcadero.com/VCL/en/SysUtils.ElementToCharLen

[..] I give up for now ;-) I advice you to do a search in the help for "This is function" (you will need those quotes!) and see how many results you get for document entries which do not have any useful description added. Please don't forget to do a search for "This is type" and "This is class" , too as this will bring many more incomplete pages. PS: Looked up in the English help QC Entry 67390

QC #: 67537 - Status: Closed

QC #: Project Date Reported: Area:67537 Delphi 10/4/2008 Documentation\Online Help Description Steps:[QC Short Description] Deployment help is out of date and refers to old products [QC Description] The Deploy help here: ms-help://embarcadero.rs2009/devwin32/dapmergemodules_xml.htmlsays to use InstallShield Express, which is no longer part of the product. It also lists all of the Delphi 2006 packages (*100.bpl). QC Entry 67537

Start IDE, hit F1 Go to this help URL: ms-help://embarcadero.rs2009/devwin32/dapmergemodules_xml.html

QC #: 67539 - Status: Closed

QC #: Project Date Reported: Area:67539 Delphi 10/4/2008 Documentation\Online Help Description Steps:[QC Short Description] Several linker options are undocumented [QC Description] Several of the Delphi options under Project Options, Linking are undocumented. The list includes: Set extra PE header flags Set extra PE header optional flags Set OS version fields in PE header Set subsystem version fields in PE header Set user version fields in PE header QC Entry 67539

Go to Project, Options, Delphi Compiler, Linking and hit F1 and note the missing items there

QC #: 67639 - Status: Closed

QC #: Project Date Reported: Area: 67639 Delphi 10/7/2008 IDE\Code Editor Description Steps:[QC Short Description] Options under Code Completion not greyed out when it is off [QC Description] Options dialog allows changing options under Code Completion even

Go to Tools/Options, navigate to Editor Options/Code Insight, uncheck Code Completion and click OK. Open the Options dialog again and observe all checkboxes under the Code Completion appear enabled even though Code Completion is still unchecked.

if it is unchecked. QC Entry 67639

QC #: 67688 - Status: Closed

QC #: Project Date Reported: Area: 67688 Delphi 10/8/2008 IDE\Packages Description Steps:[QC Short Description] Disabled design time packages become enabled after IDE restart [QC Description] If you disable some design time packages under Components\Install Packages or under Project Options\Packages by unchecking the checkboxes, then close Delphi and restart, all packages appear enabled as if you did not change anything. QC Entry 67688

Open a VCL Project Go to Project Options, item Packages and disable some packages by unchecking the checkboxes. Check Default button to be sure. Save all changes, restart IDE, Reopen the project go back to project options and observe checkboxes you unchecked appear checked again. The same happens if you disable packages through menu Component\Install Packages...

QC #: 67691 - Status: Closed

QC #: Project Date Reported: Area:67691 Delphi 10/8/2008 RTL\Delphi\Thread support Description Steps:[QC Short Description] BeginThread memory leak [QC Description] If BeginThread cannot create a new thread (any reason) occures memory leak. QC Entry 67691

function BeginThread(SecurityAttributes: Pointer; StackSize: LongWord; ThreadFunc: TThreadFunc; Parameter: Pointer; CreationFlags: LongWord; var ThreadId: LongWord): Integer; var P: PThreadRec; begin if Assigned(SystemThreadFuncProc) then P := PThreadRec(SystemThreadFuncProc(ThreadFunc, Parameter)) else begin New(P); P.Func := ThreadFunc; P.Parameter := Parameter; end; IsMultiThread := TRUE; Result := CreateThread(SecurityAttributes, StackSize, @ThreadWrapper, P, CreationFlags, ThreadID); end; Variable P : PThreadRec allocated in BeginThread release in ThreadWrapper which not executed if BeginThread not successful.

QC #: 67695 - Status: Closed

QC #: Project Date Reported: Area:67695 C++Builder 10/8/2008 IDE\Project Management\Project Source

Description Steps:[QC Short Description] CppCompile tags move around between saves [QC Description] The tags inside of the <ItemGroup> tags of a .cbproj file change places after a change to project options have been saved. This behavior is a little annoying for .cbproj files under version control when differences need to be compared. My fix request is for tags to retain their placement in the .cbproj file. QC Entry 67695

- Create any new C++Builder project (I did VCL Application) - Save and close the project - Make a backup copy of the .cbproj file for comparison later - Reopen the project - Choose "Project | Options" from the main menu - Click "OK" - Save and close the project - Using a diff program (or visually using notepad, etc) compare the .cbproj file with the backup copy: Here is an example of an affected section: // Original <ItemGroup> <CppCompile Include="Project1.cpp"> <BuildOrder>0</BuildOrder> </CppCompile> <ResFiles Include="Project1.res"> <ModuleName>Project1.res</ModuleName> <BuildOrder>1</BuildOrder> </ResFiles> <CppCompile Include="Unit1.cpp"> <Form>Form1</Form> <DependentOn>Unit1.h</DependentOn> <BuildOrder>2</BuildOrder> </CppCompile> // Current <ItemGroup> <CppCompile Include="Unit1.cpp"> <Form>Form1</Form> <DependentOn>Unit1.h</DependentOn> <BuildOrder>2</BuildOrder> </CppCompile> <ResFiles Include="Project1.res"> <BuildOrder>1</BuildOrder> </ResFiles>

<CppCompile Include="Project1.cpp"> <BuildOrder>0</BuildOrder> </CppCompile> Notice that the original build orders were 0, 1, 2. After the second open and save the build orders are 2, 1, 0. Don't make an assumption that the orders are just reversed. If you first add more units to the project before saving the order can come out 3, 2, 0, 1.

QC #: 67696 - Status: Closed

QC #: Project Date Reported: Area: 67696 Delphi 10/9/2008 Documentation Description Steps:[QC Short Description] Typo error in parameters_xml.html [QC Description] In the following topic: ms-help://embarcadero.rs2009/devcommon/parameters_xml.html A block of text: They are always zero-based. The first element is 0, the second element is 1, and so forth. The standard Low and High functions return 0 and Length1, respectively. The SizeOf function returns the size of the actual array passed to the routine. "...return 0 and Length1, respectively..." should change to "...return 0 and Length - 1, respectively..." QC Entry 67696

This is still broken in ms-help://embarcadero.rs2010/rad/Parameters_(Delphi).html fixed see also Jira http://vmsfjira.embarcadero.com:8665/browse/RAD-2147 FIXED see http://docwiki.embarcadero.com/RADStudio/en/Parameters_%28Delphi%29

QC #: 67699 - Status: Closed

QC #: Project Date Reported: Area: 67699 Delphi 10/9/2008 VCL\Graphics Description Steps:[QC Short Description] StretchDraw JPG from TImage to TBitMap, access violation QC Entry 67699

Start the attached TestProject In the filename textbox fill in the "logo.jpg" file. Press the LOAD button, an access violation will occur. Exactly the same logo loaded in Windows Paint and saved back to "logo_ok.jpg" produces no access violation.

QC #: 67728 - Status: Closed

QC #: Project Date Reported: Area:67728 C++Builder 10/9/2008 Compatibility\BCB<->Delphi Description Steps:[QC Short Description] DynamicArray template class does not use VCL memory management [QC Description] The DynamicArray template class in sysdyn.h uses the C RTL malloc() and free() functions instead of the VCL RTL GetMem() and FreeMem() functions to manage the memory block for the array data. As long as dynamic arrays are used in C++ code only, or Delphi code only, this is not a problem. However, if dynamic arrays are passed

1 - Open the attached project 2 - Enable codeguard if it is not enabled (Project->Option | Debbuging). Set enable codeguard to true (all 3 options). 3 - F9 (compile and run) 4 - Click the form button res: Resource from different RTL in process: TestProject.exe(6984) - c:\program files\codegear\rad studio\6.0\include\vcl\sysdyn.h#383

between C++ and Delphi, this can lead to runtime crashes and CodeGuard errors because different memory managers are being used to allocate and free the array memory. QC Entry 67728

... The memory block (0x00F7BEC0) [size: 4008 bytes] was allocated with SysGetMem ... exp: no message like the one above. When clicking the button, the message: "Array allocated and freed!"

QC #: 67782 - Status: Closed

QC #: Project Date Reported: Area:67782 Delphi 10/10/2008 Documentation\Online Help Description Steps:[QC Short Description] Typo error in structuredtypes_xml.html [QC Description] In topic: ms-help://borland.bds5/devcommon/structuredtypes_xml.html A paragraph written as: Once a dynamic array has been allocated, you can pass it to the standard functions Length, High, and Low. Length returns the number of elements in the array, High returns the array's highest index (that is, Length - 1), and Low returns 0. In the case of a zero-length array, High returns 1 (with the anomalous consequence that High < Low). It should read as: .... In the case of a zero-length array, High returns -1 (with the anomalous consequence that High < Low). High should return -1 for zero-length array. QC Entry 67782

already fixed; not sure when http://docwiki.embarcadero.com/RADStudio/en/Structured_Types

QC #: 67793 - Status: Closed

QC #: Project Date Reported: Area: 67793 Delphi 2/21/2007 VCL Description Steps:[QC Short Description] PNG-compressed 256x256 application icons don't display properly in Vista [QC Description] When using an icon that includes a 256x256 PNG-compressed image for Windows Vista along with smaller sizes as the application icon, the 48x48 image is displayed on the desktop and in Windows Explorer when Vista is configured to shows large icons. This makes the icons of Delphi applications look smaller than all the other icons, as if the developer used an XP-style icon. The problem is only visible on Windows Vista, since earlier versions of Windows don't support icon sizes beyond 48x48 anyway. The problem only occurs with compressed icons. Using an uncompressed 256x256 icon works fine, but results in a significant and needless increase in file size. QC Entry 41098

1. Create a new project 2. In Project Options, select sample_icon_vistacompression.ico as the application icon 3. Compile. 4. Put both sample_icon_vistacompression.ico and the compiled .exe in the same folder. 5. View that folder in Windows Explorer on Vista 6. Click the Views button and select Extra Large Icons in Explorer Expected: sample_icon_vistacompression.ico and the .exe are shown using the same icon Actual: sample_icon_vistacompression.ico is shown full size, but the .exe's icon is small

QC #: 67912 - Status: Closed

QC #: Project Date Reported: Area: 67912 Delphi 10/15/2008 Midas\TDataSetProvider Description Steps:[QC Short Description] TDataSetProvider documentation missing [QC Description] The documentation is missing for the following methods/properties. Protected properties: TransactionStarted Public Properties: ActiveUpdateException OwnerData Protected methods: CheckDataSet FindRecord Reset SetCommandText SetParams Published Events: AfterGetParams BeforeExecute BeforeUpdateRecord OnGetTableName OnValidate QC Entry 67912

QC #: 67959 - Status: Closed

QC #: Project Date Reported: Area: 67959 Delphi 10/15/2008 RTL\Delphi\Pascal Strings Description Steps:[QC Short Description] UnicodeStringToUCS4String / WideStringToUCS4String do not handle surrogate pairs correctly [QC Description] With surrogate pairs, UnicodeStringToUCS4String and WideStringToUCS4String functions in Syste.pas fail to convert. Use of Index for filling UCS4String is wrong. I should be CharCount as below. Result[I] := UCS4Char((Cardinal(S[I + 1]) and $000003FF) shl 10 or (Cardinal(S[I + 2]) and $000003FF) + $00010000); should be Result[CharCount] := UCS4Char((Cardinal(S[I + 1]) and $000003FF) shl 10 or (Cardinal(S[I + 2]) and $000003FF) + $00010000); and Result[I] := UCS4Char(S[I + 1]); should be

Execute this code ------------------------ procedure TForm1.Button1Click(Sender: TObject); var ucs4_str: UCS4String; uni_str: string; begin uni_str := 'AB' + #$D840#$DC0B + 'CD'; ucs4_str := UnicodeStringToUCS4String(uni_str); ucs4_str := WideStringToUCS4String(uni_str); end; ------------------------ Actual result is ucs4_str[0] = 65 ucs4_str[1] = 66 ucs4_str[2] = 131083 ucs4_str[3] = 0 ucs4_str[4] = 67 ucs4_str[5] = 0

Result[CharCount] := UCS4Char(S[I + 1]); QC Entry 67959

Correct result is ucs4_str[0] = 65 ucs4_str[1] = 66 ucs4_str[2] = 131083 ucs4_str[3] = 67 ucs4_str[4] = 68 ucs4_str[5] = 0

QC #: 68106 - Status: Closed

QC #: Project Date Reported: Area: 68106 Delphi 10/20/2008 Documentation Description Steps:[QC Short Description] Tols/Options/Tool-Palette help entry is incomplete [QC Description] This help text is incomplete: ms-help://embarcadero.rs2009/devcommon/toolpalettepage_xml.html It doesn't explain all available options, e.g. what's "keep search filter"? (rough translation from german) QC Entry 68106

1. open IDE 2. open Tools/options menu 3. go to the Tool-Palette section 4. click on the help button 5. wonder what those not explained settings do

QC #: 68109 - Status: Closed

QC #: Project Date Reported: Area: 68109 Delphi 10/20/2008 IDE\Message View Description Steps:[QC Short Description] Echoed Delphi command line does not wrap [QC Description] With the IDE set to echo command lines to the message window, the C++ compiler and linker command lines are wrapped to display on multiple lines and can be read directly in the message window. The Delphi command line, however is not wrapped and inevitably is much longer than the space available. QC Entry 68109

Tools | Options | Environment Options | Compiling and Running | Show command line - checked File | New | VCL Forms App - C++ Project | Build | Project1 Expand compiler and linker command lines in Message Window - note that the lines wrap File | New | VCL Forms App - Delphi Project | Build | Project1 Exp: Wrapped command lines - expandable as in C++ Act: Command line is on a single line and is much more difficult to examine.

QC #: 68126 - Status: Closed

QC #: Project Date Reported: Area:68126 Delphi 10/21/2008 Documentation\Online Help\Main help Description Steps:[QC Short Description] Help to DCC Error E2197 missing or incomplete [QC Description] The documentation to the DCC error "E2197: Constant object cannot be passed as var parameter" is missing or at least not appropriate. Link to help document: ms-

Help | CodeGear help enter URL: ms-help://embarcadero.rs2009/devcommon/cm_const_varpar_xml.html ==================== Fixed in 2010: http://docwiki.embarcadero.com/RADStudio/en/E2197_Constant_object_cannot_be_passed

help://embarcadero.rs2009/devcommon/cm_const_varpar_xml.html Content reads: "This error message is reserved." Please provide a more useful documentation. cu, Michael QC Entry 68126

_as_var_parameter_%28Delphi%29

QC #: 68164 - Status: Closed

QC #: Project Date Reported: Area: 68164 Delphi 10/22/2008 Compiler\Delphi Description Steps:[QC Short Description] Cannot return nil from generic function call [QC Description] If you use a class type constraint in a generic class, and you return this type as the result of a function call, you cannot set Result :=nil QC Entry 68164

If you use the following code, you get error: "E2010: Incompatible types: 'T' and Pointer" TMyGenericClass<T: TComponent> = class private internalList: TList<T>; public function FindItemByName(aName: String): T; end; function TMyGenericClass<T>.FindItemByName(aName: String): T; begin // Search list, if not found, return nil Result:=nil; // #ERROR# end; If you constrain using "class" keyword (TMyGenericClass<T: class> = class), you can return Result := nil.

QC #: 68345 - Status: Closed

QC #: Project Date Reported: Area:68345 Delphi 10/28/2008 Documentation\Online Help\Main help

Description Steps:[QC Short Description] Simple type Char now maps to WideChar [QC Description] In the documentation for simple types, URL: ms-help://embarcadero.rs2009/devcommon/simpletypes_xml.html it reads "The generic character type is Char, which is equivalent to AnsiChar on Win32, and to Char on the .NET platform. Because the implementation of Char is subject to change, it's a good idea to use the standard function SizeOf rather than a hard-coded constant when writing programs that may need to handle characters of different sizes." Since the default string was changed to unicode, Char no longer maps to AnsiChar but WideChar. QC Entry 68345

QC #: 68369 - Status: Closed

QC #: Project Date Reported: Area: 68369 Delphi 10/28/2008 Documentation Description Steps:[QC Short Description] The TFNDrawText type is not documented

Go to the following link:

[QC Description] The TFNDrawText type is not documented QC Entry 68369

ms-help://embarcadero.rs2009/delphivclwin32/StdCtrls_TFNDrawText.html ====================== Fixed in 2010: http://docwiki.embarcadero.com/VCL/en/StdCtrls.TFNDrawText

QC #: 68497 - Status: Closed

QC #: Project Date Reported: Area: 68497 Delphi 11/1/2008 IDE\Build Tools Description Steps:[QC Short Description] Binary image base setting problem [QC Description] In the [project options] - [Delphi Compiler] - [Linking] page have two entries: "Image Base", and "set base address for relocatable image". They seems to have identical meaning to the IDE (both generate -K parameter for dcc32), but they handle input differently. The "Image Base" entry accepts hex number, but the "set base address for relocatable image" does not - a '$' symbol is needed in order to put a hex numer in that entry. In addition, if a hex number is set in the "set base address for relocatable image", the IDE would generate bad -K option, with two '$' in front of the hex number. QC Entry 68497

1. Create a new project. 2. Go to [project options] - [Delphi Compiler] - [Linking] page 3. In the "Image Base" entry, type: 10A00000 3. In the "set base address for relocatable image" entry, type: 10A00000, then try to move the focus away. The IDE will complain '10A00000' is not a valid integer value. 4. Change the input data to $10A00000, and close the property window, save the project. 5. Compile this project, and check the dcc32 commandline. It looks like: <path>\dcc32.exe ... -K10A00000 ... -K$$10A00000 ... Notice it has two -K options, and the second one has two extra '$'. However, the compilation does finish sucessfully, and the produced binary has the intended base address. This could be either the compiler ignores the second -K, or it is coded to handle malformed parameter gracefully.

QC #: 68590 - Status: Closed

QC #: Project Date Reported: Area: 68590 Delphi 11/4/2008 Compiler\Delphi\Generics Description Steps:Typecasts involving generics that are string types can produce unexpected AV errors at run-time.

Compile and run the attached application below. See the following program output indicating failure. FAIL Exception=EAccessViolation/Access violation at address 0040AA65 in module 'bts266353.exe'. Read of address FFFFFFFC program BTS266353; {$APPTYPE CONSOLE} uses SysUtils; type TForm = class function TestProc<gString, gPChar>(sText:gString): gString; procedure ButtonTest(Sender: TObject); end; function TForm.TestProc<gString, gPChar>(sText:gString): gString;var tempResult: gPChar;

begin tempResult := gPChar(sText); //Access violation Result := gString(tempResult); end; procedure TForm.ButtonTest(Sender: TObject); var s: AnsiString; begin s := TestProc<AnsiString, PAnsiChar>(AnsiString('Test')); if S = 'Test' then WriteLn('PASS') else WriteLn('FAIL #1'); end; var Form: TForm; begin try Form := TForm.Create; Form.ButtonTest(nil); except on E: Exception do WriteLn('FAIL Exception=', E.ClassName, '/', E.Message); end; end.

QC #: 68627 - Status: Closed

QC #: Project Date Reported: Area:68627 Delphi 11/5/2008 IDE\Project Management\Project Manager

Description Steps:[QC Short Description] Cant alter position of files in project (build order) [QC Description] There is no way to change the build order of files inside a project. The drag and drop functionality has been broken. QC Entry 68627

try to drag any item in the project manager to a new place. The IDE does not allow it to be dropped.

QC #: 68719 - Status: Closed

QC #: Project Date Reported: Area: 68719 Delphi 11/8/2008 VCL\Action Classes Description Steps:[QC Short Description] TSendMail is useless and bugs [QC Description] 1. TSendMail action in ExtActns is missing "Recepients" and "Subject" properties. The ExecuteAction method will fill those to nil before calling Mapi* functions. This make this class useless. 2. The message text to be send is still ANSI: lpszNoteText := PAnsiChar(AnsiString(Text.Text)); 3. If the user cancels the mail sending window he will receive, a MessageBox will be risen - this is very bad design. A new event like: OnMailSendStatus(Boolean) should be called by this code to allow the developer to take the decision what to do with erros/success code. QC Entry 68719

1. Create a new VCL Forms application 2. Put in a TActionManager. 3. A a new standard action called TSendMail

QC #: 68810 - Status: Closed

QC #: Project Date Reported: Area: 68810 C++Builder 10/6/2008 3:39:26 PM IDE\Project Management Description Steps:Package import libraries (.bpi's) added to a non-package project are not linked. This is especially a problem since changes were made to the runtime package list such that uninstalled packages in it are not explicitly added to the link list.

Create a new C++ package. Add a unit to it (assume Unit1) Add the following to the unit header: #include <System.hpp> String PACKAGE Echo(String Str); Add the following to the unit .cpp: String Echo(String Str) { return Str; } Build the package, but do not install it. Create a new C++ VCL Forms application Add "#include Unit1.h" (the previously created unit) Double-click the form to get an event handler. Add this code to it: ShowMessage(Echo("Hello World")); Build. // Exp and Act: Unresolved external "Echo" referenced from Unit2 Add the package's .bpi to the VCL Forms project. Build. // Exp: Links correctly // Act: Same unresolved external because the link line doesn't contain "package.bpi"

QC #: 68833 - Status: Closed

QC #: Project Date Reported: Area: 68833 Delphi 11/12/2008 RTL\Delphi\Pascal Strings Description Steps:[QC Short Description] IntToStr should use CvtIntW [QC Description] Currently IntToStr uses CvtInt (which generates Ansi) plus a conversion to Unicode String, instead of using the (already existing) CvtIntW, which would avoid the conversion. Additionnally it could be nice to have an IntToStrA, with an AnsiString result (ie. same as current IntToStr implementation, withoutthe conversion). QC Entry 68833

QC #: 68884 - Status: Closed

QC #: Project Date Reported: Area:68884 Delphi 11/13/2008 Compiler\Delphi\Anonymous Methods

Description Steps:[QC Short Description] Incorrect error with higher-order function declarations involving generics.

Compile the attached application below. See the following unexpected compile-time error.

[QC Description] bts266634.dpr(34) Error: E2086 Type 'TFunctional.Curry$ActRec<A,B,R>' is not ye completely defined

bts266634.dpr(34) Error: E2086 Type 'TFunctional.Curry$ActRec<A,B,R>' is not yet completely defined program bts266634; { Incorrect errors with higher-order function declarations involving generics. } {$APPTYPE CONSOLE} uses SysUtils; type TFuncFunc<A,B,R> = reference to function(Arg1:A) : TFunc<B, R>; TFunctional = class public class function PartialApply<A, B, R>(AFunc: TFunc<A, B, R>; AArgA: A): TFunc<B, R>; class function Curry<A, B, R>(AFunc: TFunc<A, B, R>): TFunc<A, TFunc<B, R>>; //#1// class function Curry2<A, B, R>(AFunc: TFunc<A, B, R>): TFuncFunc<A,B,R>; end; class function TFunctional.PartialApply<A, B, R>(AFunc: TFunc<A, B, R>; AArgA: A): TFunc<B, R>; begin Result := function(AArgB: B): R begin Result := AFunc(AArgA, AArgB); end; end; class function TFunctional.Curry<A, B, R>(AFunc: TFunc<A, B, R>): TFunc<A, TFunc<B, R>>; begin Result := function(AArgA: A): TFunc<B, R> begin Result := function(AArgB: B): R begin Result := AFunc(AArgA, AArgB); end; end; end; class function TFunctional.Curry2<A, B, R>(AFunc: TFunc<A, B, R>): TFuncFunc<A, B, R>; begin Result := function(AArgA: A): TFunc<B, R> begin Result := PartialApply<A, B, R>(AFunc, AArgA); end; end; begin try WriteLn('PASS'); //PASS on compile// except on E: Exception do WriteLn('FAIL - Exception - ', E.ClassName, '/', E.Message); end; end.

QC #: 68913 - Status: Closed

QC #: Project Date Reported: Area: 68913 Delphi 11/13/2008 AddOn\IntraWeb Description Steps:[QC Short Description] IntraWeb 10.0.6 fails to handle MBCS string(Japanese etc...) [QC Description] IntraWeb 10.0.6 (Test Release Version) fails to handle MBCS. Pleasse see Steps and attached screenshots. [Version 10.0.6] http://downloads.atozed.com/intraweb/iw10.0.6.exe QC Entry 68913

1. intall VCL for the Web Verion 10.0.6 http://downloads.atozed.com/intraweb/iw10.0.6.exe 2. create VCL for the Web application with Standalone mode 3. add a IWEdit, a IWLabel and a IWButton on the form 4. add OnClick event handler of IWButton as below procedure TIWForm1.IWButton1Click(Sender: TObject); begin IWLabel1.Caption := IWEdit1.Text; end; 5. build and run it 6. input Japanese Kanji characters as attached screenshot, 'before.jpg' 7. click Button 8. the Japanese Kanji characters are corrupted as attached screenshot, 'after.jpg'

QC #: 69036 - Status: Closed

QC #: Project Date Reported: Area: 69036 Delphi 11/18/2008 IDE\Help Description Steps:[QC Short Description] Incomplete documentation for Menu, Tools, Options, Library - Win32, Browsing Path [QC Description] Doc url: ms-help://embarcadero.rs2009/devcommon/delphilibrary_xml.html The documentation for the Browsing path mentions the "Project Browser" in bold letters, but makes no effort to explain what the "Project Browser" actually is and what it is supposed to do. Is it the same as the object browser, or the file browser? When you don't know what the Project Browser does, it is pretty hard to know what the Browsing path is supposed to do. QC Entry 69036

QC #: 69135 - Status: Closed

QC #: Project Date Reported: Area:

69135 Delphi 11/20/2008 Documentation\Online Help\VCL

Description Steps: [QC Short Description] TObject missing documentation [QC Description] Documentation is not available for the following parts of TObject Members topic url: ms-help://embarcadero.rs2009/delphivclwin32/!!MEMBEROVERVIEW_System__TObject.html Public methods - ClassInfo Equals GetHashCode MethodName ToString

UnitName In addition, the following methods which are overloaded could have their description altered sligtly to improve the readability. As it is for these methods the documentaiont states "This is the overview for the <method> method overload." Since overloaded methods are meant to accomplish the same task, I think the description might as well state what task this is. Public methods - FieldAddress MethodAddress Topic urls ms-help://embarcadero.rs2009/delphivclwin32/System__TObject__ClassInfo.html ms-help://embarcadero.rs2009/delphivclwin32/[email protected] ms-help://embarcadero.rs2009/delphivclwin32/System__TObject__GetHashCode.html ms-help://embarcadero.rs2009/delphivclwin32/[email protected] ms-help://embarcadero.rs2009/delphivclwin32/System__TObject__ToString.html ms-help://embarcadero.rs2009/delphivclwin32/System__TObject__UnitName.html ms-help://embarcadero.rs2009/delphivclwin32/!!OVERLOADED_FieldAddress_System__TObject.html ms-help://embarcadero.rs2009/delphivclwin32/!!OVERLOADED_MethodAddress_System__TObject.htmlQC Entry 69135

QC #: 69185 - Status: Closed

QC #: Project Date Reported: Area: 69185 Delphi 11/21/2008 Documentation\Online Help\VCL

Description Steps:[QC Short Description] Missing documentation for TBasicAction [QC Description] The following few members are not documented, they have "this is foo of class bar"-type docs. I have excluded methods that are simply inherited from the parent class TComponent. Url for member overview ms-help://embarcadero.rs2009/delphivclwin32/!!MEMBEROVERVIEW_Classes_TBasicAction.html Protected Fields - FClients Protected Properties Clients Topic urls ms-help://embarcadero.rs2009/delphivclwin32/Classes_TBasicAction_FClients.html ms-help://embarcadero.rs2009/delphivclwin32/Classes_TBasicAction_Clients.html

Fixed in 2010: http://docwiki.embarcadero.com/VCL/en/Classes.TBasicAction_Fields http://docwiki.embarcadero.com/VCL/en/Classes.TBasicAction.FClients http://docwiki.embarcadero.com/VCL/en/Classes.TBasicAction_Properties http://docwiki.embarcadero.com/VCL/en/Classes.TBasicAction.Clients

QC Entry 69185

QC #: 69228 - Status: Closed

QC #: Project Date Reported: Area: 69228 Delphi 11/22/2008 Compiler\Delphi\Generics Description Steps:[QC Short Description] URW1135 when using generics with circular unit dependencies QC Entry 69228 [Tester Recommended] [Affected by the NEW_ENGINE reversion]

Create a new console application Create a new Unit "Unit1" and paste the following code: --------------------------------------- unit Unit1; interface uses Unit2; type TClass1 = class public procedure Foo(List : TGenClass<TObject>); virtual; abstract; end; implementation end. --------------------------------------- Create a new Unit "Unit2" and paste the following code: unit Unit2; interface type TGenClass<T> = class constructor Create; end; implementation uses Unit1; constructor TGenClass<T>.Create; begin end; end. --------------------------------------- Add both units to the project and build

QC #: 69255 - Status: Closed

QC #: Project Date Reported: Area: 69255 Delphi 11/24/2008 Compiler\Delphi Description Steps:[QC Short Description] Memory leak - DateTimeToStr [QC Description] When I call the DateTimeToStr function, it causes a memory leak in my application. Here is an own object serializer for Delphi:

Added by Sysop <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< Calling DateTimeToStr function directly in main block as below, the returned value(string) is not free. ---------------------------------------- program Project1; {$APPTYPE CONSOLE} uses SysUtils; begin ReportMemoryLeaksOnShutdown := True; DateTimeToStr(Now); end. ---------------------------------------- But,

http://jankajanos.spaces.live.com/blog/cns!C3E2695FC6F7B0A4!791.entry I hope you will solve this problem. Thanks. Added by Sysop <<<<<<<<<<<< This issue was reported about Delphi 2006. I changed Version from 10.0 to 14.0 as Sysop. >>>>>>>>>>>> QC Entry 69255

calling DateTimeToStr function in a function as below, the returned value(string) is free properly. ---------------------------------------- program Project1; {$APPTYPE CONSOLE} uses SysUtils; procedure foo; begin DateTimeToStr(Now); end; begin ReportMemoryLeaksOnShutdown := True; foo(); end. ---------------------------------------- >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>

QC #: 69267 - Status: Closed

QC #: Project Date Reported: Area: 69267 C++Builder 11/24/2008 IDE\Project Management Description Steps:[QC Short Description] Files with overriden local options are passed to batch compilation [QC Description] If the batch compile is enabled, the files that have local options set are still passed to the batch compile instead of being processed separatelyQC Entry 69267

1. Open a project with more than one source file 2. In the project options, enable batch compilation 3. Edit some local options for one of the files in the project 4. Make the project. 5. Observe that the file with local options is passed to the batch compile

QC #: 69412 - Status: Closed

QC #: Project Date Reported: Area: 69412 Delphi 11/28/2008 Documentation\Online Help\VCL

Description Steps:[QC Short Description] Controls TMouseWheelEvent Type is not documented [QC Description] In unit Controls, the TMouseWheelEvent has no documentation. The url is: ms-help://embarcadero.rs2009/delphivclwin32/Controls_TMouseWheelEvent.htmlQC Entry 69412

QC #: 69417 - Status: Closed

QC #: Project Date Reported: Area:69417 C++Builder 11/28/2008 Compiler\C++\Front End\Templates

Description Steps:[QC Short Description] Template specialization error [QC Description] Template specialization will fail for recursive templates. // this works template<class T> struct another_test: integral_constant<bool, some_test<int>::value> {};

1 - File - New - Other - C++ Console Application 2 - Paste the code below //-------------------------------------- template <class T, T v> struct integral_constant { static const T value = v; typedef T value_type; typedef integral_constant<T, v> type;

// this fail template<class T> struct another_test: integral_constant<bool, some_test<T>::value> {}; // this works again: template<class T> struct another_test: integral_constant<bool, some_test<T>::value == true> {}; See complete testcase: QC Entry 69417

}; template<class T> struct some_test { static const bool value = true; };template<class T> struct another_test: integral_constant<bool, some_test<T>::value> {}; static const bool result = another_test<int>::value; //-------------------------------------- 3 - Compile act: [BCC32 Error] File6.cpp(17): E2299 Cannot generate template specialization from 'integral_constant<T,v>' exp: Compiles with no error. (This code compiles with Comeau) -----------------------Original Steps (from QC)------------------------ This is ok: template <class T, T v> struct integral_constant { static const T value = v; typedef T value_type; typedef integral_constant<T, v> type; }; template<class T> struct some_test { static const bool value = true; };template<class T> struct another_test: integral_constant<bool, some_test<int>::value> {}; static const bool result = another_test<int>::value; //---------------------------- This will fail: template<class T> struct another_test: integral_constant<bool, some_test<T>::value> {};

QC #: 69726 - Status: Closed

QC #: Project Date Reported: Area:69726 Delphi 12/9/2008 Documentation\Online Help\Main help

Description Steps:[QC Short Description] Simple types: Real types have a wrong range, Exponents shouldn't be negative [QC Description] Go to the documentation for the simple types. ms-help://borland.bds5/devcommon/simpletypes_xml.html# Look at the REAL types: Real48 -2.9 x 10^-39 .. 1.7 x 10^38 should be -2.9 x 10^39 .. 1.7 x 10^38 Single -1.5 x 10^-45 .. 3.4 x 10^38 should be -1.5 x 10^45 .. 3.4 x 10^38 Double -5.0 x 10^-324 .. 1.7 x 10^308 should be -5.0 x 10^324 .. 1.7 x 10^308 Extended -3.6 x 10^-4951 .. 1.1 x 10^4932 should be -3.6 x 10^4951 .. 1.1 x 10^4932 Real -5.0 x 10^-324 .. 1.7 x 10^308 should be -5.0 x 10^324 .. 1.7 x 10^308 I think that the Exponents of the left range shouldn't be negative. That makes no sense.

QC Entry 69726

QC #: 70056 - Status: Closed

QC #: Project Date Reported: Area: 70056 C++Builder 12/20/2008 Documentation Description Steps:[QC Short Description] Linker error documentation is missing [QC Description] No documentation exists for linker errors (such as "Unresolved external 'name' referenced from /unit/"). This is a regression from at least C++Builder 6. QC Entry 70056

- Create a new C++ console application - Insert the following code: // ----- int main (void) { void test (void); test (); } // ----- - Try to build. - The linker error "Unresolved external 'test()' from MAIN.OBJ" occurs. Select it in the build message pane and press F1. Exp.: The help viewer pops up immediately and displays a detailed description of the error. (This is what happens in C++Builder 6.) Act.: After a long initialization phase, the help viewer offers to select one of three linker-related but otherwise useless help entries. Further investigation reveals that linker errors are not documented at all.

QC #: 70068 - Status: Closed

QC #: Project Date Reported: Area: 70068 C++Builder 12/21/2008 Compiler\C++ Description Steps:[QC Short Description] Template class with multiple constructors doesn't compile [QC Description] When defining a simple template class with more than one constructor, Builder won't recognize all of the constructors and as far as I could see, only the first one will work. QC Entry 70068

template <class T> class vector3d { public: // Need to put union first because compiler will stop with known bug E2547 error, ... expected union { struct { T x; T y; T z; }; T v[3]; }; vector3d() : x(0), y(0), z(0) {} vector3d(T nx, T ny, T nz) : x(nx), y(ny), z(nz) {} vector3d(const vector3d<T>& other) : x(other.x), y(other.y), z(other.z) {} }; Later in code: vector3d<float> p(1, 1, 1); Compiler error: [BCC32 Error] File1.cpp(32): E2227 Extra parameter in call to vector3d<float>::vector3d() While vector3d<float> p; will work.

QC #: 70146 - Status: Closed

QC #: Project Date Reported: Area:70146 C++Builder 12/27/2008 Compiler\C++\Front End\Language

Description Steps:[QC Short Description] class members of a struct is not initialized [QC Description] When a struct without a constructor is initialized, constructors of class members are not called. QC Entry 70146

Create a new console application with the following code: #include <iostream> class TFoo { public: TFoo() {std::cout << "TFoo::TFoo()" << std::endl;} }; struct TTest { int Val; TFoo Foo; }; int main() { TTest Test = {5}; return 0; } I expected it to print something to the console indicating that the default constructor is called to initialize the TFoo object. But nothing is shown in the cosnole as no constructor is called.

QC #: 70159 - Status: Closed

QC #: Project Date Reported: Area: 70159 Delphi 12/28/2008 Compiler Description Steps:[QC Short Description] Static constructors

type // ***************************************************************************** // TSingleton (thread safe singleton helper class) //

[QC Description] There aren't static constructors for Win32. How to implement a generic class's static fields without it? I need static constructors to create reference counted objects for the compiler generated types. More details: https://forums.codegear.com/thread.jspa?threadID=9481 QC Entry 70159

***************************************************************************** TSingleton<T: class, constructor> = class strict private class var FInstance: T; // class var FSyncObj: TObject; <= I can't initialize this. {$HINTS OFF} constructor Create; {$HINTS ON} public class function Instance(Creator: TFunc<T>): T; overload; static; class function Instance: T; overload; static; end; var // unfortunately, GlobalSyncObj locks all singletons // because there aren't static constructors for static fields // in unmanaged environment GlobalSyncObj: TObject; // singleton collection Singletons: TObjectList; // instead of GC // SynObjects: TObjectList; // instead of GC

QC #: 70212 - Status: Closed

QC #: Project Date Reported: Area:70212 C++Builder 12/31/2008 ActiveX\Code Generators\C++

Description Steps:[QC Short Description] Incorrect BSTR management in Event Handlers with non-reference String parameters [QC Description] When generating an ActiveX Control (OCX) from a VCL component, any VCL event handler that has String parameters that are not passed by reference are freeing temporary BSTR objects incorrect at runtime.QC Entry 70212

1) File | New | Other | C++Builder Projects | ActiveX | ActiveX Library 1) File | New | Other | C++Builder Projects | ActiveX | ActiveX Control 2) Select TStringGrid (or any component that has event handlers with String reference parameters) 3) Press OK The following type of code is generated: void __fastcall TTestImpl::SetEditTextEvent(TObject *Sender, int ACol, int ARow, const UnicodeString Value) { BSTR TempValue; TempValue = WideString(Value).Copy(); Fire_OnSetEditText((long)ACol, (long)ARow, TempValue); delete TempValue; // <-- wrong way to free a BSTR!! } The last line is not freeing the BSTR correctly. The SysFreeString() function must be used instead. WORKAROUND ============= Change the generated code to call the SysFreeString() function instead of the 'delete' operator: void __fastcall TTestImpl::SetEditTextEvent(TObject *Sender, int ACol, int ARow, const UnicodeString Value) { BSTR TempValue; TempValue = WideString(Value).Copy(); Fire_OnSetEditText((long)ACol, (long)ARow, TempValue); // delete TempValue; SysFreeString(TempValue); // <-- here } Or, stop using BSTR values directly at all and let the WideString class do all of the work: void __fastcall TTestImpl::SetEditTextEvent(TObject *Sender, int ACol, int ARow, const UnicodeString Value) { Fire_OnSetEditText((long)ACol, (long)ARow, WideString(Value).c_bstr()); }

QC #: 70283 - Status: Closed

QC #: Project Date Reported: Area: 70283 C++Builder 1/5/2009 Compiler\C++ Description Steps:[QC Short Description] ICE when instantiating a class template with an anonymous union member [QC Description] C++Builder gives an ICE when instantiating a class template that has an anonymous union member. It also gives various other errors indicating that it can't handle the union's members. QC Entry 70283

#include <limits> #include <iostream> #pragma hdrstop #include <tchar.h> // Example from Google C++ Testing Framework template <size_t size> class TypeWithSize { public: typedef void UInt; }; template <> class TypeWithSize<4> { public: typedef int Int; typedef unsigned int UInt; }; template <> class TypeWithSize<8> { public: typedef __int64 Int; typedef unsigned __int64 UInt; }; template<typename RawType> class FloatingPoint { public: typedef typename TypeWithSize<sizeof(RawType)>::UInt Bits; static const size_t kBitCount = 8*sizeof(RawType); static const size_t kFractionBitCount = std::numeric_limits<RawType>::digits - 1; static const size_t kExponentBitCount = kBitCount - 1 - kFractionBitCount; static const Bits kSignBitMask = static_cast<Bits>(1) << (kBitCount - 1); static const Bits kFractionBitMask = ~static_cast<Bits>(0) >> (kExponentBitCount + 1); static const Bits kExponentBitMask = ~(kSignBitMask | kFractionBitMask); static const size_t kMaxUlps = 4; explicit FloatingPoint(const RawType& x) : value_(x) {} static RawType ReinterpretBits(const Bits bits) { FloatingPoint fp(0); fp.bits_ = bits; return fp.value_; } static RawType Infinity() { return ReinterpretBits(kExponentBitMask); } const Bits &bits() const { return bits_; } Bits exponent_bits() const { return kExponentBitMask & bits_; } Bits fraction_bits() const { return kFractionBitMask & bits_; } Bits sign_bit() const { return kSignBitMask & bits_; } bool is_nan() const { return (exponent_bits() == kExponentBitMask) && (fraction_bits() != 0); } private: union { RawType value_; // The raw floating-point number. Bits bits_; // The bits that represent the number. }; }; #pragma argsused int _tmain(int argc, _TCHAR* argv[]) { FloatingPoint<float> f(1.0); std::cout << f.is_nan() << std::endl; return 0; }

QC #: 70292 - Status: Closed

QC #: Project Date Reported: Area: 70292 Delphi 1/5/2009 IDE\Help Description Steps:[QC Short Description] Broken help context in Options/Delphi Options/Type Library [QC Description] The help for the Options dialog, when displaying the type library option page does not work (help context not found). I tested randomly a few pages and they worked. QC Entry 70292

1- Open Options dialog. 2- Select Delphi Options/Type library. 3- Click the Help button. Error message: "No help found for context".

QC #: 70576 - Status: Closed

QC #: Project Date Reported: Area: 70576 C++Builder 1/16/2009 Compiler\C++\Front End Description Steps:[QC Short Description] inlining broken [QC Description] Inlining of even trivial (empty) member functions is broken. This is a regression in update 3. The problem was already reported as QC#35430/QC#30044 and was fixed in some versions, but now is broken again.

download attachment bcc32 -c -w qc70576.cpp Exp: Clean compile Act: Warning W8026 foo.cpp 1: Functions with exception specifications are not expanded inline This is a regression from the release version with patch 2 applied.

Attached code: class X { public: X() { } }; void foo() { X x; } QC Entry 70576

QC #: 70842 - Status: Closed

QC #: Project Date Reported: Area:70842 C++Builder 1/25/2009 IDE\Code Editor\Syntax Highlighting

Description Steps:[QC Short Description] Files without extension should be syntax-highlighted as C++ headers [QC Description] This was improved in Cogswell, but apparently, the IDE just has an incomplete "whitelist" of files without extension that are C++ headers. IMHO, a better approach would be to use syntax highlighting for all files that reside in a subdirectory of one of the include paths. QC Entry 70842

- Create a new C++ project, add this lines: // ----- #include <string> #include <cstring> // ----- - Now Ctrl+Enter each of the files (or use the context menu instead). Exp.: both files are shown with C++ syntax highlighting Act.: only <string> is syntax-highlighted. (If you have TR1 in your path, <string> refers to $(CG_BOOST_ROOT)\boost\tr1\tr1\string instead of $(BDS)\include\dinkumware\string. No highlighting in that case.)

QC #: 70905 - Status: Closed

QC #: Project Date Reported: Area: 70905 Delphi 1/27/2009 Database Description Steps:[QC Short Description] TVarData.VString interpreted as UnicodeString, while it contains a pointer to an AnsiString [QC Description] A search in DBCommon for the symbol 'VString' (a member of TVarData), results in 8 occurances of this construct : "string(TVarData(Value).VString)". Since 'string' now means UnicodeString, this construct interprets an AnsiString as UnicodeString, without any compiler magic in between. Possibly the new string-header helps preventing errors, but at the very least this is a syntactic error. PS: Don't mix this up with TVarRec.VString: PShortString, it's TVarData.VString: Pointer that's handled wrong. QC Entry 70905

Search in the RTL/VCL code for all 'VString' occurances. Notice that in Variant.pas all TVarData.VString are cast to an AnsiString. Now notice that DBCommon (and other units) do a cast to 'string', which effectively means a cast to 'UnicodeString'.

QC #: 70977 - Status: Closed

QC #: Project Date Reported: Area: 70977 C++Builder 1/29/2009 IDE\Build Tools Description Steps:[QC Short Description] IDE/MsBuild fails to quote hyphenated filenames when invoking TLIB [QC Description] Creating a static library project containing one or more files with

1. Create a static library project. 2. Add a file "a-b.cpp" 3. Bulid it. The following command is run, with the following results: tlib /P32 gtest.lib -+a-b.obj TLIB 6.0 Copyright (c) 1987-2008 CodeGear Warning: 'a' not found in library Warning: 'a.obj' file not found Warning: 'b' not found in library

hyphens in the filename fails, because the hyphens are passed unquoted and unescaped to tlib.exe, so tlib.exe interprets them as "remove modulename from the library" instructions rather than part of the filename. QC Entry 70977

QC #: 71008 - Status: Closed

QC #: Project Date Reported: Area:71008 Delphi 1/30/2009 Compiler\Delphi\Execution Description Steps:[QC Short Description] F2084 Internal Error: D18900 with {$METHODINFO ON} and class helper [QC Description] A class helper with a function that returns a string and {$METHODINFO ON} leads to the parser error D18900 -> see steps QC Entry 71008

- save the following code as MethodInfoAndClassHelperTest.dpr - dcc32 MethodInfoAndClassHelperTest.dpr expected: it compiles actual: Fatal: F2084 Internal Error: D18900 This error doesn't occur with one of this modifications: - the function ReturnString returns something else than a string - the function ReturnString is defined after TTestObject - TTestObject is inherited from TPersistent //--- MethodInfoAndClassHelperTest.dpr --- program MethodInfoAndClassHelperTest; {$APPTYPE CONSOLE} {$METHODINFO ON} type TObjectHelper = class helper for TObject function ReturnString: string; end; function TObjectHelper.ReturnString: string; begin end; type TTestObject = class(TObject) end; begin WriteLn('PASS'); end.

QC #: 71106 - Status: Closed

QC #: Project Date Reported: Area: 71106 Delphi 2/3/2009 Compiler\Delphi\Generics Description Steps:[QC Short Description] Mix enumerators, anonymous functions and generic records - strange error [QC Description] Code in steps not compile with error [DCC Error] Project5.dpr(89): E2010 Incompatible types: 'TEnumerator<Classes.TComponent>' and 'Pointer' QC Entry 71106

try to compile the attached code below. See the following unexpected error for the line marked #1 in the source code. Error: E2010 Incompatible types: 'TEnumerator<Classes.TComponent>' and 'Pointer' program BTS268054; { Mix enumerators, anonumus functions and generic records - strange error } {$APPTYPE CONSOLE} uses SysUtils, Classes; type TEnumerateFunc<T> = reference to function (var NextItem: T): boolean; TEnumerator<T> = record strict private FFunc: TEnumerateFunc<T>; FCurrent: T; public constructor Create(const AEnumerateFunc: TEnumerateFunc<T>); property Current: T read FCurrent; function MoveNext: Boolean; end; TEnumeratorFactory<T> = record strict private FFunc: TEnumerateFunc<T>; public

constructor Create(const AEnumerateFunc: TEnumerateFunc<T>); function GetEnumerator: TEnumerator<T>; end; TMyComponent = class(TComponent) public function GetComponents(AForward: boolean): TEnumeratorFactory<TComponent>; end; {... See file attachment ...} var MyComp: TMyComponent; C: TComponent; begin try MyComp := TMyComponent.Create(nil); try for C in MyComp.GetComponents(True) do; // #1 finally MyComp.Free end; WriteLn('PASS'); except on E:Exception do Writeln('FAIL Exception=', E.Classname, ': ', E.Message); end; end.

QC #: 71144 - Status: Closed

QC #: Project Date Reported: Area: 71144 Delphi 2/4/2009 VCL Description Steps:[QC Short Description] Change images class of TCategoryPanelGroup [QC Description] The TCategoryPanelGroup has a property images of class TImagelist. In my opinion it would be better to make this a TCustomImageList, so the custom made imagelists can also be used. QC Entry 71144

none

QC #: 71185 - Status: Closed

QC #: Project Date Reported: Area:71185 Delphi 2/5/2009 IDE\Code Editor\Error Insight Description Steps:[QC Short Description] Error Insight cannot identify a method class, referenced by class reference [QC Description] The error happen with all class methods, even when all reference are at same unit, when cast by class. // ERROR INSIGHT FAILURE Messages: 'TJazzClass' does not contains a method named 'GetTypeInfo'

1) create a class with class methods 2) declare the class of object class 3) use class reference to call the class methods. this code can reproduce: program EI_QC71185; type TJazzClass = class of TJazzObject; TJazzObject = class(TObject)

'TJazzClass' does not contains a method named 'RegisterTypeInfo' QC Entry 71185

public class procedure Invoke; end; procedure RegisterClassMetaInfo; begin TJazzClass(nil).Invoke; // <<< here end; { TJazzObject } class procedure TJazzObject.Invoke; begin end; begin end.

QC #: 71187 - Status: Closed

QC #: Project Date Reported: Area: 71187 Delphi 2/5/2009 IDE\Code Templates Description Steps:[QC Short Description] Ctrl+Space incorrectly eats the character following the template name [QC Description] When Ctrl+Space is used to expand a template name into a template, the character following the template name disappears. See "Steps". This worked correctly in Delphi 7 but does not in Delphi 2009. Severity comment: This makes the new code template system MUCH more clumsy and less useful than the Delphi 7 system. QC Entry 71187

E.g. 1) Suppose the template name is "abc" and that it expands to "A=B": Suppose that before Ctrl+Space you have: if abc| then Inc(A); After Ctrl+Space you get: if A=Bthen Inc(A); rather than: if A=B then Inc(A); This lost space must then be replaced manually for the code to compile. --- E.g. 2) Suppose the template name is "fan" and that it expands to "FreeAndNil": Suppose that before Ctrl+Space you have: fan|(ObjectReference); After Ctrl+Space you get: FreeAndNilObjectReference); rather than: FreeAndNil(ObjectReference); This lost semicolon must then be replaced manually for the code to compile.

QC #: 71555 - Status: Closed

QC #: Project Date Reported: Area: 71555 Delphi 2/17/2009 RTL Description Steps:[QC Short Description] Buffer in SysUtils.SysErrorMessage is too small [QC Description] Buffer in SysErrorMessage is too small. In Vista there is a messages, which are much longer then 256 symbols. For example: "Code: 560 Indicates that an attempt was made to assign protection to a file system file or directory and one of the SIDs in the security descriptor could not be translated into a GUID that could be stored by the file system. This causes the protection attempt to fail, which may cause a file creation attempt to fail." QC Entry 71555

//I use such code to retrieve error-message: function GetErrorStr(Code: Cardinal): string; var MsgBuf: PChar; begin Result := ''; if FormatMessage(FORMAT_MESSAGE_ALLOCATE_BUFFER or FORMAT_MESSAGE_FROM_SYSTEM, Nil, Code, 0, @MsgBuf, 0, Nil) > 0 then begin Result := MsgBuf; LocalFree(Cardinal(MsgBuf)); end // else // Result := 'Error ' + IntToStr(GetLastError) + ' while getting errorstring' + // ' for code ' + IntToStr(Code); //FormatMessage can return 0, and it will be //a good idea to save at least error-codes end; //Here I search for messages that are longer than 256 symbols. procedure TForm1.FormCreate(Sender: TObject); var i: Integer; s: string; begin for i := 0 to 2000 do begin s:= GetErrorStr(i); if Length(s) > 256 then begin Memo1.Lines.Add('Code: ' + IntToStr(i)); Memo1.Lines.Add(s); end; end; end;

QC #: 71614 - Status: Closed

QC #: Project Date Reported: Area: 71614 C++Builder 2/19/2009 Documentation Description Steps:[QC Short Description] Error in documentation for TStrings.Move [QC Description] The documentation for TStrings.Move contains the following quote. The first example is invalid syntax (missing ");") and should be MyStringsObject.Count - 1. For example, the following lines of code move the string in the first position to the last position. MyStringsObject.Move(0, MyStringsObject.Count MyStringsObject->Move(0, MyStringsObject->Count - 1); QC Entry 71614

QC #: 71632 - Status: Closed

QC #: Project Date Reported: Area:71632 Delphi 2/20/2009 RTL\Delphi\File Management Description Steps:[QC Short Description] myfile := TFileStream.Create (Filename, fmCreate OR fmShareDenyWrite) dont respect sharemode! [QC Description] Hello Developers... PUSH PUSH TFileStream.Create(s, fmCreate OR fmShareDenyWrite ); <==== fmShareDeny* will be ignored TFileStream.Create (system.string, system.word) system.word = 16 Bit fmCreate = $FFFF fmShareDenyWrite = $20 $FFFF or $20 = $FFFF outch direct hit... How's about a TFileStream.CreateEx(s, fmCreate, fmShareDenyWrite ); <==== fmShareDeny* will be --- Some Programms look in ONE single file. One Create the file for Writing it, all others can read the file. Open new file with delph, shared mode deny WRITE , tfilestream or else...

constructor TFileStream.Create(const AFileName: string; Mode: Word; Rights: Cardinal); begin if Mode = fmCreate then begin inherited Create(FileCreate(AFileName, Rights)); ====

dont close file. lockfilehandle := TFileStream.Create(s, fmCreate OR fmShareDenyWrite ); <==== fmShareDeny* will be ignored Open the same file for READ only with another delphi programm... dont work... FSlockfilehandle := TFileStream.Create(Filename, fmOpenRead or fmShareDenyWrite ); <=== NO HANDLE!!!! FSlockfilehandle.Read(macbuffer^,sizeof(macbuffer^)) QC Entry 71632

QC #: 71697 - Status: Closed

QC #: Project Date Reported: Area: 71697 Delphi 2/23/2009 IDE\Open Tools API Description Steps:[QC Short Description] Ability to add own pages to the environment options dialog (Tools | Options) [QC Description] A lot of the OTA plugins add just one item to the main menu for their options. These items could be replaced by pages in the environment options dialog (Tools | Options) if the OTA would provide interfaces for the options dialog. Then almost all options would be accessible in one dialog and some main menu items wouldn't be necessary any longer. I've attached images which shows how this could look like for the JCL options, some options from DDevExtensions and JVCS. Requirements: - hierarchy should be supported (see items below "JCL Options" in the attached images) - a root area (3rd party) should be recommended in the doc, provided as constant, but not enforced (see EnvironmentOptionsOTA3rdPartyArea.png [some plugins care about the "3rd party" area, but "Don't care about 3rd party area" doesn't) QC Entry 71697

have a look at the attached images

QC #: 71714 - Status: Closed

QC #: Project Date Reported: Area: 71714 Delphi 2/24/2009 VCL\Core VCL Classes Description Steps:[QC Short Description] Redundant setting [QC Description] Redundant setting of variable ExStyle in Controls.pas procedure THintWindow.CreateParams(var Params: TCreateParams);... //#1 if NewStyleControls then ExStyle := WS_EX_TOOLWINDOW; // CS_DROPSHADOW requires Windows XP or above if CheckWin32Version(5, 1) then

WindowClass.Style := WindowClass.style or CS_DROPSHADOW; //#2 if NewStyleControls then ExStyle := WS_EX_TOOLWINDOW; ... QC Entry 71714

QC #: 71723 - Status: Closed

QC #: Project Date Reported: Area:

71723 Delphi 2/24/2009 Compiler\Delphi\Code Generation/Optimization

Description Steps:[QC Short Description] Using old style Objects in D2009 fails [QC Description] I have a lot of old BP7 code which uses the old-style Object syntax. It has been working fine (except for error insight) with all versions of Delphi until now, but having gone through the process of de-ANSIing the code to get it to compile I find it crashes as soon as it uses a virtual method call. I have prepared a short test program that runs (after removing the D2009 specific code) in BP7 but fails in D2009. I can get it to run in both either by not initialising the object's field or making the Virtual method static. QC Entry 71723

The following code compiles but fails to run. The problem seems to be with corruption of the VMT after field initialisation. program testD2009; {$APPTYPE CONSOLE} uses SysUtils; Type PObject1 = ^TObject1; TObject1 = Object FCount : Integer; Constructor Init; Procedure Add; virtual; { removing virtual allows the program to run } end; Type PObject2 = ^TObject2; TObject2 = Object(TObject1) Constructor Init; end; Constructor TObject1.Init; begin { Commenting out this assignment allows the program to run. It also runs if Procedure Add; is not Virtual. I presume there is some address mismatch resulting in an over-write of the VMT } FCount := 0; Writeln('TDynArray:Init'); end; Procedure TObject1.Add; begin Writeln('Add'); end; Constructor TObject2.Init; begin Inherited Init; Writeln('TObject2:Init'); end; Var Object1 : PObject1; Object2 : PObject2; begin try Object1 := New(PObject1,Init); Object1^.Add; Object2 := New(PObject2,Init); Object2^.Add; readln; except on E:Exception do Writeln(E.Classname, ': ', E.Message); end; end.

QC #: 71881 - Status: Closed

QC #: Project Date Reported: Area: 71881 Delphi 3/2/2009 Internet\CGI Application Description Steps:[QC Short Description] TCGIRequest.GetFieldByName is broken [QC Description] AdjustHTTP function defined as local function inside CGIHTTP.TCGIRequest.GetFieldByName uses AnsiStrPos incorrectly. As a result, it is e.g. Impossible to read the correct value of TWebRequest.ContentLength property of a TCGIRequest when apache web server is used (recreatable at least using version 2.2.11). The problematic line in CGIHTTP.pas: if AnsiStrPos(PAnsiChar(SHttp), PAnsiChar(Name)) = PAnsiChar(Name) then The correct one would be (the sub-string to be searched must be the second parameter): if AnsiStrPos(PAnsiChar(Name), PAnsiChar(SHttp)) = PAnsiChar(Name) then QC Entry 71881

1. Create web broker cgi-application that uses ContentLength of a web request and use it in apache web server. 2. Send a request that has some content to the web server and cgi-application. Result: -1 is returned as result of ContentLength.

QC #: 71984 - Status: Closed

QC #: Project Date Reported: Area: 71984 Delphi 3/5/2009 Midas\TProvider Description Steps:[QC Short Description] ApplyUpdates with empty string fields yields null values in where clause [QC Description] When I pull some data into a TClientDataset using a Provider with UpdateMode := upWhereAll, and then i apply updates to a changed record: If some of the string fields in the record being updated are blank (but not null) I get "Record not found or changed by another user" because the update statement is sending `where myStringField is null` instead of `where myStringField = ""` QC Entry 71984 Added by Sysop <<<<<<<<< This issue seems to be related to QC#67891/RAID#265858. >>>>>>>>>

TDBXWeaverBugsSuite.native.Db.Test.exe connection=mysqlconnection -s:TestRaid_268357 -or- Set up an app with the following components: TClientDataset->TDataSetProvider->TSQLQuery->TSQLConnection Set UpdateMode := upWhereAll on the provider. Create a test table (this is MySQL Syntax) create table ATest( ID integer not null, Name varchar(50) not null, Name2 varchar(50) not null ); insert into ATest values(1,'text','text'); insert into ATest values(2,'change',''); Using a DBGrid, change the 'change' data to 'test' and ApplyUpdates. The query built by the provider and sent to the server will look like: update ATest set Name = 'test' where ID = 2 and Name = 'change' and Name2 is null <-- this is wrong ----- It looks like TWideStringField.OldValue is returning a null variant for any empty string field -- but only during ApplyUpdates! Calling TWidestringField.OldValue on empty string fields during normal runtime returns a true empty string.

QC #: 72052 - Status: Closed

QC #: Project Date Reported: Area:72052 C++Builder 3/9/2009 Compiler\C++\Front End\Exception Handling

Description Steps:[QC Short Description] Throw exception in constructor causes assertion fail [QC Description] When throwing an exception from the constructor the following error message appears: "Assertion failed: elemType->tpClass.tcpFlags & CF_HAS_DTOR, file xx.cpp, line 4130" and the application terminates with the message "Abnormal program termination" This problem only occurs in release build. QC Entry 72052

Create a VCL Forms Application and add this code: //--------------------------------------------------------------------------- #include <vcl.h> #pragma hdrstop #include <string> #include <fstream> #include <exception> #include "main.h" //--------------------------------------------------------------------------- #pragma package(smart_init) #pragma resource "*.dfm" TForm1 *Form1; //--------------------------------------------------------------------------- class Bug { public: Bug() :m_Internal(NULL) { } void Test() { m_File.open("c:\\tmp\\test.bin", std::ios::binary); m_Internal = new Internal(m_File); } private: class Internal { public: Internal(std::ifstream& file) { throw std::runtime_error("WTF"); } }; Internal* m_Internal; std::ifstream m_File; }; //--------------------------------------------------------------------------- __fastcall TForm1::TForm1(TComponent* Owner) : TForm(Owner) { } //--------------------------------------------------------------------------- void __fastcall TForm1::Button1Click(TObject *Sender) { try { Bug b; b.Test(); } catch(const std::runtime_error& re) { ShowMessage(re.what()); } } //---------------------------------------------------------------------------

QC #: 72207 - Status: Closed

QC #: Project Date Reported: Area: 72207 C++Builder 3/13/2009 Database\DataSnap\Server Description Steps:[QC Short Description] DataSnap Server Module Missing [QC Description] Unlike Delphi the Data Server Module is missing under C++ Builder files. Try to replicate the DataSnap 2009 Delphi whitepaper exactly like it is presented. QC Entry 72207

1) Create a new VLC application 2) Add the three DataSnap contgrols from the datasnap server. 3) Go to new and Add the Server Data module from the C++ files. It is missing!

QC #: 72212 - Status: Closed

QC #: Project Date Reported: Area: 72212 Delphi 3/13/2009 IDE\Dialogs Description Steps:[QC Short Description] Allow resize "Remove from project" dialog [QC Description] The "remove from project" dialog is very small, far too small, some of my units names are only half displayed. The dialog is not resizable. Please, make it resizable (I suspects it takes 30 seconds to do) and restore the size the user has selected. QC Entry 72212

QC #: 72297 - Status: Closed

QC #: Project Date Reported: Area: 72297 Delphi 3/17/2009 VCL\Additional Controls Description Steps:[QC Short Description] Request Property: TButtonedEdit.LeftButton\RightButton.Hint [QC Description] Request Property: TButtonedEdit.LeftButton\RightButton.Hint QC Entry 72297

QC #: 72338 - Status: Closed

QC #: Project Date Reported: Area: 72338 C++Builder 3/19/2009 Documentation Description Steps:[QC Short Description] Document __published keyword

[QC Description] The documentation for the __published keyword should explain what the keyword does, where it's used, and how it supports reflection / enhanced RTTI. A high-level overview of reflection / enhanced RTTI within C++Builder would be good. (If there is already such an overview, I haven't been able to find it.) A link to the TypInfo namespace might be good. QC Entry 72338

QC #: 72440 - Status: Closed

QC #: Project Date Reported: Area:72440 C++Builder 3/24/2009 Compiler\C++\Front End\Templates

Description Steps:[QC Short Description] Template specialization error [QC Description] Recreate of QC #68567 - it is NOT fixed and NOT a test case error. Template specialization will fail for recursive templates. The following code compiles fine with Comeau but BCC gives [BCC32 Error] E2299 Cannot generate template specialization from 'integral_constant<T,v>' Attached code: template <class T, T v> struct integral_constant { static const T value = v; typedef T value_type; typedef integral_constant<T, v> type; }; template<class T> struct some_test { static const bool value = true; }; template<class T> struct another_test: integral_constant<bool, some_test<T>::value> {}; static const bool result = another_test<int>::value; int main() { return result ? 0 : 1; } QC Entry 72440

bcc32 -c qc72440 Exp: Clean compile as in Comeau on-line Act: Error E2299 qc72440.cpp 12: Cannot generate template specialization from 'integral_constant<T,v>' Error E2303 qc72440.cpp 12: Type name expected Error E2451 qc72440.cpp 14: Undefined symbol 'value'

QC #: 72682 - Status: Closed

QC #: Project Date Reported: Area: 72682 C++Builder 4/2/2009 Documentation Description Steps:[QC Short Description] Final output directory is the intermediate directory when not specified [QC Description] BCB6 help says: Final output specifies where your final target (.EXE, .BPL, or .DLL) is placed. Default = no default. If not specified, the target is placed in the same

Create a console application project with a specified intermediate directory and leave the final output directory blank. Build project. Observe the exe file being produced in the intermediate directory.

directory as the project file (.BPR). With 2009 when the directory is not specified the intermediate directory is used. This is not stated in the help information with 2009. This change of defaults was intentional and should be reflected in the help QC Entry 72682

QC #: 72733 - Status: Closed

QC #: Project Date Reported: Area:72733 C++Builder 4/3/2009 Compiler\C++\Front End\Language

Description Steps:[QC Short Description] BCC wrongly enforces const and volatile correctness for class methods [QC Description] __classmethod member functions do not require an object and should therefore not be sensitive to cv-qualifiers. QC Entry 72733

Compile this (bcc32 qc72733.cpp): // ----- #include <System.hpp> struct Foo : public TObject { static void bar (void) {} void __classmethod baz (void) {} }; int main (void) { Foo* f; volatile Foo* vf; const Foo* cf; const volatile Foo* vcf; // calling the static function f->bar (); // works vf->bar (); // works cf->bar (); // works vcf->bar (); // works // calling the class method f->baz (); // works vf->baz (); // fails with E2523 cf->baz (); // fails with E2522 vcf->baz (); // fails with both E2522 and E2523 } // ----- Exp.: compiles Act.: fails as annotated in the comments [Edit] It has been argued that class methods can alter the base classes' static members and therefore must respect cv-correctness. I disagree for the following reasons: - cv qualifiers apply to objects only, not to classes. As can be seen, a static method may be invoked through a const or volatile object reference. - The only difference between a class method and a static method (leaving the option of virtual class methods apart) is that the class method can be bound to an object at runtime whereas the static method is bound at compile time. There is no difference in how they access static member variables of their classes. - Neither static methods nor class methods can be declared as const or volatile.

QC #: 72764 - Status: Closed

QC #: Project Date Reported: Area:72764 Delphi 4/5/2009 ActiveX\Code Generators\Pascal

Description Steps:[QC Short Description] ActiveX Pascal Code Error! [QC Description] [ uuid(08309809-FA6C-439D-808C-F84DB15A31AB), helpstring("Interface for ErrorString Object"), oleautomation ] interface IErrorString: IUnknown { [id(0x00000065)] HRESULT _stdcall AnsiStrMethod([in] LPSTR MyAnsiStr); [id(0x00000066)] HRESULT _stdcall WideStrMethod([in] LPWSTR MyWideStr); }; QC Entry 72764

1/create a COM Object [ uuid(08309809-FA6C-439D-808C-F84DB15A31AB), helpstring("Interface for ErrorString Object"), oleautomation ] interface IErrorString: IUnknown { [id(0x00000065)] HRESULT _stdcall AnsiStrMethod([in] LPSTR MyAnsiStr); [id(0x00000066)] HRESULT _stdcall WideStrMethod([in] LPWSTR MyWideStr); }; the pascal code: type TErrorString = class(TTypedComObject, IErrorString) protected function AnsiStrMethod(MyAnsiStr: PChar): HResult; stdcall; function WideStrMethod(MyWideStr: PWideChar): HResult; stdcall; end; theses code is error,must be type TErrorString = class(TTypedComObject, IErrorString) protected function AnsiStrMethod(MyAnsiStr: PAnsiChar): HResult; stdcall; function WideStrMethod(MyWideStr: PWideChar): HResult; stdcall; end;

QC #: 73014 - Status: Closed

QC #: Project Date Reported: Area: 73014 Delphi 4/15/2009 IDE\Open Tools API Description Steps:[QC Short Description] Better support for designing dockable IDE forms [QC Description] It would be nice if you would deliver the "Units and Forms required to create Dockable IDE Forms" together with the ToolsAPI source, because otherwise one can hardly design dockable IDE windows. Still with it wouldn't be that easy (-> see steps) and if you have a better solution in mind then this is of course also acceptable. I've recently created a new expert and in order to take advantage of the default dockable layout and the desktop save feature I made the main form a dockable IDE window. I found some information how to do this in the following DN articles "Opening Doors: Getting Inside the IDE" http://dn.embarcadero.com/article/21114 "Creating a Web Search Wizard using the OpenTools API." http://dn.embarcadero.com/article/26418 and downloaded the following from Code Central, because I found the "link" to this in the first article. "ID: 14529, Units and Forms required to create Dockable IDE Forms"http://cc.embarcadero.com/Item/14529 The Zip-file of CC 14529 contains the following files BaseDock.dfm BaseDock.pas DeskForm.dfm DeskForm.pas DeskStrs.pas DeskUtil.pas DockForm.dfm DockForm.pas DockToolForm.dfm DockToolForm.pas DummyDockProj.dpr DummyDockProj.res IDEDockGroup.bpg These files should be updated to match the recent IDE and file formats (.groupproj instead of .bpg) and so on and should be added to a sub folder of the ToolsAPI source - for exam. ...\RAD Studio\x.y\source\ToolsAPI\DockableFormStubs (Maybe you find a better name...) To make clear that these files are not supposed to be compilable (someone expected that in article 21114) adding something like {$MESSAGE Fatal } could help. For DeskForm this could look like this unit DeskForm; {$MESSAGE Fatal 'This file cannot be compiled. This stub exists to give you the possibility to design IDE forms.'} interface Open question: Are such messages localizable? QC Entry 73014

today with Delphi 2009: - somehow manage to find "ID: 14529, Units and Forms required to create Dockable IDE Forms" http://cc.embarcadero.com/Item/14529 - start Delphi 2009 - open DummyDockProj.dpr - add a new form inherited from "DockableToolbarForm" * File | New -> New * select page "Delphi Projects" | Inheritable Items * select "DockableToolbarForm" - save this form - remove this form from the DummyDockProj.dpr project - add your existing wizard package/DLL expert project to the current project group (DummyDockProj.dpr should stay in this project group) - add the prior saved form to your wizard package/DLL expert -> now you can design your form ... - whenever you later plan to work on your dockable form then make sure that DummyDockProj.dpr is part of the project group

QC #: 73025 - Status: Closed

QC #: Project Date Reported: Area: 73025 Delphi 4/16/2009 Modeling\Audits Description Steps:[QC Short Description] MCP Info about filed which can be made private wrong [QC Description] Together QA audits reports one of my fields in a class definition as "can be made private". But: it is already private! Tf_Farbpalette = class(TForm) BitBtn1: TBitBtn; procedure BitBtn1Click(Sender: TObject); private Abbruch : boolean; procedure SaveValues; public end; Abbruch can be made private it claims. As I've found out now this problem also repeats with other units/classes and is also there when the private section only contains one object reference as field. QC Entry 73025

[Added by VSh] Correct result warning: it should say "can be made strict private" as it sais in audit description "it is suggested that class members should be made strict private" [vk] it seems it was fixed for a long time ago UPD: ML: audit text should be corrrected. please see test: unit Unit3; interface type C1 = class procedure P1; private F1: integer; procedure P2; end; implementation { C1 } procedure C1.P1; begin F1:=1; P2; end; procedure C1.P2; begin end; end. run MCP audit for it - see audit text - 'strict' word should be added there EXP: 'Method AA can be made strict private' audit text ACT: 'Method AA can be made private' audit text same for fields

QC #: 73047 - Status: Closed

QC #: Project Date Reported: Area: 73047 Delphi 4/16/2009 Modeling\Audits Description Steps:[QC Short Description] Possibly wrong warning about uninitialized global var [QC Description] QA audits warns me about one global variable in a unit which is uninitialized. It's a integer and in the initialization section of this unit it gets initialized. The only thing I could think about is if another unit uses this one and could have access to the var before the initialization section of the unit is run. Can this be? If not this check isn't yet intelligent enough in my eyes.

1. create some application as follows: Unit QATest; interface procedure DoIt; implementation var myglobgalvar:TObject; procedure DoIt; begin myglobalvar.Free; end; initialization myglobalvar:=TObject.Create; end. 2. enable modeling support and run QA audits 3. see it complain that myglobalvar never gets initialized

QC Entry 73047

QC #: 73170 - Status: Closed

QC #: Project Date Reported: Area: 73170 Delphi 4/20/2009 IDE\History View Description Steps:[QC Short Description] Save the internal layout of the history view [QC Description] The internal layout of the history view is not saved. In the default layout, the actual code window at the bottom is tiny. Increase this and save the positions of the splitters with the general layout. QC Entry 73170

QC #: 73224 - Status: Closed

QC #: Project Date Reported: Area:73224 C++Builder 4/21/2009 Compiler\C++\Front End\Preprocessor

Description Steps:[QC Short Description] Incorrect warning issued by compiler when using some macros [QC Description] When using MAKEWORD macro with all warnings turned on compiler reports this: W8084 Suggest parentheses to clarify precedence QC Entry 73224

1. Create empty, no vcl, multithreaded console program 2. Turn on all warnings in project settings. 3. Copy this code in main cpp file #include <windows.h> #include <tchar.h> int _tmain(int argc, _TCHAR* argv[]) { (argc), (argv); WORD w = MAKEWORD(2,2); return 0; } 4. Compile it and you will receive the warning W8084 which I think you should not.

QC #: 73245 - Status: Closed

QC #: Project Date Reported: Area: 73245 Delphi 4/22/2009 RTL\Delphi\DateUtils Description Steps:[QC Short Description] DateUtils IncHour, IncMinute,... are not working as expected [QC Description] The function IncHour, IncMinute, IncSecond and IncMilliSecond of the unit DateUtils (rtl) are not working as expected in Delphi 2009. The passed value (first parameter) is only increase if it is >0. Otherwise the value is decrease [E.g.: IncHour(0, 12) = -0.5] If you have to decrease the value in case the first parameter is negative, than please change the code in a way that if 0 is passed the value will be increased. Thanks! QC Entry 73245

Compile and run the attached application below. See the following program output indicating failure. FAIL Value=-0.5000 program BTS269172; {$APPTYPE CONSOLE} uses SysUtils, DateUtils; procedure DoIt; var Value: TDateTime; begin Value := DateUtils.IncHour(0, 12); if abs(Value - 0.5) < 1e-6 then WriteLn('PASS') else

WriteLn('FAIL Value=', Value:0:4); end; begin try DoIt; except on E: Exception do begin WriteLn('FAIL - Exception Error'); WriteLn(' ClassName=', E.ClassName); WriteLn(' Message=', E.Message); end; end; end.

QC #: 73365 - Status: Closed

QC #: Project Date Reported: Area:73365 Delphi 4/25/2009 IDE\Refactoring\Introduce Variable

Description Steps:[QC Short Description] Problems with Introduce Variable (Introduce Field) [QC Description] The refactoring "Introduce Variable" opens a dialog for entering the new variable name, but nothing happens. The same problem also exists in the "Introduce Field" dialog. This functionality is not working under D2009,OS Vista SP1 Under D2007 and OS XP this functionality is working correct in both variants QC Entry 73365

1. Create a new VCL application 2. Create a new form and put on button 3. add the following code (OnClick Event): procedure TForm1.Button1Click(Sender: TObject); var x, y: integer; zz: Integer; z: Integer; begin x:=1; y:=2; z:=x+y; zz:=x+y+1; end; 4. Add Together Support to the project 5. Now select the "x+y" expression, and from the Refactor menu select "Introduce Variable". 5. you get a dialog with the title "Introduce Variable" which correctly shows the new variable type as integer and allows entering a name. 5. Enter a name vor the new variable, e.g. "Summe" 6. There is also a checkbox on that dialog saying "Replace all occurrences (2 occurrences found). Check It 7.Press OK. 8. ...nothing happens

QC #: 73374 - Status: Closed

QC #: Project Date Reported: Area: 73374 Delphi 4/26/2009 Debugger\CPU Description Steps:[QC Short Description] Debugger shows PREFETCHT#/PREFETCHh with typo [QC Description] The PREFETCHh/prefetchT# (prefetcht0, prefetcht1, prefetcht2) instructions appear with a typo in the debugger: The debugger displays "prefetch0"/1/2 instead of "prefetchT0"/1/2. (Note the "T" in the instruction name; the prefetchnta instruction is not affected.) Reference: Intel® 64 and IA-32 Architectures Software Developer’s Manual Volume 2B: Instruction Set Reference, N-Z See also: https://forums.codegear.com/thread.jspa?threadID=16160 QC Entry 73374

Add the following to a delphi project and view in debugger: asm prefetcht0 [eax+512] //0F188800020000 prefetch0 byte ptr [eax+$00000200] prefetcht1 [eax+512] //0F189000020000 prefetch1 byte ptr [eax+$00000200] prefetcht2 [eax+512] //0F189800020000 prefetch2 byte ptr [eax+$00000200] end;

QC #: 73376 - Status: Closed

QC #: Project Date Reported: Area: 73376 Delphi 4/26/2009 Debugger\CPU Description Steps:[QC Short Description] Disassembly of the CVTSD2SS has a typo [QC Description] There's a typo in the disassembly of the CVTSD2SS instruction: The disassembled instruction reads "cvtSS2ss" instead of "cvtSD2ss" QC Entry 73376

Add the following to a Delphi app and view in the debugger: asm cvtsd2ss xmm1, xmm2 //Disassembly: F20F5ACA cvtss2ss xmm1,xmm2 end;

QC #: 73441 - Status: Closed

QC #: Project Date Reported: Area:73441 C++Builder 4/28/2009 Compiler\C++\Front End\Object Generation

Description Steps:[QC Short Description] Compiler generates faulty code when allocating arrays of Delphi classes [QC Description] For some reason, the compiler's front end permits the allocation of arrays of Delphi classes. However, the compiler doesn't really support the construction of arrays of Delphi classes. It just allocates 12 bytes (which is 8 bytes too few anyway because of the hidden fields - i.e., the compiler should invoke TObject::InstanceSize()) and calls the RTL function _vector_new_ldtc_() to initialize the objects - but _vector_new_ldtc_() was designed solely for C++-style classes and therefore runs into AVs when applied to a Delphi class. IMHO, the compiler should not allow the construction of Delphi-class object arrays in the first place, but if it does, it should at least a) allocate enough memory (by querying InstanceSize()) and b) call the constructors in the right way. QC Entry 73441

bcc32 -WCV qc73441.cpp Exp.: This should either work or the compiler should issue and error to the effect of: cannot allocate arrays of Delphi-style classes Act.: compiles, AV at runtime [Marcio Crocomo] When compiling with Tiburon 12.0.3210.17555, there is an AV at runtime When compiling with Weaver 14.0.3391.20582, program ends with: Abnormal program termination

QC #: 73566 - Status: Closed

QC #: Project Date Reported: Area:73566 Delphi 5/2/2009 RTL\Delphi\File Management Description Steps:[QC Short Description] In SysUtils, Buffers of length MAX_PATH in the Unicode world are dangerous QC Entry 73566

From SysUtils.pas function ExpandFileName(const FileName: string): string; var FName: PChar; Buffer: array[0..MAX_PATH - 1] of Char; begin SetString(Result, Buffer, GetFullPathName(PChar(FileName), Length(Buffer), Buffer, FName)); end; When ExpandFileName is called with a path longer than MAX_PATH you get back a string full of nulls. Unicode filepaths can be up to 32k TChars. eg (\\?\Dir\SubDir\..........\FileName) See: Naming a File (ms-help://embarcadero.rs2009/FileIO/fs/naming_a_file.htm) <QUOTE> The Unicode versions of several functions permit a maximum path length of approximately 32,000 characters composed of components up to 255 characters in length. To specify that kind of path, use the "\\?\" prefix. Note The maximum path of 32,000 characters is approximate, because the "\\?\" prefix can be expanded to a longer string, and the expansion applies to the total length. For example, "\\?\D:\<path>". To specify such a UNC path, use the "\\?\UNC\" prefix. For example, "\\?\UNC\<server>\<share>". These prefixes are not used as part of the path itself. They indicate that the path should be passed to the system with minimal modification, which means that you cannot use forward slashes to represent path separators, or a period to

represent the current directory. Also, you cannot use the "\\?\" prefix with a relative path. Relative paths are limited to MAX_PATH characters. When using the API to create a directory, the specified path cannot be so long that you cannot not append an 8.3 file name. The shell and the file system may have different requirements. It is possible to create a path with the API that the shell UI cannot </QUOTE> The entire RTL/VCL needs to be checked for any other situations where MAX_PATH is used to define the lenght of a buffer, then determine if any changes are required.

QC #: 73617 - Status: Closed

QC #: Project Date Reported: Area: 73617 Delphi 5/4/2009 IDE\Object Inspector Description Steps:[QC Short Description] UI flaws on High DPI systems [QC Description] Despite Delphi being one of the development tools that can handle DPI changes elegantly if coded properly. the IDE itself is not fully DPI aware. QC Entry 73617

Object inspector and TValueListEditor do not adjust the row size to match the font, so the text is clipped. Run -> Parameters dialog has one combo box squashed to 0 width for some strange reason... Screenshots attached.... I'm sure the issues can be fixed with less than 20 lines of code changed..

QC #: 73791 - Status: Closed

QC #: Project Date Reported: Area: 73791 Delphi 5/11/2009 Midas\TClientDataSet Description Steps:[QC Short Description] ClientDataSet.Locate, DSCursor.LocateWithFilter not working properly [QC Description] TClientDataSet.Locate not working (alwayd returns false) for fields after huge "string.uni" widestring fields. Problem seems to be related with IDSCursor.LocateWithFilter. Midas.dll from Delphi 2006 also fails this. Added by Sysop <<<<<<<<<<<< This issue still exists in Delphi 2010 w/ Update4,5. >>>>>>>>>>>> QC Entry 73791

TDBXFulcrumBugsSuite.Native.DB.Test.exe connection=ibconnection -s:TestRaid_274249 -OR- Open attached project, build, run. Program loads included cdslist2.xml mybase xml file. 1) First locate button fails to locate on field named "_ID" 2) Second locate button locates "_ID2" field as expected The only difference between the two field is their position in cdslist2.xml metadata/fields section.

QC #: 73922 - Status: Closed

QC #: Project Date Reported: Area: 73922 C++Builder 5/13/2009 Compiler\C++ Description Steps:[QC Short Description] __declspec(dllexport) combined with try-catch in an inline function causes E2138 [QC Description] The following code doesn't compile:

bcc32 -c qc73922.cpp Exp.: compiles Act.: Error E2138 qc73922.cpp 6: Conflicting type modifiers in function Foo::bar()

// ----- class exception {}; __declspec (dllexport) struct Foo { void bar (void) { try {} catch (const exception& e) {} } }; // ----- Error E2138 qc73922.cpp 6: Conflicting type modifiers in function Foo::bar() This code , which should be equivalent, compiles fine: // ----- class exception {}; __declspec (dllexport) struct Foo { void bar (void); }; inline void Foo::bar (void) { try {} catch (const exception& e) {} } // ----- QC Entry 73922

QC #: 73957 - Status: Closed

QC #: Project Date Reported: Area:73957 Delphi 5/15/2009 VCL\Standard Controls\TPopupMenu

Description Steps:[QC Short Description] TPopupMenu cannot be closed programatically [QC Description] TPopupMenu has a method for opening it via code but no means to close it via code. Please provide this capability. QC Entry 73957 Use the EndMenu API function to do this programatically.

QC #: 73986 - Status: Closed

QC #: Project Date Reported: Area: 73986 Delphi 5/16/2009 Install\User Interface Description Steps:[QC Short Description] Download information a few pixels too low on the screen [QC Description] In Windows 7 RC running in a VMWare session (thus without aero glass) the "bytes received" info is cutting into the surrounding frame. Not sure if that happens in vista or with aero glass as well QC Entry 73986

Run the installer in a Windows 7 VMWare session. Screen attached.

QC #: 73995 - Status: Closed

QC #: Project Date Reported: Area:

73995 Delphi 5/16/2009 IDE\Code Editor\Formatting Description Steps:[QC Short Description] [3417] Code Formatter: No menu item [QC Description] I noticed that the Formatter can only work on pas files in a project. Otherwise there is no item in the menu. e.g. load Math.pas unit with Open File and right click in the editor window --> no menu item QC Entry 73995

It was in the CodeFormatter requirements. http://radblog.codegear.net/wiki/index.php?title=Source_Code_Formattersee Design Overview "Worst use cases". We have now problems with files outside project [vk] Formatting files not in the project fixed in rev.23158 all other - 23191 refixed: rev.23211 [vk]All is OK for Delphi, but the same bug occures now in cpp [vk] refixed - in the trunk rev.24349 in the branch - rev.24350

QC #: 74035 - Status: Closed

QC #: Project Date Reported: Area: 74035 Delphi 5/18/2009 Internet\Indy Description Steps:[QC Short Description] IdSNTP broken in D2009 [BUGFIX included] [QC Description] Threre is an Unicode Bug in IdSNTP shipped with Delphi. This will cause wrong time results. QC Entry 74035

uses IdSNTP; procedure Test; var IdSNTP: TIdSNTP; begin IdSNTP := TIdSNTP.Create; IdSNTP.ReceiveTimeout := 2500; IdSNTP.Port := 123; IdSNTP.Host := 'ptbtime1.ptb.de'; ShowMessage('Wrong Date: ' + DateTimeToStr(IdSNTP.DateTime)); FreeAndNil(IdSNTP); end;

QC #: 74036 - Status: Closed

QC #: Project Date Reported: Area: 74036 Delphi 5/18/2009 Modeling\Metrics Description Steps:[QC Short Description] AV happens after 'QA Metrics' execution and during the end of IDE. [QC Description] OS : Windows Vista Ultimate SP1, Japanese Weaver : Build 3417, Japanese I installed Visual Studio 2008 in order to get information more. I got the address with the JIT debugger of VS2008. I installed the Weaver English edition in Windows XP Japanese. However, I was not able to reproduce AV. -- July 3, 2009 Edit Similarly in Build3462, AV occurs. I attached to bds by bds. I added the screen shot and the text file of Call Stack to the attached file. QC Entry 74036

1. Start IDE. 2. [File]-[New]-[VCL Forms Application - Delphi] 3. Show a code editor. 4. [Project]-[QA Metrics] 5. Click the 'Start' button. 6. Close a Metrics dialog. 7. End IDE. The dialog of AV is displayed after the window of IDE disappears. [vk, 22.09.2009] See CommentOnly note [vk] Fixed in trunk - revision 24876, branch - rev.24882 [vk, 28.09.2009] 2nd fix. Fixed in trunk - rev.24902, branch - rev.24904

QC #: 74253 - Status: Closed

QC #: Project Date Reported: Area: 74253 Delphi 5/26/2009 IDE\Code Editor Description Steps:[QC Short Description] Inconvinience with indent QC Entry 74253

I found small problem with tab indent. Assume we have following text: (1)Begin (2) MyLine; (3)End; if I selected block from the beginning of line 2 to the beginning of MyLine (in other order all these spaces from the left of MyLine until beginning of the line) and then press Tab MyLine will be indented even more. I actually expecting it to replace selection with tab (or spaces) because selected only one line. Visual Studio works exactly the same way as I expected.

QC #: 74300 - Status: Closed

QC #: Project Date Reported: Area: 74300 Delphi 5/27/2009 Demos\Midas Description Steps:[QC Short Description] 'Catastrophic Failure' message when activate TClientDataset [QC Description] Application show error 'Catastrophic Failure' when user try to activate TClientDataSet in client application QC Entry 74300

Error appears during using demos 'EmpEdit' and 'Activefm' 1. Run Employee Data Server 2. Press button "Get Employees" then error appears. Error appears in design mode too.

QC #: 74373 - Status: Closed

QC #: Project Date Reported: Area: 74373 C++Builder 5/28/2009 Compiler\C++\Front End Description Steps:[c++0x] [rvalue] [QC Short Description] Valid rvalue reference code doesn't compile [QC Description] The code using rvalue reference produces compiler error. The code is a variation on Dinkumware rvalue ref-aware STL. QC Entry 74373

bcc32 -c 272372.cpp Expected - clean compilation Actual - compiler error [BCC32 Error] E2096 Illegal structure operation

QC #: 74472 - Status: Closed

QC #: Project Date Reported: Area: 74472 Delphi 6/1/2009 Documentation Description Steps:[QC Short Description] TMutex info missing [QC Description] Description: This is class SyncObjs.TMutex. QC Entry 74472

QC #: 74573 - Status: Closed

QC #: Project Date Reported: Area: 74573 Delphi 6/4/2009 Midas\TClientDataSet Description Steps:[QC Short Description] TClientDataSet filters still don't work with WideString fields [QC Description] The attached test case demonstrates additional failures when using WideString fields in a filter expression. This is a follow-up to QC 4790 which was marked as fixed for Delphi 2009 update 3 but is still not completely fixed. QC Entry 74573 Ref: 272886

TDBXWeaverBugsSuite.Native.Db.Test.exe connection=ibconnection -s:TestRaid_269928 -or- Run the attached program. - Press Test1 Expected: data should get filtered and only 1 record should be visible.Actual: Type mismatch in expression. - Press Test2 Expected: data should get filtered and 2 records should remain visible.Actual: sometimes "Type mismatch in expression". Other times "Access violation at address 4DB1E8D1 in module 'midas.dll'. Read of address 00FC00BF." - Press Test3 Expected: data should get filtered and 2 records should remain visible.Actual: no records are visible. Of course, all these worked with normal strings.

QC #: 74578 - Status: Closed

QC #: Project Date Reported: Area: 74578 Delphi 6/4/2009 RTL Description Steps:[QC Short Description] Implementation of comparers in Generics.Defaults [QC Description] It seems that the implementation of Compare methods for buildin typesis not effective. For example, consider: function Compare_I4(Inst: Pointer; const Left, Right: Integer): Integer;begin if Left < Right then Result := -1 else if Left > Right then Result := 1 else Result := 0; end; It may be replace by: function Compare_I4(Inst: Pointer; const Left, Right: Integer): Integer;begin Result := Left - Right; end; So two compares will be replaced by one substract. or function Compare_UString(Inst: PSimpleInstance; const Left, Right: UnicodeString): Integer; begin if Left < Right then Result := -1 else if Left > Right then Result := 1 else

Result := 0; end; by It may be replace by: function Compare_UString(Inst: PSimpleInstance; const Left, Right: UnicodeString): Integer; begin Result := StrComp(PChar(Left), PChar(Right)); end; So two string compares will be repaced by more effective call to StrComp QC Entry 74578

QC #: 74600 - Status: Closed

QC #: Project Date Reported: Area: 74600 C++Builder 6/4/2009 VCL Description Steps:[QC Short Description] Crash at exit if there is a GroupBox in the main form and a DLL built with VCL is used [QC Description] Using C++Builder2009 with all updates to update 4. Running on Windows XP Service Pack 3 (Spanishs): If a VCL application has a GroupBox and uses a DLL built with the VCL option checked, when the application closes an Access Violation exception is produced. Added by Sysop <<<<<<<<<<<<<<<<<< 'DELAY LOAD DLLs' is a CORRECT WAY to fix your issue. This issue occurs with Delphi application(.exe, .dlls), but Delphi does not support DELAY LOAD DLLs option. If you have a .exe and .dlls which depend on runtime packages of VCL(.BPLs), you have to use DELAY LOAD DLLs option. The reason is that, in you case, VCL resources have been initialized by the .DLL's startup code, because OS loads the .DLL file before .EXE. It must be initialzied by .EXE's startup code instead of .DLL's. One typical wrong result of this issue is ICON images of MainForm and Application which are not initialized correctly... So, if your .DLL does not need VCL features, please create the .DLL without VCL support. As a result, the .DLL does not initialize VCL resources. P.S. This initialization order problem exists in all of versions of Delphi/C++Builder. >>>>>>>>>>>>>>>>>> QC Entry 74600

Create a new project for a DLL with VCL option checked. Export a simple function, for example: int Suma(int a, int b) { return a+b; } built it as, for example, dllsuma.dll Now create a VCL application. Add dllsuma.lib to the prject. Put a GroupBox in the main form. In the FormCreate call the dll: int s; s=Suma(1,2); Build an run the application.

QC #: 74657 - Status: Closed

QC #: Project Date Reported: Area:74657 C++Builder 6/7/2009 Documentation

Description Steps:

[QC Short Description] Type of 'S' argument for TEncoding.GetByteCount is wrong [QC Description] In the documentation for TEncoding.GetByteCount the 'S' argument has an incorrect type of 'AnsiString' for the C++ code section. The type should really be 'const System::String" or " const System::UnicodeString" Link: ms-help://embarcadero.rs2009/delphivclwin32/SysUtils_TEncoding_GetByteCount@[email protected] Entry 74657

QC #: 74918 - Status: Closed

QC #: Project Date Reported: Area:74918 Delphi 6/16/2009 VCL\Standard Controls\TMemo

Description Steps:[QC Short Description] Can't pop up TMemo context menu using windows 7 touch [QC Description] see steps QC Entry 74918

- create a new VCL forms app - drop a TMemo on the form - run it on a windows 7 multitouch machine - try popping up the mem context menu using press-and-tap. you can't.

QC #: 74973 - Status: Closed

QC #: Project Date Reported: Area: 74973 Delphi 6/17/2009 Compiler\Delphi\Generics Description Steps:[QC Short Description] Inheritance constraints on generics : nil cannot be used as parameter value [QC Description] Nil cannot be passed as argument to a function or procedure that expects a generic value with an inheritance contraint. See code in steps to reproduce (note that the code will compile fine if the class declaration is changed to TToto <T : class>). QC Entry 74973

program BTS270229; {$APPTYPE CONSOLE} type TBase = CLASS(TObject); TToto <T : TBase> = class procedure Test(a : T); end; procedure TToto<T>.Test(a: T); begin if a <> nil then // Here we can compare a variable of type T with nil test(nil); // ... but there we get incompatible types : T and pointer ! end; begin WriteLn('PASS'); //PASS on compile// end.

QC #: 74988 - Status: Closed

QC #: Project Date Reported: Area:74988 Delphi 6/17/2009 Compiler\Delphi\Anonymous Methods

Description Steps:[QC Short Description] The "inline" directive causes invalid code to be generated

Compile and run the attached application below.

[QC Description] Consider the following... procedure Call(const Proc: TProc); inline; begin Proc(); end; procedure Demo; var s: string; begin s := 'hello'; Call(procedure begin ReadLn(s); end); Call(procedure begin Writeln(s); end); end; The presence of the "inline" directive on the Call procedure causes the Demo procedure to not work properly. Instead of calling the two anonymous methods, one after the other, Demo now calls only the second anonymous method -- twice! Removing the "inline" directive makes this problem go away. QC Entry 74988

See the following program output indicating failure. FAIL - Counter=22 This output suggests that the code generated for the line marked #2 executes twice and that no code is being generated for the line marked #1. program BTS270227; { The "inline" directive causes invalid code to be generated } {$APPTYPE CONSOLE} uses SysUtils; var Counter: Integer = 0; procedure AdvanceCounter(Value: Integer); begin Counter := Counter * 10 + Value; end; procedure Call(const Proc: TProc); inline; begin Proc(); end; procedure Demo; begin Call(procedure begin AdvanceCounter(1); end); //#1// Call(procedure begin AdvanceCounter(2); end); //#2// if Counter = 12 then WriteLn('PASS') else writeLn('FAIL - Counter=', Counter); end; begin Demo; end.

QC #: 75005 - Status: Closed

QC #: Project Date Reported: Area: 75005 Delphi 6/17/2009 Compiler\Delphi\Generics Description Steps:[QC Short Description] F2084 Internal Error: URW1135 with DeHL revision 224 [QC Description] Trying to compile DeHL revision 224 from http://delphilhlplib.googlecode.com/svn/trunk with DeHL.Types.DCC32_FIXED_BUG_INTERNAL_ERROR_URW1100= True does lead to a URW1135 error. -> see steps for simplified version from Uwe Schuster. (JJS: Note the circular unit reference between the units in the test case.) QC Entry 75005 [Tester Recommended] [Affect by NEW_ENGINE reversion]

Compile the attached application with the following command-line. (Note the build option) dcc32 -b BTS270254.dpr See the following compiler output indicating failure. Fatal: F2084 Internal Error: URW1100 (rev. 14.0.3453.22063) program BTS270254; { F2084 Internal Error: URW1135 with DeHL revision 224 } {$APPTYPE CONSOLE} uses uBTS270254a;

begin WriteLn('PASS'); end. unit uBTS270254a; interface type TType<T> = class abstract(TInterfacedObject) public class procedure Default; end; implementation uses uBTS270254b; type TInternalDictionary = TDictionary<Pointer, TClass>; class procedure TType<T>.Default; begin end; end. unit uBTS270254b; interface uses uBTS270254a; type TDictionary<TKey, TValue> = class(TObject) public constructor Create; end; type TBugReproducer = TDictionary<TClass, string>; implementation constructor TDictionary<TKey, TValue>.Create; begin TType<TKey>.Default; end; end.

QC #: 75027 - Status: Closed

QC #: Project Date Reported: Area:75027 Delphi 6/18/2009 IDE\Code Editor\Error Insight Description Steps:[QC Short Description] Method over an element of a generic collection showed as error [QC Description] When using a generic collection (TList<T> for exemple) that contain objects, calling a method on an element of this collection is reported has an error in the IDE but the compilation work fine. QC Entry 75027

var Report: TObjectDictionary < Integer, TStringList >; Report := TObjectDictionary < Integer, TStringList >.Create; Report.Add(0, TStringList.Create); Report[0].Add('Test'); In the last instuction, Add is red underligned in the IDE with the message 'TObjectDictionary '2' doesn't contain a member called Add' (I am traducing the message has I got it in french)

QC #: 75119 - Status: Closed

QC #: Project Date Reported: Area: 75119 Delphi 6/21/2009 Compiler\Delphi\Generics Description Steps:[QC Short Description] F2084 Internal Error: URW1135 with class helper with generic proc [QC Description] -> see steps Original short description: Using a generic class helper causes URW 1135 on first compile Original description: When trying to build a certain piece of code that calls a generic class helper for TStream, the compiler chokes on it the first time around and gives a URW1135 error. If I comment out the call, it will build successfully. If I then uncomment the call and compile, it compiles just fine. Attempting to reduce this to a simpler test case didn't yield a reproducible bug, so I'm going to have to use the real project as the test case. QC Entry 75119 [Tester Recommended] [Affected by NEW_ENGINE reversion]

Steps by USc (small test created from revision 42 of TURBU): - save the attached files - dcc32 -B default_format.dpk expected: it compiles actual: turbu_tilesets.pas(29) Fatal: F2084 Internal Error: URW1135 - dcc32 default_format.dpk expected: it compiles actual: Fatal: F2084 Internal Error: AV0044AEE7-RFFFF8003-0 Original steps: 1. Check out the TURBU project from http://turbu.googlecode.com/svn/trunk 2. Open \turbu\turbu.groupproj 3. Build EngineBasis.bpl 4. Try to build default_format.bpl 5. Observe the URW1135 error in turbu_tilesets.pas 6. Comment out lines 139, 141, 150 and 151, containing references to TStreamEx.ReadList<T> and TStreamEx.WriteList<T>. 7. Build again. It should build properly. 8. Uncomment the commented lines, and compile with CTRL-F9. It should compile correctly this time. 9. Attempt a new full build. It won't build now until you repeat step 6.

QC #: 75180 - Status: Closed

QC #: Project Date Reported: Area:75180 Delphi 6/23/2009 VCL\Win 32 Controls\TListView

Description Steps:[QC Short Description] TCustomListView.RecreateWnd causes too many unnecessary events (i.e. OnDeletion, OnInsert, etc...) [QC Description] - Outline - TCustomListView.RecreateWnd causes too many unnecessary events. (i.e. OnDeletion, OnInsert, etc...) When RecreateWnd is called, Items on TCustomListView are all deleted and inserted again. But, Delete method, InsertItem method and etc always call the event which is related with the method. So, this problem is caused. - Problems - * If Item has custom data on Data property, you will free its memory on OnDeletion event: If RecreateWnd calls OnDeletion, it will delete the data that should not be deleted. * Users cannot detect that RecreateWnd is called: RecreateWnd is called by too many methods. So it is too difficult for them to write the code with considering RecreateWnd. * Too many events will be called: So users cannot judge what event is called properly or not. - Right behavior -

1. Create a new VCL Form Application. 2. Drop a TListView and a TButton onto Form. 3. Turn Checkboxes on TListView to True. 4. Write following code on TButton.OnClick. -Code- procedure TForm1.Button1Click(Sender: TObject); var NewItem: TListItem; begin NewItem := ListView1.Items.Add; NewItem.Caption := 'hogehoge'; NewItem.Checked := True; NewItem.Selected := True; NewItem.ImageIndex := 0; if ListView1.ViewStyle = vsReport then begin ListView1.ViewStyle := vsIcon; end else begin ListView1.ViewStyle := vsReport; end; end; 5. Write following code on TListView.OnDeletion. procedure TForm1.ListView1Deletion(Sender: TObject; Item: TListItem); begin ShowMessage('OnDeletion'); end; 6. Run and click the button. exp: The message dialog does not appear. act: The message dialog appears. In this case, following events will be called. But they are all unnecessary. OnDeletion OnChanging OnChange OnSelectItem OnCreateItemClass OnItemChecked OnInsert

If ControlState includes csRecreating, TCustomListView does not call these events. See Steps, Workaround and Attachments QC Entry 75180

QC #: 75195 - Status: Closed

QC #: Project Date Reported: Area:75195 Delphi 6/23/2009 Documentation\Online Help\VCL

Description Steps:[QC Short Description] [Online Help] There are no topic about csRecreating/csPanning [QC Description] There are no topic about csRecreating/csPanning. ms-help://embarcadero.rs2009/delphivclwin32/Controls_TControl_ControlState.html However, the topic exists in the following. ms-help://embarcadero.rs2009/delphivclwin32/Controls_TControlState.html There is information only in one on the page. QC Entry 75195

EXP: content is the same as ms-help://embarcadero.rs2009/delphivclwin32/Controls_TControl_ControlState.html and ms-help://embarcadero.rs2009/delphivclwin32/Controls_TControlState.html ACT: As for ms-help://embarcadero.rs2009/delphivclwin32/Controls_TControl_ControlState.html and ms-help://embarcadero.rs2009/delphivclwin32/Controls_TControlState.html, the content is different.

QC #: 75208 - Status: Closed

QC #: Project Date Reported: Area: 75208 Delphi 6/24/2009 Debugger\CPU Description Steps:[QC Short Description] Memory operand size displayed incorrectly for PMOVZX.. instructions [QC Description] In CPU view, the PMOVZX.. instructions are incorrectly displayed as having DQWORD sized memory operands. Compare the disassembly with the specifications found in: Intel® 64 and IA-32 Architectures Software Developer’s Manual, Volume 2B: Instruction Set Reference, N-Z QC Entry 75208

Look at the disassembly for the following code: procedure PMOVZXDebuggerBugs; var i64:uint64; i16:uint16; i32:uint32; asm //PMOVZX jmp @x //DISASSEMLY SHOWS "DQWORD PTR" FOR ALL OF THESE!! pmovzxbw xmm0, i64 //Is QWORD pmovzxbd xmm0, i32 //Is DWORD pmovzxwd xmm1, i64 //Is QWORD pmovzxbq xmm2, i16 //Is WORD pmovzxwq xmm0, i32 //Is DWORD pmovzxdq xmm1, i64 //Is QWORD @x: end;

QC #: 75209 - Status: Closed

QC #: Project Date Reported: Area: 75209 Delphi 6/24/2009 Debugger\CPU Description Steps:[QC Short Description] Memory operand size displayed incorrectly for PMOVSX... instructions [QC Description] In CPU view, the PMOVSX.. instructions are incorrectly displayed as

Inspect the disassembly for the following code: procedure PMOVSXDebuggerBugs; var i64:uint64; i16:uint16; i32:uint32; asm //PMOVSX jmp @x //Disassembly shows "DQWORD PTR" pmovsxBW xmm2, i64 //is QWORD pmovsxBD xmm2, i32 //is DWORD pmovsxBQ xmm2, i16 //is WORD pmovsxWD xmm2, i64 //is QWORD pmovsxWQ xmm2, i32 //is DWORD pmovsxDQ xmm2,

having DQWORD sized memory operands. Compare the disassembly with the specifications found in: Intel® 64 and IA-32 Architectures Software Developer’s Manual, Volume 2B: Instruction Set Reference, N-Z QC Entry 75209

i64 //is QORD @x: end;

QC #: 75211 - Status: Closed

QC #: Project Date Reported: Area: 75211 Delphi 6/24/2009 Debugger\CPU Description Steps:[QC Short Description] Wrong size shown for INSERTPS memory operand [QC Description] In disassembly, INSERTPS is displayed as having a DQWORD sized memory operand, although it actually is a DWORD. Reference: Intel® 64 and IA-32 Architectures Software Developer’s Manual; Volume 2A: Instruction Set Reference, A-M QC Entry 75211

Inspect the disassembly for the following code: procedure INSERTPSDebuggerBug; var i32:longword; asm jmp @x //Disassembly shows "DQWORD PTR" insertps xmm0, i32, 7 //actually is DWORD @x: end;

QC #: 75218 - Status: Closed

QC #: Project Date Reported: Area:75218 Delphi 6/24/2009 Compiler\Delphi\Anonymous Methods

Description Steps:[QC Short Description] Codegen problem with nested procedure of anonymous method capturing variables from outer scope [QC Description] Just as the anonymous method itself, a nested procedure of an anonymous method can access the variables of the outer scope. However, the compiler generates bad code when a nested procedure references variables from the outer scope: the ActRec reference is not passed to nested procedures, which would be necessary to have them access the outer scope. QC Entry 75218 [Tester Recommended]

Compile and run the following code (dcc32 qc75218.pas): Exp.: prints PASS Act.: prints FAIL // ----- program qc75218; {$APPTYPE CONSOLE} uses SysUtils; procedure CallProc (Proc: TProc); begin Proc; end; procedure TestNestedAnonProc; var Foo: Cardinal; begin try Foo := $DEADBEEF; CallProc (procedure procedure NestedProcedure; begin Assert (Foo = $DEADBEEF); end; begin NestedProcedure; end); Writeln ('PASS'); except on EAssertionFailed do

Writeln ('FAIL'); end; end; begin TestNestedAnonProc; end. // ----- Exp.: prints PASS Act.: prints FAIL

QC #: 75227 - Status: Closed

QC #: Project Date Reported: Area:75227 C++Builder 6/24/2009 Compiler\Delphi\Header Generation

Description Steps:[QC Short Description] DCC should emit an empty default constructor for records [QC Description] If a constructor with arguments exists, a C++ doesn't implicitly generate a default constructor. Other than Delphi, C++ does not differentiate between classes and records (struct), thus the same rule applies to records. Because of this, DCC should emit an empty default constructor - which BCC would generate anyway - to records if these records have non-default constructors. I.e., this code // ----- type TMyRecord = record constructor Create (Foo: Integer); end; // ----- is represented by this code in the header file: // ----- struct TMyRecord { public: __fastcall TMyRecord(int Foo); }; // ----- Much better would be: // ----- struct TMyRecord { public: __fastcall TMyRecord(void) {} // <-- __fastcall TMyRecord(int Foo); }; // ----- The attached test case demonstrates how the current behavior can cause broken headers. QC Entry 75227 [Tester Recommended]

Generate a header for this unit (dcc32 -JPHN qc75227.pas): // ----- unit qc75227; interface type TMyRecord = record constructor Create (Foo: Integer); end; TMyClass = class FRecord: TMyRecord; end; implementation constructor TMyRecord.Create (Foo: Integer); begin end; end. // ----- - Compile the header with BCC (bcc32 -P -c qc75227.hpp) Exp.: compiles Act.: Error E2279 qc75227.hpp 39: Cannot find default constructor to initialize member 'TMyClass::FRecord' in function _fastcall TMyClass::TMyClass()

QC #: 75262 - Status: Closed

QC #: Project Date Reported: Area: 75262 Delphi 6/25/2009 Compiler\Delphi\Generics Description Steps:

[QC Short Description] Finalize(generic array) causes Internal Errors [QC Description] An attempt to finalise a variable of generic dynamic array type using standard Finalize procedure results in ICE. An attempt to finalise a variable of generic static array type using standard Finalize procedure results in ICE. QC Entry 75262 (JJS: RAID 271100 records another test case reporting the similar internal error)

Compile the attached application below. See the following compile-time error indicating failure. Fatal: F2084 Internal Error: C21490 If you comment out the line marked #1 and recompile, you will see the following internal from the presence of the line #2. Fatal: F2084 Internal Error: T2671 program BTS270464; {$APPTYPE CONSOLE} uses SysUtils; var Counter: Integer = 0; type vector<T> = array of T; procedure foo; var a: vector<integer>; begin SetLength(a, 5); Finalize(a); //#1// SetLength(a, 7); Inc(Counter); end; type tuple<T> = array[0..5] of T; procedure bar; var a: tuple<string>; begin a[3] := 'Hello'; finalize(a); //#2// a[3] := 'World'; Inc(Counter); end; procedure DoTest; begin foo; bar; end; begin try DoTest; if Counter = 2 then WriteLn('PASS') else WriteLn('FAIL - Counter=', Counter); except on E: Exception do begin WriteLn('FAIL - Exception Error'); WriteLn(' ClassName=', E.ClassName); WriteLn(' Message=', E.Message); end; end; end.

QC #: 75294 - Status: Closed

QC #: Project Date Reported: Area: 75294 Delphi 6/26/2009 IDE\Class Completion Description Steps:[QC Short Description] Class completion cannot handle generic methods with multiple type parameters [QC Description] See steps. QC Entry 75294

- Create a new Delphi console application. - Insert this source code: // ----- program qc75293; type TFoo = class procedure Bar<T1, T2>; end; begin end. // ----- - Invoke Class Completion for TFoo. Exp.: // ----- procedure TFoo.Bar<T1, T2>; begin end; // ----- Act.: // ----- procedure TFoo.Bar<T1>; // <-- note the missing ', T2'. begin end; // -----

QC #: 75314 - Status: Closed

QC #: Project Date Reported: Area:75314 Delphi 6/26/2009 IDE\Code Editor\Error Insight Description Steps:[QC Short Description] "Invalid real constant" with constants larger than MaxDouble (1.7976931348623158e+308) [QC Description] The constant MaxExtended = 1.1e+4932; in ...\RAD Studio\6.0\source\Win32\rtl\common\Math.pas leads to a "Invalid real constant" error in the Structure view. -> see steps QC Entry 75314

- save the following code at the end of the steps as RealConstantErrorInsightTest.dpr - start Delphi - open RealConstantErrorInsightTest.dpr - compile (it should compile) expected: no Error Insight errors in the Structure view actual: Invalid real constant at line 7 (7:44) Invalid real constant at line 9 (9:17) - open ...\RAD Studio\6.0\source\Win32\rtl\common\Math.pas expected: no Error Insight errors in the Structure view actual: Invalid real constant at line 69 (69:18) program RealConstantErrorInsightTest; {$APPTYPE CONSOLE} const MaxDouble_Long = 1.7976931348623158e+308; MaxDouble_Long_Plus_0_dot_000something = 1.7976931348623159e+308; //from Math.pas MaxExtended = 1.1e+4932; begin end.

QC #: 75315 - Status: Closed

QC #: Project Date Reported: Area:75315 Delphi 6/26/2009 IDE\Code Editor\Error Insight Description Steps:[QC Short Description] "Identifier redeclared" with .NET attributes [QC Description] ...\RAD Studio\6.0\source\Win32\vcl\Clipbrd.pas has a .NET attribute for a class with a name in it which is equal to a symbol and that leads to "Identifier redeclared" errors in the Structure view. -> see steps QC Entry 75315

- save the following code at the end of the steps as DotNETAttributeErrorInsightTestUnit.pas - start Delphi - create a new console application and add DotNETAttributeErrorInsightTestUnit.pas - compile (it should compile) expected: no Error Insight errors in the Structure view actual: Identifier redeclared 'Clipboard' at line 10 (10:10) Identifier redeclared 'Clipboard' at line 15 (15:10) - open ...\RAD Studio\6.0\source\Win32\vcl\Clipbrd.pas expected: no Error Insight errors in the Structure view actual: Identifier redeclared 'Clipboard' at line 117 (117:10) Identifier redeclared 'Clipboard' at line 564 (564:10) Additional note: When you rename "Clipboard" in "...Clipboard=UIPermissionClipboard..." then the error disappears. unit DotNETAttributeErrorInsightTestUnit; interface type [UIPermission(SecurityAction.LinkDemand, Clipboard=UIPermissionClipboard.AllClipboard)] TClipboard = class(TObject) end; function Clipboard: TClipboard; implementation [UIPermission(SecurityAction.LinkDemand, Clipboard=UIPermissionClipboard.AllClipboard)] function Clipboard: TClipboard; begin Result := nil; end; end.

QC #: 75341 - Status: Closed

QC #: Project Date Reported: Area:75341 Delphi 6/28/2009 IDE\Code Editor\Error Insight Description Steps:[QC Short Description] Error Insight does not use .inc files from the library path [QC Description] Error Insight does not find .inc files that are in another directory although that directory is in the library path. That is maybe be a big issue with all 3rd party libraries which are separated into multiple directories! -> see steps QC Entry 75341

1. save the attached files into a new directory (this test does use c:\tmp\IncFileTest\ and that means you should have the following two files c:\tmp\IncFileTest\IncFileErrorInsightTest.dpr c:\tmp\IncFileTest\inc\jedi_error_insight.inc) 2. start Delphi 3. open IncFileErrorInsightTest.dpr expected: Error Insight error "Undeclared identifier 'GetBar' at line 17 (17:32)" actual: as expected 4. go to 8. if you won't see that it works with the path in the project options 5. add the .inc file path into the search path in the project options (means adding "c:\tmp\IncFileTest\inc\") expected: no Error Insight errors actual: as expected 6. remove the .inc file path from the search path in the project options (means removing "c:\tmp\IncFileTest\inc\") 7. make a change in the project source and revert it to trigger Error Insight expected: the Error Insight error with GetBar is back actual: as expected 8. enter the .inc file path into the library path in the IDE options (means adding "c:\tmp\IncFileTest\inc\") expected: no Error Insight errors actual: Error Insight error "Undeclared identifier 'GetBar' at line 17 (17:32)" 9. add the .inc file path into the search path in the project options (means adding "c:\tmp\IncFileTest\inc\"; it has to be exactly the same string as in the library path) expected: no Error Insight errors actual: Error Insight error "Undeclared identifier 'GetBar' at line 17 (17:32)" (note the path wasn't added to the project options) 10. replace the .inc file path in the search path in the project options with a string different from the project options (means adding "c:\tmp\IncFileTest\inc\" [=wo trailing \] or adding "inc") (note this time the path is kept) expected: no Error Insight errors actual: as expected //--- inc\jedi_error_insight.inc --- {$DEFINE COMPILER6_UP} //--- IncFileErrorInsightTest.dpr --- program IncFileErrorInsightTest; {$APPTYPE CONSOLE} {$I jedi_error_insight.inc} type TFoo = class(TObject) {$IFDEF COMPILER5} private function GetBar: Boolean; {$ENDIF COMPILER5} public {$IFDEF COMPILER6_UP} // {$ELSE ~COMPILER6_UP} property Bar: Boolean read GetBar; {$ENDIF ~COMPILER6_UP} end; {$IFDEF COMPILER5} function TFoo.GetBar: Boolean; begin Result := False; end; {$ENDIF COMPILER5} begin end.

QC #: 75390 - Status: Closed

QC #: Project Date Reported: Area: 75390 Delphi 6/30/2009 Documentation Description Steps:[QC Short Description] Description about WinHelp Viewer is not correct. [QC Description] Description about WinHelp Viewer is not correct. And, do not translate this part. QC Entry 75390

1.Open readme.htm WinHelp: The legacy WinHelp viewer (WinHelp.exe) is not implicitly registered by RAD Studio. If you want to use .HLP files from an application, you need to add the *WinHelp viewer* to the uses list of any unit included in the application. EXP: WinHelpViewer ACT: [EN] WinHelp Viewer [DE] WinHelp-Viewer [FR] l'afficheur WinHelp [JA] WinHelp byu-a (Japanese Roman)

QC #: 75431 - Status: Closed

QC #: Project Date Reported: Area:75431 C++Builder 7/1/2009 MTS\Wizards\MTS Data Module

Description Steps:

[QC Short Description] Property Pooled not found in transactional datamodules [QC Description] When creating a new transactional Datamodule, the wizard now adds a property called "Pooled" into the DFM file. This property doesn't seem to be implemented completely since the IDE complains that it is missing when the datamodule unit is closed and reopened. QC Entry 75431

* Create a new ActiveX Library * Create a new Transactional DataModule * Save everything and Close All * Reopen the Project and then the Transactional DataModule, and an error similar to this shows: "Error reading MyTrDMod.Pooled... Property Pooled does not exist"

QC #: 75435 - Status: Closed

QC #: Project Date Reported: Area: 75435 Delphi 7/1/2009 Compiler\Delphi\Generics Description Steps:[QC Short Description] Compiler doesn't treat generics with class constraints as class types [QC Description] When using a generic type with a class constraint, the compiler doesn't seem to understand that it's a class reference. QC Entry 75435

Compile the attached application below. See the following unexpected compile-time errors. bts270644.dpr(24) Error: E2010 Incompatible types: 'TOut' and 'TIn' bts270644.dpr(25) Error: E2010 Incompatible types: 'TOut' and 'TIn' (JJS: Interestingly, if either or both of the constraints on line #1 are changed to TBaseClass, the test code compiles as expected.) program BTS270644; { Compiler doesn't treat generics with class constraints as class types } {$APPTYPE CONSOLE} type TBaseClass = class end; type TTest<TIn: TBaseClass; TOut: class> = class //#1// public function repro(a: TIn): TOut; end; { TTest<TIn, TOut> } function TTest<TIn, TOut>.repro(a: TIn): TOut; begin if a is TOut then //Operator not applicable to this operand type result := a as TOut; //Operator not applicable to this operand type tout.className; end; begin WriteLn('PASS'); { PASS on compile } end.

QC #: 75496 - Status: Closed

QC #: Project Date Reported: Area: 75496 C++Builder 7/2/2009 Compiler\C++\Back End Description Steps:[QC Short Description] DirectShow base class wxUtil.cpp Release compiler (F1001 Internal

bcc32.exe -c -w- -O2 -P wxutil.i

code generator erro) [QC Description] The DirectShow BaseClass file wxUtil.cpp compile at Release will generate F1001 QC Entry 75496 Note: Requires -O2 and is a regression against 6.11

exp: clean compile act: Internal backend error C1744 compiling wxutil.i(1398) *** 1 errors in Compile ***

QC #: 75565 - Status: Closed

QC #: Project Date Reported: Area:75565 Delphi 7/6/2009 IDE\Code Editor\Error Insight Description Steps:[QC Short Description] False positive errors with empty single line comments and Unix line breaks [QC Description] ...\RAD Studio\7.0\source\Indy\Indy10\Protocols\IdSMTPBase.pas has false positive errors in the Structure view caused by empty single line comments and Unix line breaks (only $0A). In Tiburon the Indy files have PC line breaks ($0D $0A) and there the error doesn't show up. The line breaks may have something to do with SVN client changes or changes in the SVN properties of the repositories. The same issue occur's in VirtualTrees.pas (http://virtual-treeview.googlecode.com/svn/trunk/ revision 208 checked out with Tortoise SVN 1.6.2 and also with Unix line breaks), because the included Compilers.inc has empty single line comments too. Compilers.inc does look like this: //-----... // Include file to determine... // //-----... -> see steps QC Entry 75565

- start Weaver - open IdSMTPBase.pas from the attachment expected: no Error Insight errors in the Structure view actual: Expected ; but received / at line 7 (7:6) - open ...\RAD Studio\7.0\source\Indy\Indy10\Protocols\IdSMTPBase.pas (in TP tree: $(TP)\indysockets\lib\protocols\IdSMTPBase.pas) expected: no Error Insight errors in the Structure view actual: Expected END but received / at line 136 (136:6) Expected IMPLEMENTATION but received / at line 154 (154:6) Expected INITIALIZATION but received an identifier 'public' at line 156 (156:3) Expected the end of file but received an identifier 'GetReplyClass' at line 183 (183:22)

QC #: 75659 - Status: Closed

QC #: Project Date Reported: Area: 75659 C++Builder 7/10/2009 Database\DBExpress Description Steps:[QC Short Description] tinyint field type not supported in Sybase dbexpress interface [QC Description] If in a Sybase 12.5 database stored procedure a parameter has the type 'tinyint' then the dbexpress interface does not recognize this type and generates the error message: dbExpress driver does not support the TDBXTypes.UNKNOWN data type. Vendor error message:. The types 'int' and 'smallint' are supported, the type 'tinyint' not. The former dbexpress interface of BDS2006 was working well, the new one of C++Builder 2009 does not work. Example:

Create a stored procedure in a Sybase database like create procedure TEST @PARAM1 int, @PARAM2 smallint, @PARAM3 tinyint as begin ...... end put a TSQLConnection and a TSQLStoredProc into a form, connect to the database and select the stored procedure that contains the tinyint parameter and set Active to true.

create procedure TEST @PARAM1 int, @PARAM2 smallint, @PARAM3 tinyint as begin ...... end QC Entry 75659

QC #: 75670 - Status: Closed

QC #: Project Date Reported: Area: 75670 C++Builder 7/10/2009 Documentation Description Steps:[QC Short Description] Wrong C++ prototype of SysErrorMessage in Help [QC Description] In SysUtils.hpp we can see: extern PACKAGE System::UnicodeString __fastcall SysErrorMessage(unsigned ErrorCode); But Help (Up2) says: SysUtils.SysErrorMessage Function ... Pascal function SysErrorMessage(ErrorCode: Cardinal): string; C++ AnsiString SysErrorMessage(unsigned ErrorCode); Issues: - return value is wrong; - call convention (__fastcall) is not documented. The same problem for Pascal function Format(const Format: string; const Args: array of const): string; overload; function Format(const Format: string; const Args: array of const; const FormatSettings: TFormatSettings): string; overload; C++ AnsiString Format(const AnsiString Format, const array of const Args); AnsiString Format(const AnsiString Format, const array of const Args, const TFormatSettings FormatSettings); Actual prototypes are: extern PACKAGE System::UnicodeString __fastcall Format(const System::UnicodeString Format, System::TVarRec const *Args, const int Args_Size)/* overload */; extern PACKAGE System::UnicodeString __fastcall Format(const System::UnicodeString Format, System::TVarRec const *Args, const int Args_Size, const TFormatSettings &FormatSettings)/* overload */; QC Entry 75670

On search page enter "AnsiString" and press "Search" and in list (500 entries) you can easily find a bunch of incorrectly Ansi<->Unicode documented functions: AnsiString ExtractFilePath(const AnsiString FileName); struct TFormatSettings { Byte CurrencyFormat; Byte NegCurrFormat; Char ThousandSeparator; Char DecimalSeparator; Byte CurrencyDecimals; Char DateSeparator; Char TimeSeparator; Char ListSeparator; AnsiString CurrencyString; AnsiString ShortDateFormat; AnsiString LongDateFormat; AnsiString TimeAMString; AnsiString TimePMString; AnsiString ShortTimeFormat; AnsiString LongTimeFormat; array[1..12] of string ShortMonthNames; array[1..12] of string LongMonthNames; array[1..7] of string ShortDayNames; array[1..7] of string LongDayNames; Word TwoDigitYearCenturyWindow; }; C++ RegisterPropertyInCategory(const AnsiString CategoryName, const AnsiString PropertyName); RegisterPropertyInCategory(const AnsiString CategoryName, TClass ComponentClass, const AnsiString PropertyName); RegisterPropertyInCategory(const AnsiString CategoryName, PTypeInfo PropertyType, const AnsiString PropertyName); RegisterPropertyInCategory(const AnsiString CategoryName, PTypeInfo PropertyType); ..... It's easy to find and correct them all, isn't it? Just do it.

QC #: 75693 - Status: Closed

QC #: Project Date Reported: Area:75693 C++Builder 7/12/2009 Compiler\C++\Front End\Templates

Description Steps:[QC Short Description] Internal Compiler Error when using a template with boost::variant [QC Description] When compiling the attached project the compiler produces an ICE and stops compiling. Please don't mind that the code doesn't make any sense in this state. It did before reducing it :) QC Entry 75693

bcc32 -c -P -w- -j2 271247.i res: Fatal F1004 271247.i 1923: Internal compiler error at 0x44aea8 with base 0x400000 in function main(int,char * *) Fatal F1004 271247.i 1923: Internal compiler error in function main(int,char * *)

QC #: 75749 - Status: Closed

QC #: Project Date Reported: Area:75749 Delphi 7/14/2009 VCL\Standard Controls\TEdit Description Steps:[QC Short Description] When changing colour of edit box at run time, colours are not redrawn until mouse over [QC Description] When changing the colour of an edit box (say from clWindow to clRed), the 'border' of the colour is not redrawn unless the mouse is moved into the edit box. Changing the colour back from clRed to clWindow shows the outline as red, until moused over, where it is redrawn. This only happens when running in themed mode, and did not happen with Delphi 2007. QC Entry 75749

Create a form with 1 editbox and 2 buttons, then attach the following handlers. procedure TForm3.Button1Click(Sender: TObject); begin Edit1.Color := clRed; end; procedure TForm3.Button2Click(Sender: TObject); begin Edit1.Color := clWindow; end;

QC #: 75799 - Status: Closed

QC #: Project Date Reported: Area: 75799 Delphi 7/15/2009 Compiler\Delphi\Generics Description Steps:[QC Short Description] Initialize() or Finalize() for the type parameter causes Internal Error C21494 when the type argument is a generic [QC Description] See Steps. An attempt to instantiate the generic List using a generic type as the type argument results in ICE: the compiler cannot handle the call to Initialize() or Finalize() intrinsic procedures. This is crucial for generic [container] classes that manage their own memory. QC Entry 75799 (JJS: RAID 270464 records a test case reporting the same internal error.)

Compile the attached application below. See the following unexpected compile-time error indicating failure. Fatal: F2084 Internal Error: C21490 program BTS271100; { Initialize() or Finalize() for the type parameter causes ICE C21494 when the type argument is a generic } {$APPTYPE CONSOLE} type List<T> = class procedure Bar; end; Container<T> = class end; procedure List<T>.Bar; var p: ^T; z: pointer;

begin // p := uninitialised memory initialize( p^ ); // Fatal: F2084 Internal Error: C21494 finalize( T( z^ )); // Fatal: F2084 Internal Error: C21494 end; var A: List< List<integer> >; B: List< Container<record a: string end> >; begin WriteLn('PASS'); //PASS on compile// end.

QC #: 75822 - Status: Closed

QC #: Project Date Reported: Area: 75822 Delphi 7/15/2009 IDE\Code Editor\Error Insight

Description Steps:[QC Short Description] "Parameter '...' redeclared" with variables with the same identifier as a type parameter [QC Description] Variables with the same identifier as a type parameter do produce Error Insight errors. This error was extracted from the original report. The other issues are either follow up errors or are already reported (RAID 239029, QC 70644/RAID 267704) -> see steps -> see "[3478] - Error Insight" in .weaver.ide.general https://forums.codegear.com/thread.jspa?messageID=136440&tstart=0#136440Message-ID: <[email protected]> Original short description: Error Insight Problems with attached code. Original description: In the attached code several Error Insight Error Messages are visible. Specifically in six.dpr However, the code compiles file. First set of errors: Parameter 't' redeclared at line 113 Parameter 't' redeclared at line 120 Parameter 't' redeclared at line 155 Identifier redeclared 'T' at line 171 The cause is that a procedure has 3 nested procedures each with a nested paramter of 't' Related and the nest (sidenote: the case of the code and name don't match in last error) Second set of Errors: Undeclared indentifier 'GetMethod' at line 159 Undeclared indentifier 'GetProperty' at line 161 Undeclared indentifier GetField' at line 163 There are several more error insight errors I have attached a image of the errors.

Steps by USc: - save the following code at the end of the steps - start Weaver - open the project - compile (it should compile) expected: no Error Insight errors in the Structure view actual: Parameter 'b' redeclared at line 19 (19:17) program six; {$APPTYPE CONSOLE} type TListHelper<A> = class public function ToArray<B>: Boolean; end; function TListHelper<A>.ToArray<B>: Boolean; begin end; procedure Test1(A: Integer); begin end; procedure Test2(b: Integer); begin end; begin end. Original steps: 1. Open the attached project group. 2. Open six.dpr 3. View Error Insight messages

QC Entry 75822

QC #: 75885 - Status: Closed

QC #: Project Date Reported: Area: 75885 Delphi 7/17/2009 Compiler\Delphi\Language Description Steps:[QC Short Description] The compiler allows modification of read-only class property backed by a field [QC Description] See Steps. QC Entry 75885

Compile the attached application below. See that it compile successfully even though assignment errors are expected for lines marked #1 and #2 in the source code. program BTS271228; { The compiler allows modification of read-only class property backed by a field } {$APPTYPE CONSOLE} uses Types; type C = class strict private class var FP: TPoint; public class property P: TPoint read FP {write FP}; end; begin C.P.x := 1; //#1// writeln(C.P.x); with C.P do x := 5; //#2// writeln(C.P.x); WriteLn('FAIL - Compile-time errors expected'); end. {##COMERR.English: BTS271228.dpr(19) Error: E2129 Cannot assign to a read-only property} {##COMERR.English: BTS271228.dpr(21) Error: E2129 Cannot assign to a read-only property}

QC #: 75907 - Status: Closed

QC #: Project Date Reported: Area: 75907 Delphi 7/18/2009 Compiler\Delphi\Generics Description Steps:[QC Short Description] Singeletons containing generic containers as properties give bogus "compiled with different version" errors on recompile. [QC Description] Yet another bug I found while working on the TURBU editor. I've got a global singleton that holds a bunch of project data, called GDatabase. It uses several generic TLists and TDictionaries. Everything builds just fine, but when I change anything and try to recompile (not rebuild,) it says: [DCC Fatal Error] turbu_database.pas(1283): F2051 Unit turbu_tilesets was compiled with a different version of turbu_database.GDatabase

Steps by USc (small test created from revision 49 of TURBU): - save the attached files - dcc32 -B -UMiniGenericCollections turbu_database.pas expected: it compiles actual: it compiles - dcc32 -M -UMiniGenericCollections turbu_database.pas expected: it compiles actual: turbu_database.pas(28) Fatal: F2051 Unit turbu_tilesets was compiled with a different version of turbu_database.GDatabase Since the minimized version of Generics.Collections.pas does only contain one case for the error an additional test with the original version is necessary: - dcc32 -B turbu_database.pas expected: it compiles actual: it compiles - dcc32 -M turbu_database.pas expected: it compiles actual: turbu_database.pas(27) Fatal: F2051 Unit turbu_tilesets was compiled with a different version of turbu_database.GDatabase Original steps: 1. Check out the TURBU project from http://turbu.googlecode.com/svn/trunk 2. Open \turbu\turbu.groupproj 3. Open Testing.exe and run a full build. 4. Make a trivial change in

QC Entry 75907 [Affected by the NEW_ENGINE reversion]

turbu_database.pas, press SPACE, for example, and recompile. 5. Error occurs here.

QC #: 75913 - Status: Closed

QC #: Project Date Reported: Area: 75913 Delphi 7/19/2009 Resourcing Description Steps:[QC Short Description] cgrc.exe cannot handle output file names with spaces [QC Description] The cgrc.exe resource compiler which invokes Microsoft's rc.exe does not handle spaces in the -fo command line option. c:\codegear\rad studio\7.0\bin\cgrc.exe -dDEBUG -i"c:\codegear\rad studio\7.0\lib";"C:\Dokumente und Einstellungen\Andreas\Eigene Dateien\RAD Studio\7.0\Imports";"c:\codegear\rad studio\7.0\Imports";"c:\codegear\rad studio\7.0\Lib\Indy10";"C:\Dokumente und Einstellungen\All Users\Dokumente\RAD Studio\7.0\Dcp";"c:\codegear\rad studio\7.0\include" "My Test.rc" -fo"My Test.res" [BRCC32 Fehler] My Test.rc(1): invalid usage; use RC /? for Help This is what ProcessMonitor shows: You can clearly see the missing quotes for the >/fo My Test.res< option. "c:\codegear\rad studio\7.0\bin\rc.exe" /dDEBUG=1 /fo My Test.res /i "c:\codegear\rad studio\7.0\lib";"C:\Dokumente und Einstellungen\Andreas\Eigene Dateien\RAD Studio\7.0\Imports";"c:\codegear\rad studio\7.0\Imports";"c:\codegear\rad studio\7.0\Lib\Indy10";"C:\Dokumente und Einstellungen\All Users\Dokumente\RAD Studio\7.0\Dcp";"c:\codegear\rad studio\7.0\include" "C:\Dokumente und Einstellungen\Andreas\Eigene Dateien\RAD Studio\Projekte\cgrcBug\tmp6.tmp" Looks like somebody forgot to send the -fo option with quotes to the rc.exe. This bug also affects Delphi/C++Builder 2009 QC Entry 75913

1. Open the attached project 2. Verify that the resource compiler is set to "Windows SDK Resource compiler" in the project options dialog 3. Build the project Expected: The project compiles Actual: cgrc.exe fails with [BRCC32 Fehler] My Test.rc(1): invalid usage; use RC /? for Help

QC #: 75918 - Status: Closed

QC #: Project Date Reported: Area:75918 Delphi 7/19/2009 IDE\Code Editor\Error Insight Description Steps:[QC Short Description] "Identifier redeclared" when using forwarded type [QC Description] ...\RAD Studio\6.0\source\database\DSReflect.pas does use the type TDSAdapterClass in a type definition before it is defined and that leads to an "Identifier redeclared" error in the Structure view. -> see steps

- save the following three files or save the attachment - start Delphi - open ForwardTypeDefErrorInsightTest.dpr - open DSReflectMini.pas with CTRL+Enter expected: no Error Insight errors in the Structure view actual: Identifier redeclared 'TDSAdapterClass' at line 7 (7:3) - open ForwardTypeDefErrorInsightTestWithIn.dpr - open DSReflectMini.pas with CTRL+Enter expected: no Error Insight errors in the Structure view actual: Undeclared identifier 'TDSAdapterClass' at line 6 (6:33) Identifier redeclared 'TDSAdapterClass' at line 7 (7:3) - open ...\RAD

QC Entry 75918 Studio\6.0\source\database\DSReflect.pas expected: no Error Insight errors in the Structure view actual: Identifier redeclared 'TDSAdapterClass' at line 20 (20:3) //--- ForwardTypeDefErrorInsightTest.dpr --- program ForwardTypeDefErrorInsightTest; {$APPTYPE CONSOLE} uses DSReflectMini; begin end. //--- ForwardTypeDefErrorInsightTestWithIn.dpr --- program ForwardTypeDefErrorInsightTestWithIn; {$APPTYPE CONSOLE} uses DSReflectMini in 'DSReflectMini.pas'; begin end. //--- DSReflectMini.pas --- unit DSReflectMini; interface type TDSAdapterClassType = type of TDSAdapterClass; TDSAdapterClass = class(TObject); implementation end.

QC #: 75920 - Status: Closed

QC #: Project Date Reported: Area:75920 Delphi 7/19/2009 IDE\Code Editor\Error Insight Description Steps:[QC Short Description] "Identifier redeclared" with procedures after generic "reference to procedure" [QC Description] ...\RAD Studio\7.0\source\Win32\rtl\sys\SysUtils.pas does produce since FT build 3478 some "new" Error Insight error. They were probably hidden due RAID 213361 (+ QC 64959/RAID 263095) and the error has something todo with generic "reference to procedure" -> see steps QC Entry 75920

- save the file at the end of the steps - start Weaver - open SimplifiedSysUtils.pas expected: no Error Insight errors in the Structure view actual: Identifier redeclared 'GetDefaultFallbackLanguages' at line 16 (16:10) Identifier redeclared 'SetDefaultFallbackLanguages' at line 20 (20:11) Identifier redeclared 'PreferredUILanguages' at line 24 (24:10) - open ...\RAD Studio\7.0\source\Win32\rtl\sys\SysUtils.pas expected: no Error Insight errors in the Structure view actual: Identifier redeclared 'GetDefaultFallbackLanguages' at line 22731 (22731:10) Identifier redeclared 'SetDefaultFallbackLanguages' at line 22736 (22736:11) Identifier redeclared 'PreferredUILanguages' at line 22746 (22746:10) unit SimplifiedSysUtils; interface type TProc<T> = reference to procedure; function GetDefaultFallbackLanguages: string; procedure SetDefaultFallbackLanguages(const Languages: string); function PreferredUILanguages: string; implementation function GetDefaultFallbackLanguages: string; begin end; procedure SetDefaultFallbackLanguages(const Languages: string); begin end; function PreferredUILanguages: string; begin end; end.

QC #: 75927 - Status: Closed

QC #: Project Date Reported: Area:75927 C++Builder 7/20/2009 IDE\Code Editor\Formatting Description Steps:[QC Short Description] [C++ formatter] Handling of spaces after control structure keywords is inconsistent [QC Description] The handling of spaces after control structure keywords is inconsistent: if (true) // space while (true) // space for (; ; ) // space catch(...) // no space switch(i) // no space There should be one separate option to control them all, IMHO. QC Entry 75927

- Create a new C++Builder console application - Insert this code: // ----- int main (void) { while (true) // space if (true) // space { } for (; ; ) // space try { } catch (...) // no space { } switch (0) // no space { } } // -----

- Run the formatter (Right click|Format source) Exp.: consistent spaces after control structure keywords Act.: some have a space, some don't

QC #: 75928 - Status: Closed

QC #: Project Date Reported: Area:75928 C++Builder 7/20/2009 IDE\Code Editor\Formatting Description Steps:[QC Short Description] [C++ formatter] Argument of "catch" statement is parsed as expression [QC Description] The "catch" statement contains a declaration, e.g.: // ----- catch (Exception& e) { ... } // ----- However, the formatter parses it as an expression, views the & as binary operator and thus changes the statement to // ----- catch (Exception & e) { ... } // ----- .. QC Entry 75928

- Create a new C++Builder console application - Insert this code: // ----- void foo (int* i) // parsed as declaration { try { } catch (int* j) // parsed as expression { } } // ----- - Run the formatter (Right click|Format source) Exp.: "int* j" inside the catch clause is parsed as declaration and becomes "int* j" (with space), similar to the declaration in the first line Act.: "int* j" inside the catch clause is parsed as expression and becomes "int*j"

QC #: 75941 - Status: Closed

QC #: Project Date Reported: Area:75941 Delphi 7/20/2009 IDE\Code Editor\Formatting Description Steps:[QC Short Description] Code Formatter: formatting of message handlers QC Entry 75941

Message handlers like procedure WMLButtonDown(var Msg: TWMMouse); message WM_LBUTTONDOWN; are formatted into procedure WMLButtonDown( var Msg: TWMMouse); message WM_LBUTTONDOWN; Not good. It's also weird, 'cause 'virtual', 'override', 'abstract' keywords are kept on the same line, which is correct and expected.

QC #: 75972 - Status: Closed

QC #: Project Date Reported: Area: 75972 Delphi 7/21/2009 Midas\TClientDataSet Description Steps:[QC Short Description] CDS not returning all records [QC Description] The TClientDataSet makes problems with some tables, where the orderkey has some special values. As such it will stop on returning all the records, as if it thinks it is at the eof, which is wrong. I'm not exactly sure, but I think it has something to do with the internal index generation of the CDS, which makes some weird things. (see QC 75974) In my testapplication I have 25'000 records, but the CDS returns only about 100 and then it stops. See my sample project and follow the

1. Unzip the attached Sample Project. 2. Change the SQLConnection1.Params to your environement. I'm testing with BlackfishSQL and Informix. 3. Compile and run the application. This application will create a new table "testdbxorder" and adds 25'003 records into that table. Follow this steps: 1. The first time you run the application, press the 'Fill Table' button. This will take some time, about 1-2 Minutes. 2. Now press on "Go DBX" button to run the SQL in the Memo1. 3. Select the DBGrid and move the cursor down to scroll through the recordset. After 100 records it stops browsing on the value "-250".

steps. QC Entry 75972

QC #: 76020 - Status: Closed

QC #: Project Date Reported: Area:76020 Delphi 7/22/2009 RTL\Delphi\Other Classes\TEncoding

Description Steps:[QC Short Description] TEncoding.ASCII property is broken on some systems [QC Description] The TEncoding.ASCII property uses codepage 20127 exclusively. Not all OS versions support that codepage, though. When not available, the TEncoding.ASCII property should fallback to codepage 1252 instead. This bug exists in Tiburon as D2009 as well. QC Entry 76020

Addressing this issue can be handled inside of the TMBCSEncoding constructor, ie: constructor TMBCSEncoding.Create(CodePage: Integer); begin // FCodePage := CodePage; Create(CodePage, 0, 0); end; constructor TMBCSEncoding.Create(CodePage, MBToWCharFlags, WCharToMBFlags: Integer); var LCPInfo: TCPInfo; LError: Boolean; begin FCodePage := CodePage; FMBToWCharFlags := MBToWCharFlags; FWCharToMBFlags := WCharToMBFlags; LError := not GetCPInfo(FCodePage, LCPInfo); if LError and (FCodePage = 20127) then begin FCodePage = 1252; LError = not GetCPInfo(FCodePage, LCPInfo); end; if LError then raise EEncodingError.CreateRes(@SInvalidCodePage); FMaxCharSize := LCPInfo.MaxCharSize; FIsSingleByte := FMaxCharSize = 1; end;

QC #: 76074 - Status: Closed

QC #: Project Date Reported: Area: 76074 Delphi 7/25/2009 Compiler\Delphi\Generics Description Steps:[QC Short Description] Generic methods on non-generic classes place blue dots in the wrong unit [QC Description] When compiling a non-generic class or record with generic methods, the blue dots in the gutter for these methods get placed at the correct line number, but in the units where the call to them is made, not in the unit where the method is defined. This makes debugging very difficult.QC Entry 76074

Load the attached product and compile. Note the location of the blue dots in the DPR for the first two method calls. Look at bluedot_map.pas and see that the dots for the record with a generic type get placed correctly.

QC #: 76080 - Status: Closed

QC #: Project Date Reported: Area: 76080 C++Builder 7/25/2009 Compiler\C++\Front End

Description Steps:[QC Short Description] Label problem [QC Description] [BCC32 Error] File1.cpp(10): E2379 Statement missing ; Full parser context File1.cpp(7): parsing: void Foo() [BCC32 Error] File1.cpp(10): E2134 Compound statement missing }Full parser context File1.cpp(7): parsing: void Foo() The same incorrect error messages are given with a few versions of Builder. The compiler appears to have a problem with functions that end with a label and then an object declaration. QC Entry 76080

void Foo() { b: int i; } // line 10

QC #: 76150 - Status: Closed

QC #: Project Date Reported: Area:76150 Delphi 7/28/2009 VCL\Touch Controls\TTouchKeyboard

Description Steps:[QC Short Description] TTouchKeyboard: Caps Lock issue [QC Description] see steps QC Entry 76150

- press caps lock, so it's on (use the hardware keyboard) - start a TTouchKeyBoard app. - The Caps Lock button is now white, that's good. - The alpha keys show lowercase letters, that's NOT good. The alpha keys are still wrong after pressing Caps Lock Pressing an alpha key works fine, it's just a button caption painting issue.

QC #: 76174 - Status: Closed

QC #: Project Date Reported: Area: 76174 Delphi 7/29/2009 IDE\Code Editor Description Steps:[QC Short Description] Code Formatter: break before End QC Entry 76174

The code Procedure TForm1.FormClick(Sender : TObject); Begin ShowMessage('1'); End; is formatted into Procedure TForm1.FormClick(Sender : TObject); Begin ShowMessage('1'); End; which is correct and expected. OTOH, slightly different code Procedure TForm1.FormClick(Sender : TObject); Begin {ShowMessage('1');} End; is formatted into Procedure TForm1.FormClick(Sender : TObject); Begin {ShowMessage('1');} End; 'End' is not on separate line as one would expect. Maybe need to introduce option 'Break before End'? Currently we only have options to break after Begin.

[vk] commments location is saved as in the source code

QC #: 76175 - Status: Closed

QC #: Project Date Reported: Area: 76175 C++Builder 7/29/2009 IDE\Project Management Description Steps:Regression against Tiburon 12.0.3390.20513 [QC Short Description] Unresolved external 'LresultFromObject' [QC Description] I opened a project that compiles and runs without error in RS 2009 and tried to build in Weaver, but I get the following error: [ILINK32 Error] Error: Unresolved external 'LresultFromObject' referenced from C:\PROGRAM FILES\CODEGEAR\RAD STUDIO\7.0\LIB\DEBUG\VCLACTNBAND.LIB|ActnMenus Since the error is coming from actnband.lib and my project does not need that library, I tried to disable it by removing the reference to it from the runtime libraries list. Even with the reference removed, I receive the same error on build. The attachment contains the project file after removing most of the project content and demonstrates the error. I cannot reproduce this in a project built entirely in Weaver. QC Entry 76175

Open attached project in Weaver Shift+F9 to build Exp: Successful build as in RS 2009 Act: [ILINK32 Error] Error: Unresolved external 'LresultFromObject' referenced from C:\PROGRAM FILES\EMBARCADERO\RAD STUDIO\7.0\LIB\DEBUG\VCLACTNBAND.LIB|ActnMenus [ILINK32 Error] Error: Unable to perform link Failed

QC #: 76191 - Status: Closed

QC #: Project Date Reported: Area:76191 Delphi 7/29/2009 ActiveX\IDE\Options Dialogs Description Steps:[QC Short Description] Translation missing - Options dialog [QC Description] within options dialog is a translation missing "Umgebungsoptions"->"Compilieren" Label: "Verbosity" QC Entry 76191

click tools first treeoption in german "Umgebungsoptionen". see label "Verbosity"

QC #: 76213 - Status: Closed

QC #: Project Date Reported: Area:76213 Delphi 7/30/2009 IDE\Code Editor\Error Insight Description Steps:[QC Short Description] IDE reports missing fields but compiler se no problem [QC Description] IDE/Structure Error

Just load the code. Just an empty form with some added code. ------------------------------------------------ unit Unit1; interface uses Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms, Dialogs, Generics.Collections; type TStructList<T: class> = class(TObjectList<T>) end; TItemClass = class(TObject) private

TStructList '1' does not contain a member named 'Field1' at line 54(54:16) This piece of code will build with no errors, warnings or hints. What is the problem? Best Regards Anders QC Entry 76213 See also 272863.

FField1: integer; FField2: double; FField3: string; public property Field1: integer read FField1 write FField1; property Field2: double read FField2 write FField2; property Field3: string read FField3 write FField3; end; TForm1 = class(TForm) procedure FormActivate(Sender: TObject); private MyList: TStructList<TItemClass>; public { Public declarations } end; var Form1: TForm1; implementation {$R *.dfm} procedure TForm1.FormActivate(Sender: TObject); var MyItem: TItemClass; begin // Create the list MyList := TStructList<TItemClass>.Create(True); // Generate some items MyItem := TItemClass.Create; MyList.Add(MyItem); MyItem := TItemClass.Create; MyList.Add(MyItem); // Se if we can reference some fields if Mylist[0].Field1 = 0 then ShowMessage('Kilroy was here'); end; end. ------------------------------------------------

QC #: 76226 - Status: Closed

QC #: Project Date Reported: Area:

76226 C++Builder 7/30/2009 Compiler\C++\Front End\Pre-Compiled Headers

Description Steps:Regression against Tiburon 12.0.3420.21218 [QC Short Description] F1004 ICE at 0x4ce94d with base 0x400000 w/ -H [QC Description] Compiling with the -H option I will receive the following internal compiler error. Compiling without -H option will be successful. Compiling a preprocessed source file, with or without -H, has no effect. bcc32.exe -DIS_DLL;USE_DLL;TIMER_DEBUG;_DEBUG;STRICT-D_RTLDLL -UNO_STRICT -I"C:\Program Files\Embarcadero\RAD Studio\7.0\include";"C:\Program Files\Embarcadero\RAD Studio\7.0\include\vcl";"C:\Program Files\Embarcadero\RAD Studio\7.0\include\dinkumware";"C:\Program Files\Embarcadero\RAD Studio\7.0\ObjRepos\Cpp";"C:\Program Files\Embarcadero\RAD Studio\7.0\include\Indy10" -y -v4 -Q -c -tWM -tW -Vx -Ve -He- -C8 -wstl -wimp -Od -v -vi -H HighResElapsedTimer.cpp Embarcadero C++ 6.20 for Win32 Copyright (c) 1993-2009 Embarcadero Technologies, Inc. highreselapsedtimer.cpp: Loaded pre-compiled headers. Fatal F1004 highreselapsedtimer.cpp 161: Internal compiler error at 0x4ce94d wit h base 0x400000 Fatal F1004 highreselapsedtimer.cpp 161: Internal compiler error QC Entry 76226

1 - download attached files 2 - bcc32.exe -DIS_DLL;USE_DLL;TIMER_DEBUG;_DEBUG;STRICT -D_RTLDLL -UNO_STRICT -y -v4 -Q -c -tWM -tW -Vx -Ve -He- -C8 -wstl -wimp -Od -v -vi -H HighResElapsedTimer.cpp // Note: if the ICE does not appear at the first attempt, repeat step 2 above act: Loaded pre-compiled headers. Fatal F1004 HighResElapsedTimer.cpp 161: Internal compiler error at 0x4ce94d wit h base 0x400000 Fatal F1004 HighResElapsedTimer.cpp 161: Internal compiler error exp: No ICE [QC Steps] To fail: 1) Compile the attached source file with the described bcc32.exe command.

QC #: 76277 - Status: Closed

QC #: Project Date Reported: Area:76277 Delphi 7/31/2009 IDE\Code Editor\Error Insight Description Steps:[QC Short Description] "Overloaded procedure 'TFoo.Bar' must be marked with the 'overload'..." with generic type a result [QC Description]

- save the file at the end of the steps - start Weaver - open GenericsResultOverloadErrorInsightTest.dpr expected: no Error Insight errors in the Structure view actual: Overloaded procedure 'TRttiType.GetMethods' must be marked with the 'overload' directive at line 18 (18:10) - open ...\RAD

...\RAD Studio\7.0\source\Win32\rtl\common\Rtti.pas does produce a Error Insight error for an overloaded method with a generic type as result. -> see steps QC Entry 76277

Studio\7.0\source\Win32\rtl\common\Rtti.pas expected: no Error Insight errors in the Structure view actual: Overloaded procedure 'TRttiType.GetMethods' must be marked with the 'overload' directive at line 3401 (3401:10) program GenericsResultOverloadErrorInsightTest; {$APPTYPE CONSOLE} type TArray<T> = class(TObject); TRttiType = class(TObject) function GetMethods: TArray<TObject>; overload; function GetMethods(const AName: string): TArray<TObject>; overload; end; function TRttiType.GetMethods: TArray<TObject>; begin Result := nil; end; function TRttiType.GetMethods(const AName: string): TArray<TObject>; begin Result := nil; end; begin end.

QC #: 76299 - Status: Closed

QC #: Project Date Reported: Area: 76299 Delphi 8/1/2009 VCL\Ribbon Controls Description Steps:[QC Short Description] Deleting a combobox from a Ribbon cause an exception [QC Description] Deleting a combobox from a Ribbon cause an exception QC Entry 76299

Open RibbonDemo Go to Home tab Click on rcbFontSize Press delete key An exception occures [[10534938]{vclribbon140.bpl} RibbonActnCtrls.TRibbonComboControl.SetBounds (Line 4382, "RibbonActnCtrls.pas" + 4) + $F [500073FE]{rtl140.bpl } System.ErrorAt (Line 3645, "System.pas" + 3) + $4 [10534938]{vclribbon140.bpl} RibbonActnCtrls.TRibbonComboControl.SetBounds (Line 4382, "RibbonActnCtrls.pas" + 4) + $F [1051D0A8]{vclribbon140.bpl} Ribbon.TCustomRibbonGroup.AlignGroupControls (Line 6851, "Ribbon.pas" + 93) + $12 [502996AB]{vcl140.bpl } Controls.TWinControl.Notification (Line 8959, "Controls.pas" + 1) + $6 [1051E6D5]{vclribbon140.bpl} Ribbon.TCustomRibbonGroup.Notification (Line 7495, "Ribbon.pas" + 9) + $4 [50075359]{rtl140.bpl } Classes.TComponent.RemoveFreeNotifications (Line 11810, "Classes.pas" + 4) + $11 [500752FC]{rtl140.bpl } Classes.TComponent.Destroy (Line 11793, "Classes.pas" + 2) + $2 [50293A7B]{vcl140.bpl } Controls.TControl.Destroy (Line 5222, "Controls.pas" + 27) + $7 [50009D14]{rtl140.bpl } System.TObject.FreeInstance (Line 9440, "System.pas" + 2) + $2 [5000A3E6]{rtl140.bpl } System.@ClassDestroy (Line 10319, "System.pas" + 0) + $2 [50293198]{vcl140.bpl } Controls.TControlCanvas.Destroy (Line 4865, "Controls.pas" + 3) + $6 [5029FD7C]{vcl140.bpl } Controls.TGraphicControl.Destroy (Line 13104, "Controls.pas" + 3) + $7 [214E1B6A]{vclactnband140.bpl} ActnMan.TCustomActionControl.Destroy (Line 5749, "ActnMan.pas" + 3) + $7 [1053418A]{vclribbon140.bpl} RibbonActnCtrls.TRibbonComboControl.Destroy (Line 4164, "RibbonActnCtrls.pas" + 4) + $7 [50009D5C]{rtl140.bpl } System.TObject.Free (Line 9459, "System.pas" + 1) + $4 [214E1085]{vclactnband140.bpl} ActnMan.TCustomActionBar.RecreateControls (Line 5448, "ActnMan.pas" + 4) + $15 [214DE3AB]{vclactnband140.bpl} ActnMan.TActionClientItem.SetCommandStyle (Line 4063, "ActnMan.pas" + 33) + $A [10534817]{vclribbon140.bpl} RibbonActnCtrls.TRibbonComboControl.Notification (Line 4347, "RibbonActnCtrls.pas" + 7) + $8 [500756C0]{rtl140.bpl } Classes.TComponent.Notification (Line 11979, "Classes.pas" + 8) + $12 [50293E37]{vcl140.bpl } Controls.TControl.Notification (Line 5426, "Controls.pas" + 1) + $6 [502996AB]{vcl140.bpl } Controls.TWinControl.Notification (Line 8959, "Controls.pas" + 1) + $6 [214E0337]{vclactnband140.bpl} ActnMan.TCustomActionBar.Notification (Line 5001, "ActnMan.pas" + 1) + $6 [1051E69F]{vclribbon140.bpl} Ribbon.TCustomRibbonGroup.Notification (Line 7487, "Ribbon.pas" + 1) + $6 [500756C0]{rtl140.bpl } Classes.TComponent.Notification (Line 11979, "Classes.pas" + 8) + $12 [50293E37]{vcl140.bpl } Controls.TControl.Notification (Line 5426, "Controls.pas" + 1) + $6 [502996AB]{vcl140.bpl } Controls.TWinControl.Notification (Line 8959, "Controls.pas" + 1) + $6 [502BEC17]{vcl140.bpl } Forms.TCustomForm.Notification (Line 3362, "Forms.pas" + 1) + $6 [20D80EB1]{designide140.bpl} Proxies.NotificationHook (Line 310,

"Proxies.pas" + 8) + $B [50075549]{rtl140.bpl } Classes.TComponent.RemoveComponent (Line 11903, "Classes.pas" + 2) + $8 [50075311]{rtl140.bpl } Classes.TComponent.Destroy (Line 11795, "Classes.pas" + 4) + $9 [50293A7B]{vcl140.bpl } Controls.TControl.Destroy (Line 5222, "Controls.pas" + 27) + $7 [5029821B]{vcl140.bpl } Controls.TWinControl.Destroy (Line 8198, "Controls.pas" + 34) + $7 [10534FDD]{vclribbon140.bpl} RibbonActnCtrls.TCustomRibbonComboBox.Destroy (Line 4589, "RibbonActnCtrls.pas" + 2) + $7 [50009D5C]{rtl140.bpl } System.TObject.Free (Line 9459, "System.pas" + 1) + $4 [20DAF869]{designide140.bpl} ComponentDesigner.TComponentRoot.DeleteSelection (Line 4628, "ComponentDesigner.pas" + 44) + $2 [20DC2DAB]{designide140.bpl} Surface.TDesignSurface.DeleteSelection (Line 193, "Surface.pas" + 0) + $7 [20D8E48B]{designide140.bpl} Designer.TDesigner.DeleteSelection (Line 751, "Designer.pas" + 2) + $5 [20D909EF]{designide140.bpl} Designer.TDesigner.Key (Line 1547, "Designer.pas" + 4) + $3 [5196CF04]{vcldesigner140.bpl} VCLSurface.KeyEvent (Line 3000, "VCLSurface.pas" + 8) + $1E [5196D80E]{vcldesigner140.bpl} VCLSurface.TVclDesignSurface.IsDesignMsg (Line 3182, "VCLSurface.pas" + 61) + $6 [50009F7E]{rtl140.bpl } System.@IsClass (Line 9739, "System.pas" + 1) + $8 [50296273]{vcl140.bpl } Controls.TControl.WndProc (Line 6968, "Controls.pas" + 4) + $21 [20D6C80E]{designide140.bpl} DeskUtil.SetFocusHook (Line 454, "DeskUtil.pas" + 4) + $C [5029AD50]{vcl140.bpl } Controls.TWinControl.WndProc (Line 9797, "Controls.pas" + 144) + $6 [502BFCDC]{vcl140.bpl } Forms.TCustomForm.WndProc (Line 3960, "Forms.pas" + 191) + $5 [5029A41D]{vcl140.bpl } Controls.TWinControl.MainWndProc (Line 9521, "Controls.pas" + 6) + $0 [5029AD50]{vcl140.bpl } Controls.TWinControl.WndProc (Line 9797, "Controls.pas" + 144) + $6 (0002D49C){CnWizards_D14.dll} [0948E49C] [502BFCDC]{vcl140.bpl } Forms.TCustomForm.WndProc (Line 3960, "Forms.pas" + 191) + $5 [2215510B]{delphivclide140.bpl} VCLFormContainer.TControlSizer.ControlWndProc (Line 306, "VCLFormContainer.pas" + 33) + $C [5029A408]{vcl140.bpl } Controls.TWinControl.MainWndProc (Line 9518, "Controls.pas" + 3) + $6 [50076E3C]{rtl140.bpl } Classes.StdWndProc (Line 13072, "Classes.pas" + 8) + $0 [502C8EF1]{vcl140.bpl } Forms.TApplication.ProcessMessage (Line 9784, "Forms.pas" + 30) + $1 [502C8F36]{vcl140.bpl } Forms.TApplication.HandleMessage (Line 9814, "Forms.pas" + 1) + $4 [502C9261]{vcl140.bpl } Forms.TApplication.Run (Line 9951, "Forms.pas" + 26) + $3 [0042C94A]{bds.exe } bds.bds (Line 200, "" + 8) + $FFFB Note: this happens in Delphi 2009 too

QC #: 76312 - Status: Closed

QC #: Project Date Reported: Area: 76312 Delphi 8/2/2009 AddOn\Quality Central Description Steps:[QC Short Description] QC client: Windows 7 cannot add an Attachement [QC Description] Added by Sysop <<<<<<<<<<<<< This issue is about QualityCentral client which comes with Weaver. >>>>>>>>>>>>> Try to add an Attachment on Windows 7 Got this message: cdsAttachmentHeader: Missing data provider or data packet

QC Entry 76312

QC #: 76313 - Status: Closed

QC #: Project Date Reported: Area: 76313 Delphi 8/2/2009 IDE\Search\Find Description Steps:[QC Short Description] There is no way to search text using Entire Scope in Weaver as it was in D2009 QC Entry 76313

In D2009 and all previous versions there was possible to do search in Entire Scope. It means whatever I press Ctrl+F and type text and press Enter it will search from beginning of the file. It first thing I set when setting up new version. But I found that it is not possible to get it in Weaver. There is only way to do it to click on button in search bar to start from begging. It is really slowdown search for me because I rarely use mouse when I typing and form me it is big productivity issue.

QC #: 76332 - Status: Closed

QC #: Project Date Reported: Area: 76332 Delphi 8/3/2009 IDE\Search\Find Description Steps:[QC Short Description] Find bar (Ctrl-F) options doesn't shown [QC Description] When using Ctrl-F option find bar shown but some options are hidden behind "Additional search options" button when plenty of space available to show all of them in one place QC Entry 76332

used screen resolution: 1680x1050 run and maximaze Delphi 2010 open any file for editing press Ctrl-F - find bar is shown the result - some options (usually Search selection, but sometimes others depends on program window size) are not shown hidden behind "Additional search options" button when plenty of space available to show all of them in one place (See attached image)

QC #: 76349 - Status: Closed

QC #: Project Date Reported: Area:76349 C++Builder 8/3/2009 Compiler\C++\Front End\Language

Description Steps:[QC Short Description] Internal Compiler Error when using a closure that returns a reference [QC Description] When a closure returns a reference, the compiler crashes with an access violation. QC Entry 76349

bcc32 272023.cpp

QC #: 76390 - Status: Closed

QC #: Project Date Reported: Area:76390 Delphi 8/4/2009 IDE\Code Editor\Formatting Description Steps:[QC Short Description] Code Formatter: line break after 'uses' QC Entry 76390

With current set of formatter options it's impossible to format Uses clause in "classic" way, as follows: uses

Classes, Controls, Forms; It's only possible to get uses Classes, Controls, Forms; or uses Classes, Controls, Forms; [vk] Additional parameter "New Line after Uses keyword"

QC #: 76395 - Status: Closed

QC #: Project Date Reported: Area: 76395 C++Builder 8/4/2009 CodeGuard Description Steps:[QC Short Description] CodeGuard and TCppWebBrowser cause application crash on startup [QC Description] Enabling CodeGuard on an application that uses a TCppWebBrowser component within it causes an application crash with an empty message box and no diagnostic information as to the cause. In my case, I had moved a large application with many units from CB2006 to CB2009. The application ran without problem, but when I enabled CodeGuard, the application would not even start (the cryptic details are below), and a breakpoint on the first line of WinMain was never reached. I spent many hours searching for the cause of the problem, tearing out parts of the application until I found it. This will occur in any application that uses either a TCppWebBrowser or TWebBrowser anywhere in it; even including the .h file of a unit that uses one of these components will cause the problem. Note that the following thread was posted in the forum in January, 2009, without response: https://forums.codegear.com/thread.jspa?messageID=66367&tstart=0 Unlike that thread, I do not get a codeguard log indicating what happened. The .cgl file does not have anything useful. This is a basic functionality failure because CodeGuard is an important part of CB2009, and is useless if there is a TCppWebBrowser anywhere in the application, since the application crashes without giving a reason why or any reason to suspect that the TCppWebBrowser (as opposed to any one of the thousands of other components) is the problem. QC Entry 76395

Using C++ Builder 2009 installed on a 64 bit virtual machine running under VMWARE on a Mac File/New/VCL Forms Application - C++ Builder File/Save Project As... (pick location to save project) Project/Options... Select the C++ Compiler/Debugging page Double-click on "False" under Enable Codeguard (change it from False to True) OK to close dialog Run/Run (to compile, link, and run program) The blank form appears without problem Close the new blank form application by clicking on the red "X" in the upper right of the window In the tool palette search box, type "tcpp", see the TCppWebBrowser Click on TCppWebBrowser in the tool palette, then click once on the form, to drop a TCppWebBrowser on the form Run/Run (to compile, link, and run program) Instead of the application running, a small, empty message box with no caption or text, but just an "OK" button appears. Click "OK" Windows puts up a message box, "Application has stopped working" with two choices, to "Check online for a solution and close the program" or "Close the program" Click "Close the program" A message box comes up: "The application failed to initialize properly (0xc0000005). Click OK to terminate the application." Click "OK" and get dropped into a CPU window. Press Ctrl-F2 to stop the program. Project/Options... Select the C++ Compiler/Debugging page Double-click on "True" under Enable Codeguard (change it from True to False) OK to close dialog Run/Run (to compile, link, and run program) The blank form appears with the blank TCppWebBrowser on it.

QC #: 76419 - Status: Closed

QC #: Project Date Reported: Area: 76419 C++Builder 8/5/2009 Compiler\C++ Description Steps:[QC Short Description] Compiler may ignore const keyword on primitive data type parameters

bcc32 -w- qc76419.cpp exp: Error E2024 qc76419.cpp 5: Cannot modify a const object in function test_me(const int) act: clean compile

[QC Description] If a primitive data type parameter is declared as const after being prototyped as non-const, the compiler ignores that parameter's const-ness and permits it to be modified anyway. Parameters declared as const in this fashion are somewhat unique in that the const-ness isn't part of the function's signature, but the compiler should still enforce it within that function. QC Entry 76419

QC #: 76446 - Status: Closed

QC #: Project Date Reported: Area: 76446 Delphi 8/6/2009 International\Truncation Description Steps:[QC Short Description] Background compiling - German text in the dialog is truncated [QC Description] German text in the dialog is truncated See picture QC Entry 76446

1. I enabled background compiling in Option 2. Rebuild my project and hit F12 to switch from frormdesigner to codedesigner. The compiling prozess stopped and Delphi locked. 3. I using the taskmanager and finished the Delphi prozess. After this the compiler finshed his prozess and I got a message "Für dies Operation muss die aktuelle Hintergrund-Compilierung abgebrochen werden. Soll die Hintergrund-Compilierung abgebrochen und weitergemacht"

QC #: 76481 - Status: Closed

QC #: Project Date Reported: Area:76481 Delphi 8/7/2009 VCL\Win 32 Controls\TPageScroller

Description Steps:[QC Short Description] TPagescroller looses scroll-buttons [QC Description] The TPageScroller loses the scrollbuttons if the content is resized while the Scrollers position is not 0. This way elements contained in the scrollbox may get unreachable. QC Entry 76481

I'll attach a tiny application demontrating the problem. * Launch the app, * Click on Button 1 - a scroll-arrow appears * Click the scroll-button to scroll to the right * Click Button2 - 2 scroll buttons appear * Click the scroll-right-button BANG! Both scroll-buttons disappear!

QC #: 76502 - Status: Closed

QC #: Project Date Reported: Area: 76502 C++Builder 8/7/2009 Documentation Description Steps:[QC Short Description] No entry for UIntToStr [QC Description] No entry for UIntToStr. However some other UIntTo... conversion is documented QC Entry 76502

Try to use Index for found.

QC #: 76503 - Status: Closed

QC #: Project Date Reported: Area: 76503 C++Builder 8/7/2009 Documentation

Description Steps:[QC Short Description] The Index entry for IntToStr is too strict [QC Description] The Index entry for IntToStr is too strict, because only Indy's function is in the help QC Entry 76503

The Index entry for IntToStr is too strict, because only Indy's function is in the help. Try to find in index

QC #: 76504 - Status: Closed

QC #: Project Date Reported: Area: 76504 C++Builder 8/7/2009 Documentation Description Steps:[QC Short Description] Bad navigation from IntToStr by F1 [QC Description] Bad navigation from IntToStr by F1. The occurring window not contain the function of the conversion. QC Entry 76504

Bad navigation from IntToStr by F1. The occurring window not contain the function of the conversion.

QC #: 76508 - Status: Closed

QC #: Project Date Reported: Area:76508 C++Builder 8/7/2009 IDE\Code Editor\Formatting Description Steps:[QC Short Description] One initializer per line option [QC Description] When writing the definition of a constructor, one common coding idiom is to initialize one base or class member per line, rather than hoist them all onto the same line. This could be another code formatter option under line-breaks E.g. given struct MyClass : Base1, Base2 { MyClass( int a, int b, int c ); int m; }; I would want to write: MyClass::MyClass( int a, int b, int c ) : Base1() , Base2(a, b) , m(c) { } Tweaks others might be interested in with the same layout include: whether the comma goes at the end of the previous line, or start of the next (as I prefer) whether the opening brace goes on new line, or after last initializer whether opening brace is indented with the list if on a new line QC Entry 76508

Option added in the form MyClass::MyClass( int a, int b, int c ) : Base1(), Base2(a, b), m(c) { }

QC #: 76511 - Status: Closed

QC #: Project Date Reported: Area:76511 C++Builder 8/7/2009 IDE\Code Editor\Formatting Description Steps:[QC Short Description] Always use {} with conditional statements [QC Description] After an if, else, while or for statement comes a second statement, which may be a compound statement in {}. It is optional if a single statement should be written inside {} as well, and coding conventions vary. If would be helpful if the code formatter could enforce project rules for this - so options that a single statement should: i/ never be put in {} ii/ always be put in {} iii/ respect the existing source This might be configured as a general rule about controlled expressions, or it might be configured per-keyword. QC Entry 76511

[vk] Not all should be fixed!!! 1. case i/ "never be put in {}" can be very dangerous 2. case iii/ "respect the existing source" - the current behaviour 3. case ii/ "always be put in {}" - we can add such option in the form from Together 6.1 "Surround simple body by curly braces" autoformat.java.controlStatement.forceBodyBraces = false | true | ifOnNextLine Defines how Together will treat a simple body in control expressions.(A simple body is not surrounded by curly braces. For example, if (true) processAccount();") - true - Together will always surround a simple body by curly braces.if (true) processAccount(); -> if (true) { processAccount(); } - false - Together will never surround a simple body by curly braces. if (true) processAccount(); will not be changed - ifOnNextLine - Together will surround a simple body by curly braces only if it is located on a new line [vk] Option planned CppFormatter.ForceBraces = "Force braces in control statements" = (Yes, No, IfOnNextLine) CppFormatter.ForceBraces.Description = "Defines how Formatter will treat a simple body (without braces) in control statement:. * Yes - always surround a simple body by braces. * No - do not change a simple body * If on the next line - surround a simple body by braces only if it is located on a new/multiple lines but we have very big problem: if the source contains many #if - #else threads source can be destroyed after such operation, because for one opening brace it can be necessary to add many closing braces etc. It seems that it is necessary for such source fragments (preprocessor directives inside body) disable this option.

QC #: 76530 - Status: Closed

QC #: Project Date Reported: Area: 76530 Delphi 8/8/2009 IDE Description Steps:[QC Short Description] Reopen project with file removed QC Entry 76530

First of all, 'Project desktop' in 'Autosave options' must be checked. Open some project. Open few units. Close the project (remember which unit was active one). -- NOTE: I had to make sure the Welcome page was closed as well to reproduce this..... In explorer delete/rename that unit. Reopen project in Delphi -> it ends up with no active module. There are unit tabs, but no editor. Clicking on tabs restores everything to normal. This is not new to Weaver. D2009 has the very same behavour. D2007 in this case just opens empty layout - no editor tabs at all.

QC #: 76563 - Status: Closed

QC #: Project Date Reported: Area:76563 Delphi 8/10/2009 IDE\Code Editor\Help Insight Description Steps:[QC Short Description] Tooltip help insight is not working for symbols inside "on" statement block [QC Description] Tooltip help insight is not working for symbols inside "on" statement block QC Entry 76563

Create a new Delphi Win32 application Double click on the new form In the OnCreate Event past this code : try showmessage('Hello'); except on E: Exception do showmessage('Hello'); end; Hover the mouse over showmessage('Hello'); ("on" block) Act : code parameter hint is displayed Expt : Tooltip help insight should be displayed

QC #: 76580 - Status: Closed

QC #: Project Date Reported: Area: 76580 Delphi 8/10/2009 Database\DataSnap\Server Description Steps:[QC Short Description] Server method parameter lost data [QC Description] When I pass a double value via parameter to server method, the server side only get a zero. The Server side: procedure TDSServerModule1.SaveInvoice(const SessionID, InvoiceNumber, ClientAccountCode: string; BilledAmount, TaxableAmount, GSTTotal, PSTTotal, QSTTotal, HSTTotal: double; InvoiceImage: OleVariant); The Client side: DataModuleMain.Client.SaveInvoice('', InvoiceNumber, cdsInvoiceSummaryClientAccountCode.AsString, InvoiceTotal, TaxableTotal, GSTTotal, PSTTotal, QSTTotal, HSTTotal, //value 20.31 vaPDF); When debug the server side, I found HSTTotal has value 0 instead of 20.31 QC Entry 76580

DataSnapDM.native.Db.test.exe connection=dsconnection -s:TestRaid_272522 -or- Added by Sysop <<<<<<<<<<<<<< 1. open project group 2. build Server project and run it 3. build Client project and run it 4. click Button2 ---> Results are OK 5. click Button1 ---> Results are NG as below --------- invoice number test 1.1 2.2 3.3 4.4 5.5 6.59999847412109 // NG: expected result is 6.6 0 // NG: expected result is 7.7 9 // OK ----------- >>>>>>>>>>>>>>

QC #: 76639 - Status: Closed

QC #: Project Date Reported: Area: 76639 Delphi 8/12/2009 IDE\Form Designer Description Steps:[QC Short Description] TImageList editor has problems with PNG images [QC Description] TImageList editor has random problems with added PNG files even if set to 32 bpp. The files are from the Glyph FX package and the problem is that sometimes they get a black instead of a transparent background.

1. create a new Win32 forms project with a main form. 2. add a TImageList to it. 3. add a few PNG images from the GlyphFX selection to it (16x16) (2-3 images will do I think) 4. see the black background. Oop, you see now you didn't use 32 Bpp 5. Set the ImageList to 32 Bpp and notice all those images gone. Dam'n it. So add those pictures again. Now continue and play a bit with the list. You should see now that new images aren't always added as last, esp. if the images reach the right borader of the list management window. Drag the images to the desired positions and you should notice

Somebody else (see comments) now confirmed the behaviour and additionally found out, that closing the dialog with OK saves the images ok so it's only the dialog which corrupts the images for display purposes ;-) QC Entry 76639

sometimes black backgrounds.

QC #: 76645 - Status: Closed

QC #: Project Date Reported: Area: 76645 C++Builder 8/12/2009 IDE\Class Explorer Description Steps:[QC Short Description] Class Explorer - no tool tip hint for 3rd button from the right [QC Description] No tool tip hint for the 3rd button from the right on the tool bar of the C++ Class Explorer. I believe that's the "Show inherited members" button? QC Entry 76645

QC #: 76650 - Status: Closed

QC #: Project Date Reported: Area: 76650 C++Builder 8/12/2009 IDE\Class Explorer Description Steps:[QC Short Description] Class Explorer - Refresh doesn't work [QC Description] Refresh in Class Explorer does not do anything. QC Entry 76650

Create a new CPP console app with default options (multithreaded and use vcl). Add a class called test right above #pragma argsused. class test { }; Go to C++ Class Explorer. Select test. Notice there's one entry called test with type test. Go back to source. add nested class test2 under test: class test { class test2 { }; }; Go back to Class Exp. Hit refresh. You should now see test class refreshed and showing 2 entries with test2 as the 2nd entry but nothing happens. However, if you hit the Clear all browser info button and hit refresh, 'test' class info will be updated.

QC #: 76652 - Status: Closed

QC #: Project Date Reported: Area: 76652 C++Builder 8/12/2009 IDE\Code Editor\ Description Steps:[QC Short Description] C++ Code formatter confused when it encounters nested template [QC Description] For non nested template types, it works fine: UIntArray processIds = TProcessManager::GetProcessIds<Process>(); For nested template types, it thinks it's dealing with a greater than symbol rather than a matching close '>' for the template type: GcList<Process>::Type list = gcnew<GcList<Process>::BaseType > (); i.e. should be: gcnew<GcList<Process>::BaseType>();

1 - File | New | Other | C++ Builder Project | Console Application 2 - Ok 3 - Add the below lines to the source code: TProcessManager::GetProcessIds<Process>(); GcList<Process>::Type list = gcnew<GcList<Process>::BaseType>(); 4 - Right clicke and select "Format Source" act: TProcessManager::GetProcessIds<Process>(); GcList<Process>::Type list = gcnew<GcList<Process>::BaseType > (); // notice the whitespace between BaseType and '>' and '>' and (). exp:

*notice the whitespaces between BaseType and '>' and '>' and (). QC Entry 76652

TProcessManager::GetProcessIds<Process>(); GcList<Process>::Type list = gcnew<GcList<Process>::BaseType>(); // no white spaces

QC #: 76653 - Status: Closed

QC #: Project Date Reported: Area: 76653 C++Builder 8/12/2009 IDE\Structure Pane Description Steps:[QC Short Description] Structure pane filter by visibility doesn't refresh when clicked [QC Description] When structure is showing the structure of your code, hitting the "filter by visibility" button should filter the displayed members accordingly. However, it's not refreshed and appears as if the button is broken. It is only when you navigate to a different page and back that it is refreshed (and there's no refresh button either). QC Entry 76653

As above.

QC #: 76661 - Status: Closed

QC #: Project Date Reported: Area: 76661 Delphi 8/13/2009 Install\User Interface Description Steps:[QC Short Description] Ribbon Dialog text layout [QC Description] When you install Weaver and the Ribbon controls are included in the install, you get a dialog that tells you about the license for the Office UI you need to obtain. The text inside this dialog is not formatted correctly. The actual text is as follows: You have chosen to install the Ribbon Controls feature of the VCL.In order to use, copy, modify or distribute this set of user interface controls, you must agree to a licensing agreement with Microsoft for the office UI.You receive no rights in the Office UI from us. Therefore, you may not distribute applications using the Office UI from us without obtaining a license from Microsoft.You can request a license from Microsoft at http://msdn.microsoft.com/officeui. There are a few problems with this text: - Three times no space after a . - One time two spacs after a . - Second line: You receive no rights in (for?) the office UI from us. QC Entry 76661

Install Weaver, make sure Ribbon controls are included

QC #: 76662 - Status: Closed

QC #: Project Date Reported: Area: 76662 Delphi 8/13/2009 Install\Files Description Steps:

[QC Short Description] Quality Central splash screen with CodeGear on it [QC Description] The built-in Quality Central tool of Weaver has a splash screen that still has the word "CodeGear" all over it. QC Entry 76662

Start Quality Central from the Weaver IDE.

QC #: 76667 - Status: Closed

QC #: Project Date Reported: Area:76667 Delphi 8/13/2009 Compiler\Delphi\Execution Description Steps:[QC Short Description] Internal Compiler Error when generating header definition for a subset of an enumeration [QC Description] See steps. QC Entry 76667

Compile the following code (dcc32 -JPHN qc76667.pas): // ----- unit qc76667; interface type TVegetable = (Aubergine, Zucchini, Tomato, Paprika, Onion); TRatatouille = set of TVegetable; // works TPeperonata = set of Tomato..Onion; // fails implementation end. // ----- Exp.: works Act.: Fatal: F2084 Internal error: GH1151

QC #: 76680 - Status: Closed

QC #: Project Date Reported: Area: 76680 Delphi 8/13/2009 IDE\Code Editor Description Steps:[QC Short Description] dialog use unit - OK button disabled [QC Description] After filtering and select an unit with a mouse click the OK button is disabled. QC Entry 76680

Steps by USc: - save the attached files - open UseUnitTest.dpr - open FirstUnit.pas - press ALT+F11 to show the "Use Unit" dialog - enter "Second" in the search edit in the "Use Unit" dialog (see that "OK" is enabled) - click with the mouse on the line with SecondUnit.pas expected: OK is enabled actual: OK is disabled Original Steps: 1. Open a project with few units 2. push [ALT] [F11] to open the dialog "Unit verwenden" Use unit 3. Filter the units and click with the mouse on an unit or click twice on an item The OK button is disabled

QC #: 76684 - Status: Closed

QC #: Project Date Reported: Area:76684 Delphi 8/13/2009 Documentation\Online Help Description Steps:[QC Short Description] Missing documentation on keymappings [QC Description] In the help (ms-help://embarcadero.rs2010/rad/Key_Mappings.html) the "See also" section at the bottom of the page has a number of links, all of which are broken: * Default Key Mapping * IDE Classic Key Mapping * BRIEF Emulation Key Mapping * Epsilon Emulation Key Mapping * Visual Studio Key Mapping * Visual Basic Key Mapping QC Entry 76684

QC #: 76693 - Status: Closed

QC #: Project Date Reported: Area: 76693 Delphi 8/14/2009 IDE\Menus Description Steps:[QC Short Description] No icon for Delphi 2010 on Start menu [QC Description] Please see attached screenshot - that is on Windows 2003 Server, 64-bit. I installed Delphi 2010, noticed this problem, ran the Repair, and the icon is still missing. I do not recall this problem on 32-bit Windows. QC Entry 76693

Install Delphi Start > Programs .... Delphi 2010 this should put Delphi into the short-list of programs to start - see screenshot Delphi is listed in the short-list but there is no icon.

QC #: 76712 - Status: Closed

QC #: Project Date Reported: Area:76712 Delphi 8/15/2009 VCL\Gestures\Components Description Steps:[QC Short Description] Painting issue with some keys on the TTouchKeyboard [QC Description] On my Swiss german keboard layout of the TouchKeyboard are two keys which looks weird. This are the keys, who are used in conjunctionwith another key like this: Pressing the "?" (german Umlaut) and after that the key "a" will produce the char "·. Now the problem is that the first key buttons are painted somehow strange like "?[]". See my attached Image to see better what I mean. QC Entry 76712

Place a TTouchKeayboard on an Swiss german system on a form See the keys left of the $ and Back Buttons. See the attached Image too.

QC #: 76717 - Status: Closed

QC #: Project Date Reported: Area: 76717 Delphi 8/15/2009 Documentation Description Steps:[QC Short Description] Readme.html: Indy9 cannot be used any longer (DE/FR/JA) [QC Description] Indy9 cannot be used any longer. [readme_de.html] Indy-Versionen: Indy10 ist in das Produkt integriert. Sie konnen aber aus dem Verzeichnis C:\Programme\Embarcadero\RAD Studio\7.0\source\Indy\Indy9 auch die Vorgangerversion, Indy9, installieren. [readme_fr.html] Versions Indy : Indy10 est integre au produit. En revanche, vous pouvez installer la version anterieure, Indy9, a partir de C:\Program Files\Embarcadero\RAD Studio\7.0\source\Indy\Indy9.

Added by Sysop <<<<<<<<<<<<< Please see comments of this QC report for more information. >>>>>>>>>>>>>

[readme_ja.html] Indy ?????: Indy10 ?????????????? ??????????????? Indy9 ? C:\Program Files\Embarcadero\RAD Studio\7.0\source\Indy\Indy9 ????????????? # "C:\Program Files\Embarcadero\RAD Studio\7.0\source\Indy\Indy9" is not exists. QC Entry 76717

QC #: 76719 - Status: Closed

QC #: Project Date Reported: Area: 76719 C++Builder 8/15/2009 Documentation Description Steps:[QC Short Description] Release Notes- Known Problems - ActiveX section needs C++ version updated [QC Description] Release Notes for Embarcadero Delphi and C++Builder 2010 in the section: Known Problems ActiveX The following line needs "2009" changed to "2010" "The Register and Unregister menu items are not enabled if you open and run an ActiveX library project in C++ Builder 2009 that was created with" QC Entry 76719

QC #: 76729 - Status: Closed

QC #: Project Date Reported: Area: 76729 Delphi 8/16/2009 IDE\Code Editor Description Steps:[QC Short Description] Editor shows no error when it cannot save a file [QC Description] When the editor cannot save a file due to a low level error, no message is displayed. A temporary file *.$$$ is kept instead. QC Entry 76729

1. Launch the IDE under a non-privileged user (specifically who has no write access to $(BDS)\Source directory). 2. Create a new console application using the wizard. 3. Open SysUtils unit source and make some changes. 4. Try "Save"/"Save all" 5. Try "Compile"/"Run" ("Autosave options->Editor files" should be enabled). In steps #4 and #5 IDE silently refuses to perform the requested action and you have no clue what's going on.

QC #: 76732 - Status: Closed

QC #: Project Date Reported: Area: 76732 Delphi 8/16/2009 IDE\History View

Description Steps:[QC Short Description] Switching to another revision does not reset the search result [QC Description] After performing a search in the History view and switching to another revision the search result is not resetted. -> see steps and attached images

Before you start with the following steps make sure that QC 75439/RAID 270794 and QC 76730 is fixed! - start the IDE - create a new Delphi console application - save it - remove the "{ TODO -oUser -cConsole Main : Insert code here }" line - save it - switch to the History editor tab - switch to the "Content" History sub tab - click into the edit control on the "Contents" tab - press CTRL+F - enter "end" in the search edit and press ENTER (see "end"

This is from the thread "Search in Historie Window?" in .weaver.ide.editor https://forums.embarcadero.com/thread.jspa?messageID=147476&tstart=0#147476Message-ID: <[email protected]> QC Entry 76732

[end;] on line 13 is marked in black see also HistoryViewSearchResultCorrectRevision.png) - select the Revision "~1~" in the Revision content virtual tree expected: the search result is resetted actual: the black mark stays where it is (see HistoryViewSearchResultOtherRevision.png)

QC #: 76743 - Status: Closed

QC #: Project Date Reported: Area: 76743 Delphi 8/16/2009 VCL Description Steps:[QC Short Description] scrollbars don't work with touch QC Entry 76743 trunk rev: 24810 update rev: 24811

The scrollbars of TListBox, TMemo, TStringGrid and TScrollBox don't work with touch on a Windows 7 multi-touch machine. You can click them, but moving the slider or keeping the outer buttons down doesn't work. In NotePad the scrollbars do work.

QC #: 76765 - Status: Closed

QC #: Project Date Reported: Area:76765 C++Builder 8/17/2009 Compiler\C++\Front End\Mangling Scheme

Description Steps:[QC Short Description] Unmangler doesn't handle cv-qualified member function pointers correctly [QC Description] The unmangler doesn't handle cv-qualified member function pointers correctly. Look at the following example: // ----- class A; void pass (void (A::*) (void)) {} void fail (void (A::*) (void) const) {} // ----- For this code, BCC generates the following mangled names: // ----- @pass$qM1Aqv$v @fail$qM1Axqv$v // ----- unmangle.c, when built with -DSTANDALONE, emits the following function names: // ----- pass(void (A::*)() const) fail(void () const void ::*) // ----- The fix is easy; I attached a patch for unmangle.c. QC Entry 76765

- Write the following lines into a file named mangled.txt: // ----- @pass$qM1Aqv$v @fail$qM1Axqv$v // ----- - Build the unmangler in standalone mode (open up a command line window, switch to $(BDS)\source\cpprtl\Source\misc, run "bcc32 -DSTANDALONE -I..\..\rtlinc unmangle.c") - Execute "unmangle.exe mangled.txt" Expected output: // ----- @pass$qM1Aqv$v function 'pass(void (A::*)())' '' 'pass' @fail$qM1Axqv$v function 'fail(void (A::*)()) const' '' 'fail' // ----- Actual output: // ----- @pass$qM1Aqv$v function 'pass(void (A::*)())' '' 'pass' @fail$qM1Axqv$v function 'fail(void () const void ::*)' '' 'fail' // -----

QC #: 76775 - Status: Closed

QC #: Project Date Reported: Area:

76775 Delphi 8/17/2009 IDE\Code Editor Description Steps:[QC Short Description] How to crash the IDE in a few steps [QC Description] Steps: 1) Create a new Delphi forms application and drop a TButton, double klick to auto-create the OnClick handler. 2) In the event handler type some nonsense chars, ensure the last char is not a semicolon. 3) Mark the nonsense string and move the curser to the right within the _same line until some loop starts popping up code insight windows infinitely (eats a lot of CPU time, but IDE still survives). 4) While in that loop press the DEL key. 5) Move the curser to another line to stop the loop. If you do not see strange looking characters in the editor yet just undo last change by using the shortcut keys. A lot of garbage should become visible. Try to delete the garbage and the IDE should crash sooner or later. Vista 32bit, single CPU VM. Clean, default install and default settings.QC Entry 76775

1) Create a new Delphi forms application and drop a TButton, double klick to auto-create the OnClick handler. 2) In the event handler type some nonsense chars, ensure the last char is not a semicolon. 3) Mark the nonsense string and move the curser to the right within the _same line until some loop starts popping up code insight windows infinitely (eats a lot of CPU time, but IDE still survives). 4) While in that loop press the DEL key. 5) Move the curser to another line to stop the loop. If you do not see strange looking characters in the editor yet just undo last change by using the shortcut keys. A lot of garbage should become visible. Try to delete the garbage and the IDE should crash sooner or later. Vista 32bit, single CPU VM. Clean, default install and default settings.

QC #: 76776 - Status: Closed

QC #: Project Date Reported: Area: 76776 Delphi 8/17/2009 Database\DataSnap\Server Description Steps:[QC Short Description] DataSnap WebBroker applications don't run [QC Description] DataSnap WebBroker projects created with the new project wizard do not run, but throw an exception stating that an application can only have one data module. QC Entry 76776

1. Click File->New->Other 2. Select DataSnap Server 3. Double-click on DataSnap WebBroker application. 4. Select CGI, and click OK 5. Hit Run Expected: Application to run, show default handler content, and exit. Actual: Application starts and throws the following exception: First chance exception at $7C812AEB. Exception class Exception with message 'Only one data module per application'. Process Project1.exe (4216)

QC #: 76780 - Status: Closed

QC #: Project Date Reported: Area: 76780 Delphi 8/17/2009 IDE\Tool Palette Description Steps:[QC Short Description] Indy Component Icons missing [QC Description] Some of Indy components are missing icons: - Indy SASL - missing all - Indy Misc - missing some - Indy Intercept - missing some - Indy I/O Handlers - missing one - Indy Servers - missing some - Indy Clients - missing one QC Entry 76780

Check Indy component Tool Palette and also in the Component Toolbar.

QC #: 76785 - Status: Closed

QC #: Project Date Reported: Area: 76785 Delphi 8/17/2009 Database\DataSnap\Server Description Steps:[QC Short Description] HTTP PUT command does not work in DataSnap REST [QC Description] The HTTP PUT command does not work in the DataSnap REST support, because the PostStream is not returned to the beginning of the stream before the byte content is read. QC Entry 76785

DataSnapHTTP.Native.DB.Test.exe connection=dsconnection -s:TestRaid_272545 -or- 1. Extract the attached project into a location. 2. Open the project in Delphi 2010. 3. Run the application. 4. Click the button. Expected: Nothing visible to happen, but the request to be processed internally. Actual: The applications throws the following exception: First chance exception at $7C812AEB. Exception class TDSServiceException with message 'Message content is not a valid JSON value.'. Process Project1.exe (204)

QC #: 76794 - Status: Closed

QC #:

Project Date Reported: Area:

76794 Delphi 8/18/2009 IDE Description Steps: [QC Short Description] AVs at shutdown - fatal for 3rd party addins [QC Description] I'm getting serious AVs at shutdown in several cases. A long story: I first noticed that in some cases ModelMaker Code Explorer (MMX) caused AVs at shutdown. Running this ide add-in in the in the debugger showed all kind of errors (object instance not set to a ref) followed by crashed, but all outside the MMX code. Then after a

Steps: 1 Run BDS in debugger. 2 Open large project, not previously openend in BDS. "Large" just gives you time you: 3 shut down after showing the .dpr 4 before the IDE completes bk-gnd analyzing the units in this project: 5 shut down. => AV #1 --------------------------- Debugger Exception Notification --------------------------- Project bds.exe raised exception class EOleException with message 'Object reference not set to an instance of an object'. --------------------------- Break Continue Help --------------------------- :7c812a5b kernel32.RaiseException + 0x52 :515b6315 ; c:\program files\embarcadero\rad studio\7.0\bin\exceptiondiag140.bpl :21e22511 ; c:\program files\embarcadero\rad studio\7.0\Bin\delphierrorinsite140.bpl :2092e545 ; C:\Program Files\Embarcadero\RAD Studio\7.0\bin\coreide140.bpl :2092dee7 ; C:\Program Files\Embarcadero\RAD Studio\7.0\bin\coreide140.bpl :20733211 ; C:\Program Files\Embarcadero\RAD Studio\7.0\bin\coreide140.bpl :50073681 ThreadProc + $45 :5000b976 ThreadWrapper + $2A :7c80b683 ; C:\WINDOWS\system32\kernel32.dll #2 --------------------------- Debugger Exception Notification --------------------------- Project bds.exe raised exception class EListError with message 'List index out of bounds (0)'. --------------------------- Break Continue Help --------------------------- :7c812a5b kernel32.RaiseException + 0x52 :515b6315 ; c:\program files\embarcadero\rad studio\7.0\bin\exceptiondiag140.bpl :50063ec6 TList.Get + $1A :50063ec6 TList.Get + $1A :221d8455 ; c:\program files\embarcadero\rad studio\7.0\Bin\dotnetcoreide140.bpl :77e79dc9 RPCRT4.CheckVerificationTrailer + 0x75 :77ef321a ; C:\WINDOWS\system32\RPCRT4.dll :77ef4f4a RPCRT4.NdrProxyErrorHandler + 0xa4 :771366b4 ; C:\WINDOWS\system32\oleaut32.dll :77600c31 ; C:\WINDOWS\system32\ole32.dll :77600bdb ; C:\WINDOWS\system32\ole32.dll :7750f237 ; C:\WINDOWS\system32\ole32.dll :7750f15c ; C:\WINDOWS\system32\ole32.dll :7750fc79 ; C:\WINDOWS\system32\ole32.dll :77600e3b ; C:\WINDOWS\system32\ole32.dll :776009bc ; C:\WINDOWS\system32\ole32.dll :77600df2 ; C:\WINDOWS\system32\ole32.dll :7750fcb3 ; C:\WINDOWS\system32\ole32.dll :7750fae9 ; C:\WINDOWS\system32\ole32.dll :77d48734 USER32.GetDC + 0x6d :77d48816 ; C:\WINDOWS\system32\USER32.dll :77d489cd ; C:\WINDOWS\system32\USER32.dll :77d48a10 USER32.DispatchMessageW + 0xf :77512c02 ; C:\WINDOWS\system32\ole32.dll :77512761 ; C:\WINDOWS\system32\ole32.dll :77557227 ole32.CoWaitForMultipleHandles + 0xe6 :5007b76f CoWaitForMultipleHandles + $2B :5007b814 THandleObject.WaitFor + $20 :07875bb5 :0269ad49 :078797a5 :0787976b :79f68c4e ; c:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\mscorwks.dll :79f68d5b ; c:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\mscorwks.dll :79f68ec4 ; c:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\mscorwks.dll :0269a29a :221d8215 ; c:\program files\embarcadero\rad studio\7.0\Bin\dotnetcoreide140.bpl :221da14d ; c:\program files\embarcadero\rad studio\7.0\Bin\dotnetcoreide140.bpl :208cd698 coreide140.@Docmodul@TCodeIDocModule@NotifyDestroyed$qqr45System@%DelphiInterface$t17System@IInterface%t1 + 0x58 :20d8cda8 ForEach + $60 :208cd5fb coreide140.@Docmodul@TCodeIDocModule@NotifyDestruction$qqrv + 0x13 :20805c40 ; C:\Program Files\Embarcadero\RAD Studio\7.0\bin\coreide140.bpl :218a8bf2

while the AVs went away! and I could shutdown repeatedly without problem. I tired to open a different project in the IDE being debugged and voila: AVs again. Next step: I ran bds.exe in the debugger by defining it as host app for the MMX addin dll project without actually loading the add-in dll (temp unregistered it). And yes: AVs at shutdown - as long as the project opened in the IDE is relatively "new". Once the opened project is "known" I can shutdown OK. Doing the same thing outside the debugger does not show any noticable error msgs. So why is this a shopwstopper? Because these (invisible) AVs can cause 3rd party addins to crash afterwards which in that case does show error msgs. Another hint: something inside the IDE makes the "known" state persistent: once the problem is gone I can consistently restart / shutdown without AVs The stack traces point at some thread still running at shutdown causing the AV. Probably the thread collection the "persistent state" ? Below are

delphicoreide140.@Basedelphiproject@TBaseDelphiProject@BeforeDestruction$qqrv + 0x2a :50009d73 TObject.Free + $B :5000a45c @BeforeDestruction + $C :0042025e ; C:\Program Files\Embarcadero\RAD Studio\7.0\bin\bds.exe :502c392f TCustomForm.CloseQuery + $5B :5029a6c5 TWinControl.WndProc + $56D :502bf591 TCustomForm.WndProc + $599 :50299d63 TWinControl.MainWndProc + $2F :50076362 StdWndProc + $16 :77d48734 USER32.GetDC + 0x6d :77d48816 ; C:\WINDOWS\system32\USER32.dll :77d4b4c0 ; C:\WINDOWS\system32\USER32.dll :77d4b50c ; C:\WINDOWS\system32\USER32.dll :7c90eae3 ntdll.KiUserCallbackDispatcher + 0x13 :77d4b3f9 USER32.DefWindowProcW + 0xbd :5ad73c20 ; C:\WINDOWS\system32\uxtheme.dll :5ad8e300 ; C:\WINDOWS\system32\uxtheme.dll :5ad71ac7 ; C:\WINDOWS\system32\uxtheme.dll :5ad71b3d ; C:\WINDOWS\system32\uxtheme.dll :77d4bb15 USER32.GetPropW + 0x3a :77d48734 USER32.GetDC + 0x6d :77d48816 ; C:\WINDOWS\system32\USER32.dll :77d4c63f USER32.IsWindowUnicode + 0xa1 :77d4c665 USER32.CallWindowProcW + 0x1b :5029a7c5 TWinControl.DefaultHandler + $DD :502c28d6 TCustomForm.WMSysCommand + $5A :20833be3 coreide140.@Mainworkfrm@TMainWorkForm@WMSysCommand$qqrr22Messages@TWMSysCommand + 0x17 :5029a6c5 TWinControl.WndProc + $56D :502bf591 TCustomForm.WndProc + $599 :50299d63 TWinControl.MainWndProc + $2F :50076362 StdWndProc + $16 :77d48734 USER32.GetDC + 0x6d :77d48816 ; C:\WINDOWS\system32\USER32.dll :77d4b4c0 ; C:\WINDOWS\system32\USER32.dll :77d4b50c ; C:\WINDOWS\system32\USER32.dll :7c90eae3 ntdll.KiUserCallbackDispatcher + 0x13 :77d4b903 USER32.SendMessageW + 0x49 :5ad9881f ; C:\WINDOWS\system32\uxtheme.dll :5ad71ac7 ; C:\WINDOWS\system32\uxtheme.dll :5ad71b3d ; C:\WINDOWS\system32\uxtheme.dll :77d4bb15 USER32.GetPropW + 0x3a :77d48734 USER32.GetDC + 0x6d :77d48816 ; C:\WINDOWS\system32\USER32.dll :77d4c63f USER32.IsWindowUnicode + 0xa1 :77d4c665 USER32.CallWindowProcW + 0x1b :5029a7c5 TWinControl.DefaultHandler + $DD :5029a6c5 TWinControl.WndProc + $56D :502bf591 TCustomForm.WndProc + $599 :50299d63 TWinControl.MainWndProc + $2F :50076362 StdWndProc + $16 :77d48734 USER32.GetDC + 0x6d :77d48816 ; C:\WINDOWS\system32\USER32.dll :77d489cd ; C:\WINDOWS\system32\USER32.dll :77d48a10 USER32.DispatchMessageW + 0xf #3 :7c812a5b kernel32.RaiseException + 0x52 :515b6315 ; c:\program files\embarcadero\rad studio\7.0\bin\exceptiondiag140.bpl :21e2249d ; c:\program files\embarcadero\rad studio\7.0\Bin\delphierrorinsite140.bpl :2092e545 ; C:\Program Files\Embarcadero\RAD Studio\7.0\bin\coreide140.bpl :2092dee7 ; C:\Program Files\Embarcadero\RAD Studio\7.0\bin\coreide140.bpl :20733211 ; C:\Program Files\Embarcadero\RAD Studio\7.0\bin\coreide140.bpl :50073681 ThreadProc + $45 :5000b976 ThreadWrapper + $2A :7c80b683 ; C:\WINDOWS\system32\kernel32.dll #4 :7c812a5b kernel32.RaiseException + 0x52 :515b6315 ; c:\program files\embarcadero\rad studio\7.0\bin\exceptiondiag140.bpl :50063ec6 TList.Get + $1A :50063ec6 TList.Get + $1A :221d8455 ; c:\program files\embarcadero\rad studio\7.0\Bin\dotnetcoreide140.bpl :77e79dc9 RPCRT4.CheckVerificationTrailer + 0x75 :77ef321a ; C:\WINDOWS\system32\RPCRT4.dll :77ef4f4a RPCRT4.NdrProxyErrorHandler + 0xa4 :771366b4 ; C:\WINDOWS\system32\oleaut32.dll :77600c31 ; C:\WINDOWS\system32\ole32.dll :77600bdb ; C:\WINDOWS\system32\ole32.dll :7750f237 ; C:\WINDOWS\system32\ole32.dll :7750f15c ; C:\WINDOWS\system32\ole32.dll :7750fc79 ; C:\WINDOWS\system32\ole32.dll :77600e3b ; C:\WINDOWS\system32\ole32.dll :776009bc ; C:\WINDOWS\system32\ole32.dll :77600df2 ; C:\WINDOWS\system32\ole32.dll :7750fcb3 ; C:\WINDOWS\system32\ole32.dll :7750fae9 ; C:\WINDOWS\system32\ole32.dll :77d48734 USER32.GetDC + 0x6d :77d48816 ; C:\WINDOWS\system32\USER32.dll :77d489cd ; C:\WINDOWS\system32\USER32.dll :77d48a10 USER32.DispatchMessageW + 0xf :77512c02 ; C:\WINDOWS\system32\ole32.dll :77512bd2 ; C:\WINDOWS\system32\ole32.dll :77512b76 ; C:\WINDOWS\system32\ole32.dll :77512b33 ; C:\WINDOWS\system32\ole32.dll :77557227 ole32.CoWaitForMultipleHandles + 0xe6 :5007b76f CoWaitForMultipleHandles + $2B :5007b814 THandleObject.WaitFor + $20 :07875bb5 :0269ad49 :078797a5 :0787976b :79f68c4e ; c:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\mscorwks.dll :79f68d5b ; c:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\mscorwks.dll :79f68ec4 ; c:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\mscorwks.dll :0269a29a :221d8215 ; c:\program files\embarcadero\rad studio\7.0\Bin\dotnetcoreide140.bpl :221da14d ; c:\program files\embarcadero\rad studio\7.0\Bin\dotnetcoreide140.bpl :208cd698 coreide140.@Docmodul@TCodeIDocModule@NotifyDestroyed$qqr45System@%DelphiInterface$t17System@IInterface%t1 + 0x58 :20d8cda8 ForEach + $60 :208cd5fb coreide140.@Docmodul@TCodeIDocModule@NotifyDestruction$qqrv + 0x13 :20805c40 ; C:\Program Files\Embarcadero\RAD Studio\7.0\bin\coreide140.bpl :218a8bf2 delphicoreide140.@Basedelphiproject@TBaseDelphiProject@BeforeDestruction$qqrv + 0x2a :50009d73 TObject.Free + $B :5000a45c @BeforeDestruction + $C :0042025e ; C:\Program Files\Embarcadero\RAD Studio\7.0\bin\bds.exe :502c392f TCustomForm.CloseQuery + $5B :5029a6c5 TWinControl.WndProc + $56D :502bf591 TCustomForm.WndProc + $599 :50299d63 TWinControl.MainWndProc + $2F :50076362 StdWndProc + $16 :77d48734 USER32.GetDC + 0x6d :77d48816 ; C:\WINDOWS\system32\USER32.dll :77d4b4c0 ; C:\WINDOWS\system32\USER32.dll :77d4b50c ; C:\WINDOWS\system32\USER32.dll :7c90eae3 ntdll.KiUserCallbackDispatcher + 0x13 :77d4b3f9 USER32.DefWindowProcW + 0xbd :5ad73c20 ; C:\WINDOWS\system32\uxtheme.dll :5ad8e300 ; C:\WINDOWS\system32\uxtheme.dll :5ad71ac7 ; C:\WINDOWS\system32\uxtheme.dll :5ad71b3d ; C:\WINDOWS\system32\uxtheme.dll :77d4bb15 USER32.GetPropW + 0x3a :77d48734 USER32.GetDC + 0x6d :77d48816 ; C:\WINDOWS\system32\USER32.dll :77d4c63f USER32.IsWindowUnicode + 0xa1 :77d4c665 USER32.CallWindowProcW + 0x1b :5029a7c5 TWinControl.DefaultHandler + $DD :502c28d6 TCustomForm.WMSysCommand + $5A :20833be3 coreide140.@Mainworkfrm@TMainWorkForm@WMSysCommand$qqrr22Messages@TWMSysCommand + 0x17 :5029a6c5 TWinControl.WndProc + $56D :502bf591 TCustomForm.WndProc + $599 :50299d63 TWinControl.MainWndProc + $2F :50076362 StdWndProc + $16 :77d48734 USER32.GetDC + 0x6d :77d48816 ; C:\WINDOWS\system32\USER32.dll :77d4b4c0 ; C:\WINDOWS\system32\USER32.dll :77d4b50c ; C:\WINDOWS\system32\USER32.dll :7c90eae3 ntdll.KiUserCallbackDispatcher + 0x13 :77d4b903 USER32.SendMessageW + 0x49 :5ad9881f ; C:\WINDOWS\system32\uxtheme.dll :5ad71ac7 ; C:\WINDOWS\system32\uxtheme.dll :5ad71b3d ; C:\WINDOWS\system32\uxtheme.dll :77d4bb15 USER32.GetPropW + 0x3a :77d48734 USER32.GetDC + 0x6d :77d48816 ; C:\WINDOWS\system32\USER32.dll :77d4c63f USER32.IsWindowUnicode + 0xa1 :77d4c665 USER32.CallWindowProcW + 0x1b :5029a7c5 TWinControl.DefaultHandler + $DD :5029a6c5 TWinControl.WndProc + $56D :502bf591 TCustomForm.WndProc + $599

several errors for "clean" IDEs at shut-down QC Entry 76794

:50299d63 TWinControl.MainWndProc + $2F :50076362 StdWndProc + $16 :77d48734 USER32.GetDC + 0x6d :77d48816 ; C:\WINDOWS\system32\USER32.dll :77d489cd ; C:\WINDOWS\system32\USER32.dll :77d48a10 USER32.DispatchMessageW + 0xf

QC #: 76812 - Status: Closed

QC #: Project Date Reported: Area: 76812 Delphi 8/18/2009 IDE\Toolbars\Component Description Steps:[QC Short Description] Component ToolBar duplicate "DataSnap Client" [QC Description] Component ToolBar have 2 items "DataSnap Client" 1- "Datasnap Client" with all items 2 - "DataSnap Cliente" Empty QC Entry 76812

QC #: 76814 - Status: Closed

QC #: Project Date Reported: Area: 76814 Delphi 8/18/2009 IDE\Code Editor\Error Insight

Description Steps:[QC Short Description] Generics T property methods are unknown [QC Description] Generics T property methods are unknown -> see steps This is from the thread "D2009 Still Broken" in .public.delphi.non-technical message + childs https://forums.embarcadero.com/thread.jspa?messageID=148858&tstart=0#148858Message-ID: <[email protected]> QC Entry 76814 See also 272043

- save the attached files or use the following two files at the end of the steps - start Delphi - open EIFindShapeInlinedGenerics.dpr expected: no Error Insight errors in the Structure view actual: 'TObjectList`1' does not contain a member named 'FindShapeAt' at line 34 (34:16) - open EIFindShape.dpr expected: no Error Insight errors in the Structure view actual: Undeclared identifier 'FindShapeAt' at line 23 (23:22) 'TObjectList`1' does not contain a member named 'FindShapeAt' at line 24 (24:16) //--- EIFindShapeInlinedGenerics.dpr --- program EIFindShapeInlinedGenerics; {$APPTYPE CONSOLE} type TObjectList<T> = class(TObject) private function GetItems(AIndex: Integer): T; public property Items[AIndex: Integer]: T read GetItems; default; end; function TObjectList<T>.GetItems(AIndex: Integer): T; begin Result := Default(T); end; type TShape = class public function FindShapeAt(X, Y: Integer): TShape; end; function TShape.FindShapeAt(X, Y: Integer): TShape; begin Result := nil; end; var ShapeList: TObjectList<TShape>; begin ShapeList := TObjectList<TShape>.Create; ShapeList.Items[0].FindShapeAt(0,0); ShapeList[0].FindShapeAt(0,0); end. //--- EIFindShape.dpr --- program EIFindShape; {$APPTYPE CONSOLE} uses Generics.Collections; type TShape = class public function FindShapeAt(X, Y: Integer): TShape; end; function TShape.FindShapeAt(X, Y: Integer): TShape; begin Result := nil; end; var ShapeList: TObjectList<TShape>; begin ShapeList := TObjectList<TShape>.Create; ShapeList.Items[0].FindShapeAt(0,0); ShapeList[0].FindShapeAt(0,0); end.

QC #: 76842 - Status: Closed

QC #: Project Date Reported: Area: 76842 Delphi 8/19/2009 ActiveX Description Steps:[QC Short Description] Registration of Automation-Interfaces fails on Windows 7 [QC Description] If Application is installed unter C:\Program Files, the code in ComServ.pas, methode TComServer.Initialize fails. Windows 7 will raise in this case a EOleRegistrationError with ErrorCode = 0. On Vista/XP it will raise a EOleSysError with ErrorCode = TYPE_E_REGISTRYACCESS QC Entry 76842

Create Application with Automation Interface, install it to C:\Program Files and start it with active UAC unter Windows 7

QC #: 76849 - Status: Closed

QC #: Project Date Reported: Area: 76849 Delphi 8/19/2009 Internet\CGI Application Description Steps:[QC Short Description] Raw POST data not available in TWebRequest [QC Description] When a POST request is set to a WebBroker-based CGI application, the raw submitted content is not present in the TWebRequest.RawContent property. The data is available at the ContentFields property. QC Entry 76849

1. Extract the attached project. 2. Open and build the project. 3. Configure IIS to execute the project as a CGI application 4. Using a web browser, navigate to the CGI application. 5. Click the Submit button on the shown form. Expected: The form to be submitted, and the submitted data to be shown next to the Raw data submitted label. Actual: The form submits, but the data only shows at the Parsed data submitted section.

QC #: 76861 - Status: Closed

QC #: Project Date Reported: Area:76861 Delphi 8/19/2009 IDE\Code Editor\Formatting Description Steps:[QC Short Description] RAD Studio 2010: "Format source" moved all bookmarks [QC Description] All bookmarks are moved in the last line of unit http://img443.imageshack.us/img443/4311/13961015.png QC Entry 76861

1) Create one (or more) bookmark in the unit 2) 'Format source'; 3) All bookmarks are moved in the last line of unit http://img443.imageshack.us/img443/4311/13961015.png fixed: trunk - rev,24557-24559, branch - rev.24560-24562

QC #: 76862 - Status: Closed

QC #: Project Date Reported: Area: 76862 Delphi 8/19/2009 IDE Description Steps:[QC Short Description] Gridlines for alignment of components don't account for non client areas of container components. [QC Description]

1) Put TCategoryPanelGroup on Form 2) Create new CategoryPanel 3) Put two buttons on CategoryPanel 4) Press down left mouse-button on one of this buttons and see http://img90.imageshack.us/img90/9999/31005543.png For comparison: http://img170.imageshack.us/img170/4613/31456407.png

Lines for alignment components in IDE are drawn incorrectly http://img90.imageshack.us/img90/9999/31005543.png QC Entry 76862 trunk rev: 24853 update rev: 24855

QC #: 76866 - Status: Closed

QC #: Project Date Reported: Area: 76866 C++Builder 8/19/2009 IDE\Project Management Description Steps:[QC Short Description] Bogus missing package prompt [QC Description] What I have in my project group is one main project that depends on several run-time packages (and some DLL projects), which are all in the same project group. All is fine when I have the corresponding bpi files for the main project. However, when I do a clean of all the projects, the next time I try to rebuild all projects, the IDE will prompt me for the location of the missing packages. This is simply incorrect - the reason I'm hitting rebuild all is so that I'd be able to rebuild the packages which can then be used by the main project. If I ignore the prompt by canceling through the dialogs (a lot of them), I can get everything to build except the main project. The IDE must have taken it out of the list even though I hit cancel. I had to close the project and reopen for the IDE to reset its state. Then do another build. CB2007 did not exhibit this problem at all. So far my impression of CB2010 is that its IDE is worse than CB2007. QC Entry 76866

Open TestGroup.groupproj under Test\ folder. Change package1.bpl to a runtime only package. Activate tester.exe project. Hit Ctrl+F9. Missing package prompt shows. That's dumb, considering the reason user hit Ctrl+F9 in the first place is so that they could build the package which the IDE complains is missing!

QC #: 76879 - Status: Closed

QC #: Project Date Reported: Area: 76879 C++Builder 8/20/2009 Compiler\C++\Back End Description Steps:[QC Short Description] BCC doesn't correctly emit the updated type info [QC Description] The type info structures in TypInfo.pas have been updated to support the new RTTI features, primarily attributes. Look at the following diff of TTypeData from Tiburon to Weaver: // ----- TTypeData = packed record case TTypeKind of ... tkClass: ( ClassType: TClass; // most data for instance types is in VMT offsets ParentInfo: PPTypeInfo; PropCount: SmallInt; // total properties inc. ancestors

- Download the attached sample project, compile it (bcc32 -WCV qc76879.cpp) and run it. Expected output: // ----- Testing TObject... PASS Testing TStringList... PASS Testing TComponent... PASS Testing TInterfacedObject... PASS Testing TCppObject... PASS Testing TCppStringList... PASS Testing TCppComponent... PASS Testing TCppInterfacedObject... PASS // ----- Actual output (message language may differ depending on locale and setup): // ----- Testing TObject... PASS Testing TStringList... PASS Testing TComponent... PASS Testing TInterfacedObject... PASS Testing TCppObject... FAIL EAccessViolation: Zugriffsverletzung bei Adresse 0040166C in Modul 'qc.exe'. L esen von Adresse 0050AC36 Testing TCppStringList... FAIL EAccessViolation: Zugriffsverletzung bei Adresse 0040166C in Modul 'qc.exe'. L esen von Adresse 004FC5CF Testing TCppComponent... FAIL EAccessViolation: Zugriffsverletzung bei Adresse 0040166C in Modul 'qc.exe'. L esen von Adresse 004FB8AE

UnitName: ShortStringBase; - {PropData: TPropData}); + {PropData: TPropData; + PropDataEx: TPropDataEx; + ClassAttrData: TAttrData;}); ... end; // ----- However, BCC doesn't emit the new type info fields, primarily the PropDataEx and ClassAttrData fields. It is understandable that BCC doesn't fully support the new RTTI features such as attributes right now, but it should at least zero out the new fields - right now the type info generated by BCC is simply wrong, and all code that tries to read in all type info fields simply crashes. To demonstrate the failure, I've attached a test case that simply reads out and skips above fields. It works fine for DCC-built type info but, as expected, it runs into AVs when consuming BCC-generated type info. In addition, once QC's #76875 and #76877 are fixed, I think Rtti.pas will form another good test case for this problem. QC Entry 76879

Testing TCppInterfacedObject... FAIL EAccessViolation: Zugriffsverletzung bei Adresse 0040166C in Modul 'qc.exe'. L esen von Adresse 004FB000 // -----

QC #: 76882 - Status: Closed

QC #: Project Date Reported: Area: 76882 C++Builder 8/20/2009 IDE\Build Tools Description Steps:[QC Short Description] C++Builder application shouldn't start when compilation error occurs in Delphi code [QC Description] See steps. QC Entry 76882

- Create a new C++ application with VCL support - Add a Delphi unit - Change the Delphi unit so that compilation will fail with a syntax error - Hit F9 (Run) Exp.: Error is printed, editor gets focus at first error Act.: Error is printed, application is started anyway

QC #: 76883 - Status: Closed

QC #: Project Date Reported: Area:76883 C++Builder 8/20/2009 Compiler\Delphi\Header Generation

Description Steps:[QC Short Description] SysUtils.TUncertainState declaration isn't translated to C++ correctly [QC Description] For some reason, the declaration of the TUncertainState enum in SysUtils isn't represented correctly in SysUtils.hpp. TUncertainState is declared with $SCOPEDENUMS ON, which usually results in "enum class" declarations instead of plain "enum" declarations. This is also what happens if SysUtils is compiled manually (DCC32 -JPHN SysUtils.pas), but the header supplied with build 3513 contains "enum TUncertainState". The problem itself isn't really noteworthy, but I think the cause might be worth investigating. QC Entry 76883

Open SysUtils.hpp, search the declaration of TUncertainState. Exp.: // ----- enum class TUncertainState { Maybe, Yes, No }; // ----- Act.: // ----- enum TUncertainState { Maybe, Yes, No }; // ----- [NOTE: See my comments in the resolution: It's related to -JPHNE vs. -JL. The latter seems to treat enums always as unscoped when emitting .hpp files :(

QC #: 76894 - Status: Closed

QC #: Project Date Reported: Area:

76894 Delphi 8/21/2009 RTL\Delphi\Other Classes\TStreamReader/TStreamWriter

Description Steps:(JJS: Not yet delivered in 14.0.3559.24962) [QC Short Description] TStreamReader(Helper).DetectBOM will never default to UTF8 [QC Description] DetectBOM will never default to UTF-8 when no BOM is detected. Code taken from Classes.pas function TStreamReaderHelper.DetectBOM(var Encoding: TEncoding; Buffer: TBytes): Integer; var LEncoding: TEncoding; begin LEncoding := nil; Result := TEncoding.GetBufferEncoding(Buffer, LEncoding); if LEncoding <> nil then Encoding := LEncoding else if (LEncoding = TEncoding.Default) and (Encoding <> TEncoding.Default) then Encoding := TEncoding.UTF8; FDetectBOM := False; end; It would seem to me that in the else branch, the first condition of the if will never be true (LEncoding=nil there and can thus never be TEncoding.Default) and therefore the Encoding will never default to UTF8... Code in D2010 is in TStreamReader itself, but otherwise unchanged. Suggested code: function TStreamReaderHelper.DetectBOM(var Encoding: TEncoding; Buffer: TBytes): Integer; var LEncoding: TEncoding; begin LEncoding := nil; Result := TEncoding.GetBufferEncoding(Buffer, LEncoding); if LEncoding <> nil then begin if (LEncoding = TEncoding.Default) and (Encoding <> TEncoding.Default) then // If no BOM detected default to UTF-8 Encoding := TEncoding.UTF8 else Encoding := LEncoding; end else ;// Leaving Encoding parameter alone FDetectBOM := False; end; QC Entry 76894

Compile and run the attached application below. See the following program output indicating failure. FAIL #1 - RetVal=TMBCSEncoding FAIL #2 - RetVal=TMBCSEncoding FAIL - Counter=0 program BTS272593; {$APPTYPE CONSOLE} uses Classes, SysUtils; var Counter: Integer = 0; procedure DoTest; var Reader: TStreamReader; RetVal: String; begin { Specifying DetectBOM on a BOM-less file } Reader := TStreamReader.Create('BTS272593.txt', True); //True=DetectBOM// try Reader.ReadLine; RetVal := Reader.CurrentEncoding.ClassName; if RetVal = 'TUTF8Encoding' then Inc(Counter) else WriteLn('FAIL #1 - RetVal=', RetVal); finally Reader.Free; end; { Specifying DetectBOM on a BOM-less file and supply the UTF8 encoding } Reader := TStreamReader.Create('BTS272593.txt', TEncoding.UTF8, True); try Reader.ReadLine; RetVal := Reader.CurrentEncoding.ClassName; if RetVal = 'TUTF8Encoding' then Inc(Counter) else WriteLn('FAIL #2 - RetVal=', RetVal); finally Reader.Free; end; if Counter = 2 then WriteLn('PASS') else WriteLn('FAIL - Counter=', Counter); end; begin try DoTest; except on E: Exception do begin

WriteLn('FAIL - Exception Error'); WriteLn(' ClassName=', E.ClassName); WriteLn(' Message=', E.Message); end; end; end.

QC #: 76972 - Status: Closed

QC #: Project Date Reported: Area: 76972 C++Builder 8/25/2009 IDE\File Handling Description Steps:[QC Short Description] IDE fails to create form if TAnimate->Filename is invalid [QC Description] If a form has a TAnimate control with it's filename property set to a non-existent file and Active set true, then the IDE fails to create the form when the unit is loaded. For me this occurred when I tried to move the project to a new machine and the filename specified contained an invalid path. Because the form is not created there is no way to fix the error and no access to the form's history so that a revert can be done. I had to exit the IDE and manually revert all the unit files to a date prior to the inclusion of the filename. I'd suggest that the IDE flags the error to the user and then sets the Active property to false so that at least the form is accessible and can be fixed. QC Entry 76972

Create a new VCL forms application Drop a TAnimate on the form Point the filename to an existing .AVI file. Set Active to true. Save and close the project. Delete the .AVI file Open the project. Dialog says "Error creating form: Cannot open AVI. Code and header pages open but form doesn't. Cannot fix problem since object inspector is empty

QC #: 76979 - Status: Closed

QC #: Project Date Reported: Area:76979 Delphi 8/25/2009 IDE\Code Editor\Formatting Description Steps:[QC Short Description] Problem with code formater with "try..except" QC Entry 76979

1. Create new VCL application 2. Double-click on form 3. insert folowwing code: ----------------------------- try except on E: Exception do end; ----------------------------- 4. press Ctrl-D 5. "end" keyword should be on the same line as "try" keyword. ----------------------------- begin try except on E: Exception do end; end; -----------------------------

QC #: 77012 - Status: Closed

QC #: Project Date Reported: Area: 77012 Delphi 8/25/2009 Midas\TClientDataSet Description Steps:[QC Short Description] ClientDataSet [QC Description] TWideStringField's CustomConstraint is malfunction QC Entry 77012 Added by Sysop

1.Add ClientDataSet to Exists Form and Add all fields 2.choose a field(TWideStringField), set CustomConstraint and the message 3.Run and open dataset 4.modify detail, no meesage at the field when input faild.

<<<<<<<<<<<<<< This issue is similar to RAID#275904(QC#83795) The line following line overwrites the expression data because the casting to PChar is not done. StrLCopy(@FBuffer[SizeOf(TSQLExprInfo)], PChar(ErrorStr), Length(FBuffer) - SizeOf(TSQLExprInfo) - 1); Change this line to StrLCopy(@FBuffer[SizeOf(TSQLExprInfo)], PAnsiChar(MetaDataFromUnicode(ErrorStr)), Len); and the correct error message is shown. >>>>>>>>>>>>>>

QC #: 77062 - Status: Closed

QC #: Project Date Reported: Area: 77062 Delphi 8/26/2009 IDE Description Steps:[QC Short Description] Options dialog looks badly if Large Fonts installed [QC Description] I have Large fonts on my WindowXP (120 dpi). When I start Delphi 2010 Trial and open Options dialog it looks as it does not designed to care of Large system fonts. QC Entry 77062

0) Install Window XP 1) Go to display options and select Large fonts, reboot if needed. 2) Install Delphi 2010 3) Start Delphi 2010 go to main menu: Tools -> Options This problem most noticeable at: 1) Environment options 2) Tool palette 3) VCL Designer

QC #: 77100 - Status: Closed

QC #: Project Date Reported: Area:77100 Delphi 8/27/2009 VCL\Standard Controls\TComboBox

Description Steps:[QC Short Description] TComboBox position uncontrollable when BevelKind != bkNone [QC Description] The position (Top, Left) or size (Width) of TComboBox are uncontrollable in a strange way if you change BevelKind to values other than bkNone. QC Entry 77100 trunk rev: 24782 update rev: 24785

Place TComboBox on a form. Then, change the BevelKind to bkFlat. You will see its position or size are being changed wrongly (every time you select the combobox).

QC #: 77118 - Status: Closed

QC #: Project Date Reported: Area:77118 Delphi 8/28/2009 IDE\Code Editor\Formatting Description Steps:[QC Short Description] Formatter confused by subrange type definition [QC Description] Code to be formatted:

See Description [vk] Fixed in the trunk rev.24448. Fixed in brunch - rev.24450

program Project1; {$APPTYPE CONSOLE} uses SysUtils; type { subrange type } TSub = -1..1; TFoo = class private FSub1: TSub; FSub2: TSub; end; begin end. Result: program Project1; {$APPTYPE CONSOLE} uses SysUtils; type { subrange type } TSub = -1 .. 1; TFoo = class private FSub1: TSub; FSub2 : TSub; end; begin end. QC Entry 77118

QC #: 77121 - Status: Closed

QC #: Project Date Reported: Area: 77121 Delphi 8/28/2009 Compiler\Delphi\Generics Description Steps:[QC Short Description] Internal Error: I12307 w/ Generic Descendants in Separate Units and {$INLINE AUTO} [QC Description] The attached project demonstrates the error. The setup: Unit2 contains TBar, a non-Generic descendant from TObjectList<T>. (TObjectList<TObject> in particular) type TBar = class(TObjectList<TObject>); Unit1 uses Unit2 and attempts to create an instance of TBar in Button2's OnClick handler. var Bar: TBar; begin {$INLINE AUTO}

Attempt to compile the attached project. Steps by USc: - save the following three files - dcc32 --inline:auto GenericsCodeGenTest.dpr expected: compiles actual: GenericsCodeGenTest.dpr(9) Error: E2010 Incompatible types: 'TObjectList<System.TObject>' and 'Class reference' GenericsCodeGenTest.dpr(11) Fatal: F2084 Internal Error: I12307 Note the E2010 error disappears if you remove the "FOwnsObjects := AOwnsObjects;" in "TObjectList<T>.Create" in Generics.Collections.Simplified.pas //--- GenericsCodeGenTest.dpr ---program GenericsCodeGenTest; {$APPTYPE CONSOLE} uses BarUnit in 'BarUnit.pas'; begin TBar.Create; WriteLn('PASS'); end. //--- BarUnit.pas --- unit BarUnit; interface uses Generics.Collections.Simplified; type TBar = class(TObjectList<TObject>); implementation end. //--- Generics.Collections.Simplified.pas --- unit Generics.Collections.Simplified; interface type TObjectList<T: class> = class(TObject) private FOwnsObjects: Boolean; public constructor Create(AOwnsObjects: Boolean = True); end; implementation constructor TObjectList<T>.Create(AOwnsObjects: Boolean); begin inherited Create; FOwnsObjects := AOwnsObjects; end; end.

Bar := TBar.Create; Bar.Free; end; Attempting to compile the project will trigger the I12307 on the Bar := TBar.Create; line. Removing (or disabling) the $INLINE AUTO directive will allow the file to compile successfully. It appars to only affect the call site itself, because setting Inline to Autoin the project options also causes the compiler error. If the class declaration is in the same unit, the error is not thrown, as can be seen by TFoo and its corresponding usage in the demo project.QC Entry 77121

QC #: 77122 - Status: Closed

QC #: Project Date Reported: Area:77122 C++Builder 8/28/2009 IDE\Project Management\Virtual Folders

Description Steps:[QC Short Description] "Show dependencies" should have indication that dependencies are already visible [QC Description] Open any C++ project. Select CPP file from project manager and right click to open pop-up menu. Select Show dependencies. As soon as dependencies become visible menu label shoud be change to "Hide dependencies" or there must be an indication that dependencies are already visble and selecting it again will hide them. QC Entry 77122

Start IDE Open Any C++ Project. Select any of the CPP files in project manager and right click on it. From Pop-Up menu select "Show dependencies" After that right click again. Exp: See Hide dependencies or there must be a selection mark Act: I see only Show dependencies without any indication that clicking again this menu item dependencies will hide.

QC #: 77126 - Status: Closed

QC #: Project Date Reported: Area: 77126 Delphi 8/28/2009 IDE\File Handling Description Steps:[QC Short Description] Problem Saving when Form is Read Only [QC Description] If you have a dfm file marked as read-only, and make a change in the IDE, then try to save, nothing happens. No error is reported. In Delphi 2007, it would report an error (show an error message box)but in Delphi 2010, no message is shown. QC Entry 77126

Create a stock VCL form project. Save the project Close the project Now, mark the .dfm file as read only Open the project in Delphi 2010 Add a button to the form Then, select Save (or save all) No error message

QC #: 77137 - Status: Closed

QC #: Project Date Reported: Area: 77137 C++Builder 8/28/2009 AddOn\IntraWeb Description Steps:[QC Short Description] Some Chinese characters can not display in C++ Builder 2010 VCL for Web project [QC Description] I used the "C++ Builder 2009 and 2010 VCL for the Web Application

- extract attached project and run it on JA VM

Wizard" to create a simple project, when I run this program I discovered that the Chinese characters "?"(unicode 540D) and "?"(unicode 4E0D) (maybe more)can not show, but these characters can be properly displayed in the IDE. I have tested this project in "Turbo C + + 2006" and "C + + Builder 6.0", but it is normal.So I think might be there is a bug in "C + + Builder 2009 and 2010" Unicode support. QC Entry 77137 Added by Sysop <<<<<<<< This fatal issue is NOT fixed with 10.0.23. With 10.0.23, we need to copy 'UTF8ContentParser.pas' from 'RAD Studio\7.0\source\Win32\websnap\' and add it to a project. >>>>>>>>

QC #: 77160 - Status: Closed

QC #: Project Date Reported: Area: 77160 Delphi 8/29/2009 Install\User Interface Description Steps:[QC Short Description] Cannot paste serial when using installer Upgrade feature [QC Description] The installer now supports copy-paste of serial numbers when performing a new install. The Product Registration screen displayed when an Upgrade is performed, however, does not permit pasting of the serial number. QC Entry 77160

1) Launch "Modify, Repair, Uninstall" from the Start menu. 2) Select the "Upgrade" radio button and press "Next" 3) Select the first cell of the "Serial Number" field and paste the serial number Expected: Serial number boxes are polpulated from the clipboard Actual: Only the first serial number box is filled

QC #: 77164 - Status: Closed

QC #: Project Date Reported: Area: 77164 Delphi 8/29/2009 IDE\Form Designer Description Steps:[QC Short Description] crash (ribbon related?) [QC Description] My first day with Delphi 2010... first tried the new Demos. Managed to repeatedly crash the IDE in "Direct2D" project. Will send the AIR after this. AIR 77165 QC Entry 77164

1. Start Delphi 2010 2. Open project ..Demos\DelphiWin32\VCLWin32\Direct2D\D2D.dproj 3. Open uMain.pas 4. Click top-left ApplicationMenu 5. While the thing is dropped, try to close the form from the [X] right corner 6. Say No when asked to save Exp: the form is closed without any troubles Act: an exception is raised and the IDE becomes unstable

QC #: 77168 - Status: Closed

QC #: Project Date Reported: Area: 77168 Delphi 8/29/2009 RTL\Delphi\WinAPI Description Steps:[QC Short Description] Named error in Windows.pas unit [QC Description]

open the Windows.pas

In the Windows.pas unit the constants names diferes from the original in C: CERT_E_VALIDITYPERIODNESTING is CERT_E_VALIDIYPERIODNESTING Thas definitions not found: TRUST_E_FAIL = HRESULT($800B010B); CERT_E_REVOKED = HRESULT($800B010C); CERT_E_UNTRUSTEDTESTROOT = HRESULT($800B010D); CERT_E_REVOCATION_FAILURE = HRESULT($800B010E); CERT_E_CN_NO_MATCH = HRESULT($800B010F); CERT_E_WRONG_USAGE = HRESULT($800B0110); QC Entry 77168

QC #: 77173 - Status: Closed

QC #: Project Date Reported: Area: 77173 C++Builder 8/29/2009 Compiler\C++ Description Steps:[QC Short Description] Incorrect constant generated for 64-bit integer when inside Delphi package class method [QC Description] When a 64-bit constant value (with no i64 suffix) is assigned to an __int64 variable a completely unrelated constant value is assigned. Added by Sysop <<<<<<<<<<< Please see Clayton-san's comment >>>>>>>>>>> QC Entry 77173

bcc32 272679.cpp 272679 exp: 0x1000000000 act: 0x10001100199779

QC #: 77183 - Status: Closed

QC #: Project Date Reported: Area: 77183 C++Builder 8/30/2009 Compiler\C++ Description Steps:[QC Short Description] Undefined symbol new when compileing Boost code [QC Description] [BCC32 Error] has_new_operator.hpp(34): E2451 Undefined symbol 'new' Occurs when using the Boosr serialization library Error occurs in line 34 of boost/type_traits/has_new_operator.hpp QC Entry 77183

1. Create a cpp file with the following line in it: #include <boost\archive\text_iarchive.hpp> 2. Compile 3. Error occurs in line 34 of boost/type_traits/has_new_operator.hpp

QC #: 77185 - Status: Closed

QC #: Project Date Reported: Area: 77185 Delphi 8/30/2009 IDE\Class Completion Description Steps:

[QC Short Description] Class Complete stops working if there is a "procedure(x: Integer) of object" field in the class [QC Description] Class Complete stops working if there is a method pointer in the class who's type is inlined. QC Entry 77185

1. Create a new unit 2. Replace the content with the following text <<<<<< unit ClassComplBug; interface type TTest = class public Event: procedure(const S: string) of object; procedure Test; end; implementation end. >>>>>> 3. Move the caret into the class declaration 4. Press Ctrl+Shift+C (Class Complete) Expected: The body for "Test" is created under implementation Actual: Expected ';' but OF found in class TTest.

QC #: 77195 - Status: Closed

QC #: Project Date Reported: Area:77195 C++Builder 8/30/2009 Documentation\IDE Help Contexts

Description Steps:[QC Short Description] Predefined macros not updated for cb2010 [QC Description] ms-help://embarcadero.rs2010/rad/Predefined_Macros.html QC Entry 77195

look for __CODEGEARC__

QC #: 77196 - Status: Closed

QC #: Project Date Reported: Area:77196 C++Builder 8/30/2009 IDE\Code Editor\Formatting Description Steps:[QC Short Description] incorrect formatting of literal number with suffix QC Entry 77196

have line similar to the following FileSeek(Handle, 0i64, soFromCurrent) format <ctrl-D> FileSeek(Handle, 0 i64, soFromCurrent) will not compile! [vk] Note: only Cpp. Case not sensitive (i8, ui8, i16, ui16, i32, ui32, i64, ui64, I8, UI8, I16, UI16, ...). i32, i64 etc are valid even for the pointed and potented numbers (1.23e-8i32). Other suffixed are valid (u, i, f, d) fixed in trunk rev.24342, 24347 synchronized in branch - rev.24348

QC #: 77221 - Status: Closed

QC #: Project Date Reported: Area:77221 C++Builder 8/31/2009 Compatibility\BCB<->Delphi Description Steps:[QC Short Description] The Rtti unit does not work with runtime packages disabled [QC Description] When "Build with runtime packages" is disabled the Rtti unit is completely useless. When enabled the Rtti unit is just very buggy. QC Entry 77221

Create a new VCL application with the following code somewhere, eg. in a button OnClick: TRttiContext LContext; TArray__1<TRttiType*> Types = LContext.GetTypes(); You also need to include Rtti.hpp at the top of the file. This works when "Build with runtime packages" is enabled and Types gets filled with a list of all types. But when runtime packages is disabled the list is empty.

[NOTE FROM BRUNEAU] ======================= This is really a request for a new feature for the C++ compiler and linker. See the attach file that describes what the C++ compiler and linker would need to do.

QC #: 77226 - Status: Closed

QC #: Project Date Reported: Area:77226 Delphi 8/31/2009 AddOn\Interbase components Description Steps:[QC Short Description] IBX Not reporting correct Interbase Error Number [QC Description] I think I have run into a bug in the latest version of IBX that came with Delphi 2010. IBX is returning a different error code under a specific situation than it used to in D2009 Basic details; I was creating a trigger, and the trigger purposely was referencing an invalid column in the database. Under D2009, IBX properly reported a -206 error (column not found error). Now under D2010 it reports 66 (Use Open for Select Statement). I think I have found the change in IBX that caused this. It may have other side effects on other IB errors as well..(not sure how bad this actually is - for me its bad though) In IBSql.pas TIBSQL.Prepare; ... if Assigned(Encoding) then bt := Encoding.GetBytes(FProcessedSQL.Text + #0) else bt := BytesOf(AnsiString(FProcessedSQL.Text) + #0); try Call(FGDSLibrary.isc_dsql_prepare(StatusVector, TRHandle, @FHandle, 0, PByte(bt), Database.SQLDialect, nil), True); except SetLength(bt, 0); end; As you can see, the call to isc_dsql_prepare, which generates the proper interbase error (-206), when it raises this exception, it gets gobbled up by the try/except which sets the length of the bt buffer to 0. I really think this should also re-raise the exception generated by isc_dsql_prepare. The older IBX code does not have this try/except, sothe interbase exception -206, makes it out to the outside callers. If I am correct here, then I have a problem that I am going to have to figure out a workaround for until a fix is made. QC Entry 77226

Create an interbase table to a database: CREATE TABLE TESTTABLE ( FIELD1 INTEGER NOT NULL, FIELD2 INTEGER NOT NULL); Now, Using IBX components, IBDatabase, IBTransaction, IBQuery, attempt to execute the following DDL query: CREATE TRIGGER TESTTRIGGER FOR TESTTABLE ACTIVE BEFORE INSERT POSITION 0 AS BEGIN IF ((NEW.SEQ IS NULL) OR (NEW.SEQ = 0)) THEN begin /* Do something dumb just for illustation*/ new.seq = 100; end; END When executing this DDL query, IBX should report a -206 column not found error. But it just generates a 66 (use Open for a Select Statement)

QC #: 77285 - Status: Closed

QC #: Project Date Reported: Area: 77285 Delphi 9/2/2009 Compiler\Delphi\Interfaces Description Steps:[QC Short Description] TComponent interface functions "redirected" to TInterfacedObject when a class helper for TComponent (descendant) exists

Steps by USc: - save the file at the end of the steps - dcc32 ClassHelperIntf.dpr - execute ClassHelperIntf.exe and see the output is "PASS" - dcc32 -DWITHCOMPONENTCLASSHELPER

[QC Description] TComponent Interface functions like _AddRef or _Release are "redirected" to TInterfacedObject when a class helper for TComponent or a TComponent descendant exists. This is regression from D2007, but it happened already in D2009. This issue can lead to unexpected behavior, because components are destroyed when the interfaces are released. -> see steps Original short description: Corrupted component interfaces Original description: I am running into a very strange bug with interfaces. Unfortunately it seems that i can only reproduce this on my product which is about 200000 lines of codes making impossible to supply a code for reproducing. I'll try to describe what happens in pseudo code bellow Type a = class(tcomponent) b = class(a, IAnyInterface) var myobject: b; implementation in my code i a getinterface call on objects eg myobject.getInterface(IAnyInterface, ivar) The problem is that in function TObject.GetInterface(const IID: TGUID; out Obj): Boolean; the statement if Pointer(Obj) <> nil then IInterface(Obj)._AddRef; Results to a call to TInterfacedObject._AddRef insteand of TComponent._AddRef. This behavior occurs only with 2010 while 2007 and 2009 work as expected. This causes the object to be freed and crash the app. My application dosen't work with d2010 while worked as expected with d2007 and d2009 QC Entry 77285

ClassHelperIntf.dpr - execute ClassHelperIntf.exe expected: output is PASS actual: output is FAIL #1 Additional test to "see" whats happening - start Delphi - open ClassHelperIntf.dpr - enable "Use debug .dcus" in the project options or compile with the RTL source - add WITHCOMPONENTCLASSHELPER as conditional define or remove the dot in line five - compile ClassHelperIntf.dpr - start the app - step through the following lines "FooComponent.GetInterface(IFooInterface, I)" "I := nil;" and see TInterfacedObject._AddRef and TInterfacedObject._Release are executed program ClassHelperIntf; {$APPTYPE CONSOLE} {.$DEFINE WITHCOMPONENTCLASSHELPER} uses Classes; type IFooInterface = interface ['{68A52E11-7139-4B66-AB44-21AF8E85B81A}'] end; TFooComponent = class(TComponent, IFooInterface) destructor Destroy; override; end; {$IFDEF WITHCOMPONENTCLASSHELPER} TBarComponentHelper = class helper for TComponent end; {$ENDIF WITHCOMPONENTCLASSHELPER} var FooComponent: TFooComponent; I: IFooInterface; ComponentAlive: Boolean; destructor TFooComponent.Destroy; begin ComponentAlive := False; inherited Destroy; end; begin FooComponent := TFooComponent.Create(nil); try if FooComponent.GetInterface(IFooInterface, I) then begin ComponentAlive := True; I := nil; if ComponentAlive then WriteLn('PASS') else WriteLn('FAIL #1'); end else WriteLn('FAIL #2'); except FooComponent.Free; end; end.

QC #: 77295 - Status: Closed

QC #: Project Date Reported: Area: 77295 Delphi 9/2/2009 Database\DataSnap Description Steps:[QC Short Description] Datasnap 2010 not handling blob fields correctly QC Entry 77295

DataSnapDM.native.db.test.exe connection=mssqlconnection -s:TestRaid_272727 -or- 1) Create a Datasnap server with a connection to a MSSQL database 2) Expose the TDBXConnection to the client (e.g. ServerConnection=TServerMethods3.GetConnection in the parameters) 3) Create a client application that has a TSQLQuery that passes the SQL to the server 4) Create a SQL SELECT statement that returns two blob fields e.g. SELECT blob1, blob2 from Table1 Test the size of the fields like this: var Stream1, Stream2: TStream; begin Stream1 := SQLQuery1.CreateBlobStream(SQLQuery1.FieldByName('blob1'),

bmRead); ShowMessage(IntToStr(Stream1.Size)); Stream2 := SQLQuery1.CreateBlobStream(SQLQuery1.FieldByName('blob2'), bmRead); ShowMessage(IntToStr(Stream2.Size)); Then adjust the SQL to reverse the blob fields SELECT blob2, blob1 from Table1 In my case the first test return the correct sizes, but in the second test blob2 size becomes 0. (This worked correctly in Delphi2009 Datasnap)

QC #: 77303 - Status: Closed

QC #: Project Date Reported: Area: 77303 Delphi 9/3/2009 Database\DBExpress Description Steps:[QC Short Description] Impossible to use temp tables in mssql [QC Description] An application originally made with D2007 uses dbExpress to connect to MSSQL. For some functionality, it creates temporary tables and fills these with data in consecutive statements on the same connection in the same (implicit) transaction. This worked great in D2007, but the same code fails in D2010. It looks like changes to the mssql dbexpress driver in between versions has broken this functionality. (Don't know about D2009.) Using explicit transactions does not help. Dmitry Arefiev suggested the driver might be using sp_execute statements internally, which would explain the behaviour because that would create a new context for each statement thus failing to recognize temp tables made in another context and therefore already dropped. This is really basic functionality for our app and a showstopper for porting it to D2010 (unfortunately, because I really like it even better than D2007). QC Entry 77303

TDBXWeaverBugsSuite.Native.DB.Test.exe connection=mssqlconnection -s:TestRaid_272730 -or- Create a new application and drop a TSQLConnection and a TButton. Connect the TSQLConnection to a MSSQL server by setting the Driver, Host and a Database. To the button.OnClick handler attach this code: SQLConnection1.ExecuteDirect('create table #TestTemp (something integer)'); SQLConnection1.ExecuteDirect('insert into #TestTemp (something) values (1)'); Expected: both statements run fine. If this program is made using D2007, it does. If made with D2010, this application fails on the 2nd statement with the SQL error "Invalid object name '#TestTemp' ". D2007 uses dbxmss30.dll. D2010 uses dbxmss.dll. If I make the D2007 version use dbxmss.dll, it fails too. Unfortunately, it doesn't work the other way round.

QC #: 77337 - Status: Closed

QC #: Project Date Reported: Area:77337 Delphi 9/3/2009 Compiler\Delphi\Execution Description Steps:[QC Short Description] F2084 Internal Error: URW1135 with an inlined record helper proc accessing an array [QC Description] -> see steps Original short description: Random internal errors when using helpers

Steps by USc: - save the following three files or the attached files in the folder Simplified - dcc32 -B RecordHelperInlineArrayAccessTest.dpr expected: it compiles actual: libMisc.pas(22) Fatal: F2084 Internal Error: URW1135 The error disappears when you change procedure IsNull; inline; into procedure IsNull; //--- RecordHelperInlineArrayAccessTest.dpr --- program RecordHelperInlineArrayAccessTest; {$APPTYPE CONSOLE} uses LibMisc; begin WriteLn('PASS'); end. //--- libMisc.pas --- unit libMisc; interface uses ActiveX.Simplified; type TGUIDHelper = record helper for TGUID procedure IsNull; inline; end;

Description: When I started using helpers in D2007 and D2009 I started to get internal compiler errors at random units, random positions and with random error codes, which resolved afer IDE restarted. At beginning, they occur not often and after working with units which contain helpers. But when helpers count and methods count in helpers grown, errors occured more and more often. And now I get stable error occuring in D2009 SP3 and not stable occuring (after some work) in D2007 without updates. Test project attached. QC Entry 77337

implementation procedure TGUIDHelper.IsNull; begin if Assigned(@D4) then; end; end. //--- ActiveX.Simplified.pas --- unit ActiveX.Simplified; interface type TGUID = record D4: array [0..7] of Byte; end; implementation end. Original steps: D2009 SP3: Open project Compile D2007: Open project repeat Compile Make some changes until Error

QC #: 77366 - Status: Closed

QC #: Project Date Reported: Area: 77366 Delphi 9/4/2009 RTL\Delphi\Other RTL Description Steps:[QC Short Description] AV using new RTTI on enum fields with explicit values [QC Description] When you have an enum declaration like this (with a specific value assignment): type TMyEnum = (Value1 = 10, Value2, Value3); you get an AV when using TRttiField.GetValue on a field of this type. When the enum does NOT contain explicit assignments like this: type TMyEnum = (Value1, Value2, Value3); then there is no problem. See steps and attachment for details. QC Entry 77366

Compile and run the attached application below. See the following program output indicating failure. IntField: 123 EnumField1: Value2 FAIL - Exception Error ClassName=EAccessViolation Message=Access violation at address 00447C14 in module 'BTS272768.exe'. Read of address 00000004 program BTS272768; {$APPTYPE CONSOLE} uses Rtti, SysUtils; type TMyEnum1 = (Value1, Value2, Value3); TMyEnum2 = (Value4 = 10, Value5, Value6); TMyObject = class public IntField: Integer; EnumField1: TMyEnum1; EnumField2: TMyEnum2; end; procedure DoTest; var MyObject: TMyObject; RttiContext: TRttiContext; ObjType: TRttiType; Field: TRttiField; Value: TValue; begin MyObject := TMyObject.Create; try MyObject.IntField := 123; MyObject.EnumField1 := Value2; MyObject.EnumField2 := Value6; ObjType := RttiContext.GetType(MyObject.ClassInfo); Assert(Assigned(ObjType)); { Read fields } for Field in ObjType.GetFields do begin Value := Field.GetValue(MyObject); { <-- AV here when accessing EnumField2 }

WriteLn(Field.Name, ': ', Value.ToString); end; WriteLn('PASS'); finally MyObject.Free; end; end; begin try DoTest; except on E: Exception do begin WriteLn('FAIL - Exception Error'); WriteLn(' ClassName=', E.ClassName); WriteLn(' Message=', E.Message); end; end; end.

QC #: 77370 - Status: Closed

QC #: Project Date Reported: Area: 77370 Delphi 9/4/2009 Compiler\Delphi\Generics Description Steps:[QC Short Description] Generic records fields cannot be mapped to getters and setters for properties [QC Description] Using the code (in the Steps Field of this report) you will see that I can map a field from a Record directly as a getter for a property by when I use a generics it doesn't work. Try the code and see for your self. QC Entry 77370

Steps by USc (including the original test case snippet turned into a console application): - save the following code as RecordFieldAsPropertyTest.dpr - dcc32 RecordFieldAsPropertyTest.dpr expected: it compiles actual: RecordFieldAsPropertyTest.dpr(18) Error: E2467 Record or object type required Additional note: The error does also occur if the field is an actual type ( means changing THello<T> = record F: T; end; into THello<T> = record F: Integer; end; ) program RecordFieldAsPropertyTest; {$APPTYPE CONSOLE} type THello<T> = record F: T; end; THello = record F: Integer; end; TDoggie = record FWorks: THello; FDoesnt: THello<Integer>; property Works: Integer read FWorks.F; property Doesnt: Integer read FDoesnt.F; end; begin WriteLn('PASS'); end.

QC #: 77410 - Status: Closed

QC #: Project Date Reported: Area:77410 Delphi 9/6/2009 VCL\Core VCL Classes\TApplication

Description Steps:[QC Short Description] message pump is now much slower than older versions [QC Description] Delphi 2010 has a message pump which is much slower than previous version (Actually the change appeared silently in D2009 update 3). The reason for slow down is clear: TApplication.ProcessMessage now filter queued messages to first extract mouse messages then do the processing. Looking at the code, the behaviour is exactly the same as the previous version which had not that message filtering. To say it in other words (sorry for my bad english), extracting the mouse messages is completely useless. The only impact is making the message pump much slower ! OK, there is another slight impact: mouse messages are handled before

See attached zip file containing a sample program. See _readme.txt in the zip file.

any other message and this could cause strange result because in many applications, the order of message processing is important (this is why there is a queue !). The impact is not noticable in normal situation because the message queue is almost empty. But under stress condition, removing mouse messages from the queue takes a lot of time. The application then consume a lot of CPU and is much less responsive if not completely frozen. I don't understand why the message pump code has been changed after so many years of good services. That change makes existing applications much slower and impose a new design (a worker thread to have another message queue). I think this is completely unecessary. btw: the offending code is line 9757 in forms.pas in D2010: MsgExists := PeekMessage(Msg, 0, WM_MOUSEFIRST, WM_MOUSELAST, PM_REMOVE); See attached file for demo program showing the issue. The zip file contains a screen dump showing D2010 and D2007 versions side by side with task manager. QC Entry 77410

QC #: 77443 - Status: Closed

QC #: Project Date Reported: Area:77443 Delphi 9/7/2009 IDE\Dialogs\Project Options Description Steps:[QC Short Description] Wrong behavior Project\Compile command when "Auto increment build number" flag checked in project options [QC Description] 1) Create new VCL application. 2) Choose Project\Options 3) Select "Version Info" node 4) Check "Include version information in project" and "Auto-increment build number" 5) Choose Project\Compile Build number was increased!!!??? In early versions of Delphi Build number are increasing only by Project\Build command. And this was a correct behavior. QC Entry 77443

QC #: 77448 - Status: Closed

QC #: Project Date Reported: Area: 77448 Delphi 9/7/2009 VCL Description Steps:[QC Short Description] TRichEdit.RegisterConversionFormat causes exception [QC Description] On Delphi 2009, TRichEdit.RegisterConversionFormat does not work (the function passed to the method will never be called), and simply calling the method causes an exception when the program exits. The problem appears to be in the FreeConversionFormatList method called in the ComCtrls finalization section, and specifically the AppendConversionFormat method, which is using the code: ConversionFormatList.Add(Pointer(@NewRec));

Simply creating a TRichEdit instance and then calling the RegisterConversionFormat method with appropriate parameters demonstrates the bug. The attachment contains a program for both Delphi 2009 and Delphi 5 which demonstrates the problem. To see the problem, run the program, click the button on the main form, then close the program. An access violation occurs when the program exits if compiled with Delphi 2009, but not with Delphi 5.

when it looks to me like it should be this: ConversionFormatList.Add(Pointer(NewRec)); Not only does this fail to register the conversion function with the correct address, so it never gets called, but it screws up the heap when the list is de-allocated. QC Entry 77448 trunk rev: 24803 update rev: 24804

QC #: 77460 - Status: Closed

QC #: Project Date Reported: Area: 77460 Delphi 9/7/2009 IDE\File Handling Description Steps:[QC Short Description] Error Wizard Datasnap Server [QC Description] File -> New -> Other -> DataSnap Server... --------------------------- Error --------------------------- Error in module : USES clause is missing or incorrect. --------------------------- OK Help --------------------------- Added by Sysop <<<<<< Please see comments of QC report for more information about environement. >>>>>> QC Entry 77460

File -> New -> Other -> DataSnap Server... --------------------------- Error --------------------------- Error in module : USES clause is missing or incorrect. --------------------------- OK Help ---------------------------

QC #: 77478 - Status: Closed

QC #: Project Date Reported: Area:77478 Delphi 9/8/2009 AddOn\Interbase components Description Steps:[QC Short Description] IBX: TIBStoredProc not working with WideString-Param in D2010 [QC Description] Hello, I just installed Delphi 2010. In my projects I am using TIBStoredProc with ExecProc. The IB-Database uses "UNICODE_FSS". When a Param is "WideString" an exception comes up (ibxeNotSupported). I think it is a problem of "TIBStoredProc.SetParams". WideString is missing in the case block. -- procedure TIBStoredProc.SetParams;

TGUIFulcrumBugsSuite.Zombie.DB.Test.exe connection=ibconnection_utf8 -s:Test

var i : integer; j: integer; begin ... case Params[j].DataType of ftString, ftFixedChar: // <--- WideString missing ... QC Entry 77478

QC #: 77487 - Status: Closed

QC #: Project Date Reported:

Area:

77487 C++Builder 9/8/2009

Compiler\C++

Description Steps: [QC Short Description] Boost Thread generate F1001 Internal code generator error [QC Description] The attached project can be compile at RAD2009 and can't be compiled at 2010. The error mesage point to dllMainFile1.cpp line 126 [BCC32 Fatal Error] dllMainFile1.cpp(126): F1001 Internal code generator error Added by Sysop <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< In my environment, I corrected 'include path' configuration of your project option as below. ------ $(CG_BOOST_ROOT)\boost\tr1\tr1;$(BDS)\include;$(BDS)\include\dinkumware;$(BDS)\include\vcl;$(CG_BOOST_ROOT);$(BDS)\ObjRepos\Cpp;$(BDS)\include\Indy10;$(BDS)\RaveReports\Lib ------ Then I tried to build 'dllMainFile1.cpp'. But, I got errors as below. ------ [BCC32 Error] posix_time_config.hpp(19): E2209 can not open include file 'boost/config/no_tr1/cmath.hpp' ... ... ------ >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> QC Entry 77487

Please use attached test case. dllMainFile1.cpp that use boost and can't compile.

QC #: 77509 - Status: Closed

QC #: Project Date Reported: Area: 77509 Delphi 9/8/2009 RTL\Delphi\Other RTL

Description Steps:[QC Short Description] GetTimeZoneInformation is very slow on Vista with programs compiled using RS2010 [QC Description] On Vista GetTimeZoneInformation() is about a 1000 times slower when using D2010 compared to when using D2009 (and earlier). Also discussed here: https://forums.embarcadero.com/thread.jspa?messageID=156125&tstart=0#156125... and here: https://forums.embarcadero.com/thread.jspa?messageID=157355&tstart=0#157355

Also see attached projects: 1) Open Project1 in D2009 and compile and run it. 2) note execution time 3) Open Project1 in D2010 and compile and run it. 4) note execution time When running on Vista (x32 or x64) you'll see a huge difference between the two execution times. 1) Open Project2 and compile and run in D2010 2) note execution time 3) Open Project2 and activate the $define USE_LOCALE_INVARIANT and compile using D2010. 4) note execution time Again when running on Vista (x32 or x64) you'll see a huge difference between the two execution times.

program Project1; program Project234; {$APPTYPE CONSOLE} { $DEFINE USESYSUTILS} // define or not - test both uses Windows{$IFDEF USESYSUTILS}, SysUtils{$ENDIF}; var I: Integer; QPF, QPC1, QPC2: Int64; tzi: TTimeZoneInformation; begin QueryPerformanceFrequency(QPF); QueryPerformanceCounter(QPC1); for I := 0 to 9999 do GetTimeZoneInformation(tzi); QueryPerformanceCounter(QPC2); Writeln(CompilerVersion:10:2); WriteLn('Execution time = ', (QPC2-QPC1)/QPF:10:6); ReadLn; end. (On Vista Ultimate 64 SP2 on an Intel i7 920 2.67GHz) D2009: Execution time = 0.005 s D2010: Execution time = 5.289 s It just worries me that a simple API suddenly takes about 0.5 millisecond to execute and am wondering if other APIs are effected by this as well. In the mean-time someone else found out that this is apperently caused by a SetThreadUILanguage call in D2010 which sets some flag in Windows Vista which makes GetTimeZoneInformation call tzres.dll on every call instead of only a few times in all the loops. On XP, only 0 is allowed, so there, LOCALE_INVARIANT is not used anyway. Note: this will not happen when you remove SysUtils from the above code. To further prove this, following test was presented: program Project2; {$APPTYPE CONSOLE} { $DEFINE USE_LOCALE_INVARIANT} // define or not - test both uses Windows; var I: Integer; QPF, QPC1, QPC2: Int64; tzi: TTimeZoneInformation; function SetThreadUILanguage(LangId: WORD): WORD; stdcall; external 'kernel32.dll'; begin {$IFDEF USE_LOCALE_INVARIANT} SetThreadUILanguage( LOCALE_INVARIANT); // In System.pas - // getting res strings invokes its call. {$ENDIF} QueryPerformanceFrequency(QPF); QueryPerformanceCounter(QPC1); for I := 0 to 9999 do GetTimeZoneInformation(tzi);

QueryPerformanceCounter(QPC2); Writeln(CompilerVersion:10:2); WriteLn('Execution time = ', (QPC2-QPC1)/QPF:10:6); ReadLn; end. (Vista U64 SP2, D2010) without SetThreadUILanguage: Execution time = 0.005452 seconds with SetThreadUILanguage: Execution time = 5.045242 seconds QC Entry 77509

QC #: 77513 - Status: Closed

QC #: Project Date Reported: Area: 77513 C++Builder 9/8/2009 IDE Description Steps:[QC Short Description] After reporting a compile error, program then runs. [QC Description] I'm finding this very frustrating. On every version of Delphi/CBuilder etc you push F9 and the program compiles if it needs to, and if there are no errors it runs in debug mode. With Rad studio 10, I'm finding that Delphi forms will not compile if there are errors (correct), but then the previous built program runs under the debugger. QC Entry 77513 Added by Sysop <<<<<<<<<<<< This issue seems to be fixed on Update 4. Please retest and close this report. >>>>>>>>>>>>

Build a program with CBuilder, with some delphi forms in it. Run it. add an error to the pascal form (misnamed variable in my case). run it. expected, error to be reported and the line to be highlighted, result error is reported, then program is run.

QC #: 77524 - Status: Closed

QC #: Project Date Reported: Area:77524 Delphi 9/8/2009 AddOn\Interbase components Description Steps:[QC Short Description] IBX Not handling new data types in D2010 [QC Description] I have ran into an area where IBX is reporting a "Unsupported Feature". This bug is similar to bug #77478, but just in a different area In IBQuery.pas - procedure TIBQuery.SetParams; There is a case statement to deal with all the different Param Datatypes. It fails to check for ftShortInt and raises an Unsupported feature exception. It appears that the IBx code should be checked everywhere it is looking at field data types to ensure that they account for any new types in D2010. SQLParams[i].IsNull := True

else begin SQLParams[i].IsNull := False; >>>>> case Params[i].DataType of ftBytes: begin ... QC Entry 77524

QC #: 77547 - Status: Closed

QC #: Project Date Reported: Area:77547 Delphi 9/9/2009 IDE\Code Editor\Formatting Description Steps:[QC Short Description] Formatter fails to format anonymous methods with variables [QC Description] The formatter formats anonymous methods with variable declarations wrongly. QC Entry 77547

1. Load the AnonThreads demo 2. switch to the SortThds unit 3. Press Ctrl+D This is the correct formatting: SelectionSort := procedure(A: TArray<Integer>) var I, J, T: Integer; begin but this is the result of Ctrl+D: SelectionSort := procedure(A: TArray<Integer>)var I, J, T: Integer; begin

QC #: 77548 - Status: Closed

QC #: Project Date Reported: Area:77548 Delphi 9/9/2009 IDE\Code Editor\Formatting Description Steps:[QC Short Description] Formatter fails to format class declaration without end [QC Description] The formatter does not indent correctly after a class declaration like this: type EInvalidValue = class(Exception); everything after it gets indented by one tab QC Entry 77548

1. Create a new project 2. add the following type declarations: type EInvalidValue = class(Exception); type TBla = class end; 3. press Ctrl+D The result looks like this: type EInvalidValue = class(Exception); type TBla = class end; but should look like this: type EInvalidValue = class(Exception); type TBla = class end;

QC #: 77551 - Status: Closed

QC #: Project Date Reported: Area: 77551 Delphi 9/9/2009 VCL Description Steps:[QC Short Description] TWinControl.Destroy access violation on FTouchManager [QC Description] TWinControl.Destroy in Controls.pas contains the following code: if Touch.GestureEngine <> nil then Touch.GestureEngine.Free; Under normal circumstances, this works because the inherited TControl.Create calls CreateTouchManager to create the object; A problems occurs if an exception is raised during the constructor of a TWinControl, before inherited, which will cause the Destroy

1. Create a subclass of TWinControl 2. In the constructor, raise an exception before calling inherited.

procedure to raise an access violation on Touch.GestureEngine. The code should be written as follows: if (Touch <> nil) and (Touch.GestureEngine <> nil) then Touch.GestureEngine.Free; QC Entry 77551 trunk rev: 24741 update rev: 24747

QC #: 77556 - Status: Closed

QC #: Project Date Reported: Area: 77556 C++Builder 9/9/2009 Compiler\Delphi Description Steps:[QC Short Description] F2084 internal errors when making a package in the IDE that contains Delphi units [QC Description] Trying to install RichView (http://www.trichview.com/) into C++Builder can lead to errors like "F2084 Internal Error: AV21FAC6FE-W00000004-1" and also ILINK32 errors. These errors are reported at line numbers greater then the maximum line number of the unit (very likely same issue as #271112) These errors do only happen in the IDE - there are no such problems on the command line. -> see steps QC Entry 77556

1. save the attached files (this is a test case created from the current RichView sources) 2. if you already executed the following steps then remove all *.hpp and *.obj files from the test case dir and remove the Release sub dir 3. start C++Builder 4. open RVPkgCB2010.cbproj 5. call "Make" for the package RVPkgCB2010.cbproj from the Project Manager popup menu expected: it compiles without any problems, because there is no problem with "Build" actual: various internal error I got these results (output in "Build" tab in message pane) with five tests: two times: Compiling RVPkgCB2010.cbproj (Release configuration) [DCC Fatal Error] CRVFData.pas(60): F2084 Internal Error: AV21FAC6FE-W00000004-1 Success once: Compiling RVPkgCB2010.cbproj (Release configuration) [DCC Fatal Error] CRVFData.pas(60): F2084 Internal Error: AV21FAC6FE-W00000004-1 [DCC Fatal Error] CRVFData.pas(60): F2084 Internal Error: AV21FA40BA-W00000004-1 [ILINK32 Error] Fatal: Unable to open file 'RVUNDO.OBJ' Failed two times Compiling RVPkgCB2010.cbproj (Release configuration) [DCC Fatal Error] CRVFData.pas(60): F2084 Internal Error: AV21FAC6FE-W00026805-1 [DCC Fatal Error] CRVFData.pas(60): F2084 Internal Error: AV21FA40BA-W00026805-1 [ILINK32 Error] Fatal: Unable to open file 'RVUNDO.OBJ' Failed Note CRVFData.pas has only 59 lines and the error is reported at line 60. (very likely same issue as #271112) (6. close the IDE 7. go to 2.)

QC #: 77561 - Status: Closed

QC #: Project Date Reported: Area:77561 Delphi 9/9/2009 VCL\System Controls\TTrayIcon

Description Steps:[QC Short Description] TTrayIcon.ShowBalloonHint() does not work correctly on pre-Vista systems [QC Description] TTrayIcon.ShowBalloonHint() does not work correctly on pre-Vista systems. This is because the ShellAPI.TNotifyIconData record is larger in D2010 than it is in D2009, and TTrayIcon is setting the TNotifyIconData.cbSize member to the full byte size, which is only appropriate for Vista and later systems. TTrayIcon needs to be updated to check the actual OS version and adjust the cbSize value accordingly, and then not use fields that are outside that size when appropriate. QC Entry 77561 trunk rev: 24729 updates rev: 24730

QC #: 77575 - Status: Closed

QC #: Project Date Reported: Area: 77575 Delphi 9/10/2009 Compiler\Delphi\Generics Description Steps:[QC Short Description] F2084 Internal Error: URW1111 when using type TArray<T> [QC Description] Try to compile attached project. It seems that Concat method of TArrayBuilder<T> (see Unit1) is a source of problem. I mentioned early that something wrong in handling type TArray<T> (See report #77535). It seems that report #75397 is fixed partitially too. QC Entry 77575

Steps by USc: - save the files at the end of the steps - dcc32 -B TestURW1111_1.dpr expected: it compiles actual: Unit2.pas(20) Fatal: F2084 Internal Error: URW1111 Additional test to make sure the original test case is also fixed: - extract the attachment into another dir - insert an "end;" after line 12 in TestURW1111_1.dpr to complete TEncodingUtils - dcc32 -B TestURW1111_1.dpr expected: it compiles actual: Fatal: F2084 Internal Error: URW1111 //--- TestURW1111_1.dpr --- program TestURW1111_1; {$APPTYPE CONSOLE} uses Unit1 in 'Unit1.pas', Unit2 in 'Unit2.pas'; begin end. //--- Unit1.pas --- unit Unit1; interface type TArrayBuilder<T> = class(TObject) public class function Concat(ASource: TArray<TArray<T>>): TArray<T>; end; implementation class function TArrayBuilder<T>.Concat(ASource: TArray<TArray<T>>): TArray<T>; var I: Integer; Items: TArray<T>; begin Items := ASource[I]; end; end. //--- Unit2.pas --- unit Unit2; interface type TEncodingHelper = class helper for TObject public class procedure GetRegisteredEncodings; end; implementation uses Unit1; class procedure TEncodingHelper.GetRegisteredEncodings; begin TArrayBuilder<TObject>.Create; end; end.

QC #: 77581 - Status: Closed

QC #: Project Date Reported: Area:77581 Delphi 9/10/2009 Documentation\Online Help\Main help

Description Steps:[QC Short Description] compiler option String Format Checking is not in help [QC Description] The help on compiler options is missing the option "String Format Check". It's neither in the online help nor in the docwiki. QC Entry 77581

1. open Project/Options 2. select Delphi Compiler/Compiler 3. press F1 4. search for String Format Checking -> It's not there 5. click on "Current Wiki Page" and wait for it to load 6. search for String Format Checking -> It's not there either

QC #: 77585 - Status: Closed

QC #: Project Date Reported: Area: 77585 Delphi 9/10/2009 IDE\Tool Palette Description Steps:[QC Short Description] Component Toolbar does not retain it's position when restarting the IDE [QC Description] When the IDE is restarted the Component Toolbar is always moved to the right of the other toolbars even when it was previously positioned in another location. QC Entry 77585

Start the IDE View | Toolbars | Component (check it) Drag Component Toolbar to be below the other toolbars Restart IDE //Exp: Toolbar positioned where it was //Act: Toolbar moved back up to the right of the menu and other toolbars

QC #: 77612 - Status: Closed

QC #: Project Date Reported: Area: 77612 Delphi 9/11/2009 IDE\Open Tools API Description Steps:[QC Short Description] ToolsAPI.IOTAEditReader.GetText returns incorrect results. [QC Description] ToolsAPI.IOTAEditReader.GetText function returns only the first two bytes of four. This manifests itself if the buffer size is greater than 65535 QC Entry 77612

Create the simplest expert, which copies of the text editor window, the program in a string variable and return. In versions of Delphi 2005 and over the result text may be corrupted for no apparent reason, if such a text data, save, of course, will be lost. This behavior occurs if the buffer passed via gettext function IOTAEditReader., more 65535. function ReaderGetText(const lciEditorReader: IOTAEditReader; Position: Longint; Buffer: PAnsiChar; Count: Longint): Longint; var ActualSize: Longint; ActualCount, TotalCount: integer; begin result := 0; FillChar(Buffer^, Count, 0); ActualSize := lciEditorReader.GetText(Position, Buffer, Count); ActualCount := 0; TotalCount := 0; // Define the actual size of data while (result < Count) and (Buffer[result] <> #0) do begin if ((Buffer[result] = #13) and (Buffer[result + 1] = #10)) or (Buffer[result] = #0) then begin if result <= ActualSize then inc(ActualCount); inc(TotalCount); end; inc(result); end; if result <> ActualSize then begin MessageBox(0, PChar(Format(StrIOTAEditReaderGetTe, [ActualSize, result, (result mod 65536), Position, Count, ActualCount, TotalCount])), PChar(TEST_MENU_NAME), MB_ICONINFORMATION); end; end;

QC #: 77628 - Status: Closed

QC #: Project Date Reported: Area: 77628 Delphi 9/12/2009 RTL\Delphi\Other Classes

Description Steps:[QC Short Description] TStopwatch returns wrong results in low res. [QC Description] Someone posted this code: program Project243; {$APPTYPE CONSOLE} uses SysUtils, Diagnostics; procedure Foo; var AStopwatch: TStopwatch; begin AStopwatch.Reset; AStopwatch.Start; sleep(1500); //one and a half second AStopwatch.Stop; Writeln(string(AStopwatch.Elapsed)); end; begin try Foo; Readln; except on E: Exception do Writeln(E.ClassName, ': ', E.Message); end; end. This gives a result like: 00:00:00.1497000 (0.15 seconds)

Compile and run the attached application below. See the following program output indicating failure. FAIL #1 Delta=1350 FAIL Counter=1 program BTS272843; {$APPTYPE CONSOLE} uses SysUtils, Diagnostics; const Threshold = 150; Period = 1500; var Counter: Integer = 0; Delta: Int64; procedure Test1; var AStopwatch: TStopwatch; begin AStopwatch.Reset; AStopwatch.Start; sleep(Period); //one and a half second AStopwatch.Stop; Delta := abs(AStopWatch.ElapsedMilliseconds - Period);if Delta < Threshold then Inc(Counter) else WriteLn('FAIL #1 Delta=', Delta); end;

The fact that not Create or StartNew were used made this stopwatch low res, and that produces the wrong result, which should have been something like 00:00:01.4790000 (1.5 seconds) I assume the problem lies in the factor 1000 in TStopwatch.GetTimeStamp, which should probably be 10000. ( Additional note from [1] added by USc: > The 1000 should be 10000, AFAICT. Then you should get 1.5 seconds, > also in your code (which uses low res). Or just use the already defined TicksPerMillisecond (which is for whatever dark reason defined as a hex number $2710 = 10000). Or even better remove TicksPerMillisecond and TicksPerSecond from that class and use the ones defined in TTimeSpan. [1] "TStopwatch. A bug? (Delphi 2010)" in embarcadero.public.delphi.language.delphi.win32 https://forums.embarcadero.com/thread.jspa?messageID=159618&tstart=0#159618Message-ID: <[email protected]> ) QC Entry 77628

procedure Test2; var AStopwatch: TStopwatch; begin AStopwatch := TStopwatch.Create; AStopwatch.Start; sleep(Period); //one and a half second AStopwatch.Stop; Delta := abs(AStopWatch.ElapsedMilliseconds - Period);if Delta < Threshold then Inc(Counter) else WriteLn('FAIL #2 Delta=', Delta); end; begin try Test1; Test2; if Counter = 2 then WriteLn('PASS') else WriteLn('FAIL Counter=', Counter); except on E: Exception do Writeln(E.ClassName, ': ', E.Message); end; end.

QC #: 77648 - Status: Closed

QC #: Project Date Reported: Area:77648 Delphi 9/13/2009 IDE\Code Editor\Formatting Description Steps:[QC Short Description] Typecasting reformats poorly [QC Description] Added by Sysop <<<<<<<<< Please see [Steps] for more details. >>>>>>>>> QC Entry 77648

Code was: (FindComponent('sqlGiftRedeemed') as TIBSQL).Close; (FindComponent('sqlGiftRedeemed') as TIBSQL).ParamByName('Business').AsInteger := Business; (FindComponent('sqlGiftRedeemed') as TIBSQL).ParamByName('Gift').AsInteger := qryGift.FieldByName('Gift_Number').AsInteger; (FindComponent('sqlGiftRedeemed') as TIBSQL).ExecQuery; Ctrl+D converted it to: (FindComponent('sqlGiftRedeemed') as TIBSQL) .Close; (FindComponent('sqlGiftRedeemed') as TIBSQL) .ParamByName('Business').AsInteger := Business; (FindComponent('sqlGiftRedeemed') as TIBSQL) .ParamByName('Gift').AsInteger := qryGift.FieldByName('Gift_Number').AsInteger; (FindComponent('sqlGiftRedeemed') as TIBSQL) .ExecQuery; Note that it has inserted whitespace between the cast and to 'dot' operator, and continued on a line after a ';' (second line with .Close).

QC #: 77670 - Status: Closed

QC #: Project Date Reported: Area:77670 Delphi 9/14/2009 Compiler\Delphi\Anonymous Methods

Description Steps:[QC Short Description] overloaded method causes Internal Error: E2896 (JJS: Not seen until rev. 24844 is delivered)

Steps by USc including the code from the description slightly completed: - save the following code as AnonMethodFailure.dpr - dcc32 AnonMethodFailure.dpr expected: it compiles actual: D2009 U#3: AnonMethodFailure.dpr(42) Fatal: F2084 Internal Error: E2896

[QC Description] Advanced record with overloaded function/procedure, where one of them has an anonymous method parameter causes F2084 Internal Error: E2896. Here is a code snippet that causes the F2084 Internal Error: E2896: type TF1 = reference to function (P: Pointer; AI: Integer): Cardinal; type TRec = record var FP: Pointer; var FI: Integer; function Proc (AInteger: Integer): Boolean; overload; function Proc (const AF: TF1): Boolean; overload; end; function TRec.Proc (AInteger: Integer): Boolean; begin Result := AInteger = 1; end; function TRec.Proc (const AF: TF1): Boolean; var I: Integer; begin I := AF (FP, FI); Result := I = 1; end; procedure TForm1.Button1Click ( Sender: TObject); var Rec: TRec; Bool: Boolean; begin Rec.FP := @Rec; Rec.FI := 2; Bool := Rec.Proc (function (P: Pointer; AI: Integer): Cardinal begin if P = Nil then Result := 1 else Result := AI; end); end; QC Entry 77670

D2010 RTM: AnonMethodFailure.dpr(42) Fatal: F2084 Internal Error: E3018 program AnonMethodFailure; {$APPTYPE CONSOLE} type TF1 = reference to function(P: Pointer; AI: Integer): Cardinal; type TRec = record var FP: Pointer; var FI: Integer; function Proc(AInteger: Integer): Boolean; overload; function Proc(const AF: TF1): Boolean; overload; end; function TRec.Proc(AInteger: Integer): Boolean; begin Result := AInteger = 1; end; function TRec.Proc(const AF: TF1): Boolean; var I: Integer; begin I := AF(FP, FI); Result := I = 1; end; procedure TestProc; var Rec: TRec; Bool: Boolean; begin Rec.FP := @Rec; Rec.FI := 2; Bool := Rec.Proc(function(P: Pointer; AI: Integer): Cardinal begin if P = nil then Result := 1 else Result := AI; end); end; begin WriteLn('PASS'); end.

QC #: 77680 - Status: Closed

QC #: Project Date Reported: Area: 77680 Delphi 9/14/2009 IDE\Code Editor\ Description Steps:[QC Short Description] Keep else end begin on the same line [QC Description] Hi! Begin some code

Option "Remove line breaks inside ..." added with default value = true[vk] Defaulr value changed to "False", but in the Formatter_Comact profile left "True"

end else begin some code end; Gets formattet into Begin some code end else begin some code end; In the NG there have been suggestions to keep formatting as the first example - at the same line... QC Entry 77680

QC #: 77686 - Status: Closed

QC #: Project Date Reported: Area:77686 Delphi 9/14/2009 Compiler\Delphi\Other Compiler

Description Steps:[QC Short Description] There are undocumented UNIT_EXPERIMENTAL and GARBAGE conditional defines [QC Description] There are undocumented UNIT_EXPERIMENTAL and GARBAGE conditional defines What they are used for? QC Entry 77686

Open a new project Open the .dpr file Press Ctrl+O+O You will see {$WARN SYMBOL_EXPERIMENTAL ON} {$WARN UNIT_LIBRARY ON} {$WARN UNIT_PLATFORM ON} {$WARN UNIT_DEPRECATED ON} {$WARN UNIT_EXPERIMENTAL ON} {$WARN HRESULT_COMPAT ON} {$WARN HIDING_MEMBER ON} {$WARN HIDDEN_VIRTUAL ON} {$WARN GARBAGE ON} {$WARN BOUNDS_ERROR ON} {$WARN ZERO_NIL_COMPAT ON} {$WARN STRING_CONST_TRUNCED ON} Please describe what those are used for?

QC #: 77695 - Status: Closed

QC #: Project Date Reported: Area: 77695 Delphi 9/14/2009 Compiler\Delphi\Generics Description Steps:[QC Short Description] F2084 Internal Error: C17608 QC Entry 77695

Steps by USc: - save the following console app as AnonGenericFuncInRecordTest.dpr - dcc32 AnonGenericFuncInRecordTest.dpr expected: it compiles actual: AnonGenericFuncInRecordTest.dpr(17) Fatal: F2084 Internal Error: C17608 program AnonGenericFuncInRecordTest; {$APPTYPE CONSOLE} type TFunc<TResult> = reference to function: TResult; TConditionProc = TFunc<Boolean>; TConditionAction = record ConditionProc: TConditionProc; end; procedure ParseConditions(Actions: TConditionAction); begin Actions.ConditionProc(); end; begin WriteLn('PASS'); end. --------------------------------------------------------------------------- Original steps: Try to compile simple application Type TConditionProc = TFunc<TStrings, Boolean>; TConditionAction = Record ConditionProc : TConditionProc; End; Procedure ParseConditions(Const ActionTask : IUnknown; Const Actions : Array Of TConditionAction); Var Proc : TConditionProc; Begin Actions[0].ConditionProc(Nil); End; --------------------------------------------------------------------------- I get this when I try to resolve why this doesn't work Type TConditionProc = TFunc<TStrings, Boolean>; TConditionAction = Record ConditionProc : TConditionProc; End; Procedure ParseConditions(Const ActionTask : IUnknown; Const Actions : Array Of TConditionAction); Var Proc : TConditionProc; A : Boolean; Begin A := Actions[0].ConditionProc(Nil); End; [DCC Error] Unit16.pas(35): E2010 Incompatible types: 'Boolean' and 'TResult'

QC #: 77696 - Status: Closed

QC #: Project Date Reported: Area: 77696 Delphi 9/14/2009 AddOn\IntraWeb Description Steps:[QC Short Description] Chinese(big5/UTF-8) problem with RAD Studio/Delphi 2010 bundled IntraWeb [QC Description] Good day, I'm currently evaluating RAD Studio 2010 and came across the following problem: - the bundled IntraWeb 10.0.0 does not work fully with Chinese characters - version 10.0.15 and up of IntraWeb is supposedly bug-fixed and is available for download - however the downloaded install package does not yet recognise RAD Studio 2010 (only recognises up to RAD 2009) Is there any quick and easy way to patch up the bundled IntraWeb, so that I can continue evaluating this wonderful product? I searched on IntraWeb's website and apparently they are not (directly) responsible for bundled IntraWeb solutions. Kindly advise. QC Entry 77696

QC #: 77698 - Status: Closed

QC #: Project Date Reported: Area: 77698 Delphi 9/14/2009 Database\TParams Description Steps:[QC Short Description] Repeated Param Item return invalid value if it is last item in TParams collection #2 [QC Description] This problem is duplicate from QC#52996. QC#52996 has mark closed but I still can replay the problem in Delphi 2010. I create a new issue here and alter the test case to show the problem more clearly. We may use TParams.ParseSQL to create a list of parameter items of SQL with parameter. For example: UPDATE MYTABLE SET Name1=:Value1 WHERE Name1=:Value1 AND Name2=:Value2 TParams.ParseSQL will return 3 param items where 1st and 2nd param item has same param name. In this case, TParams will attempt to use TParam.FParamRef (private property) to link the 2nd param item to 1st param item at some point. Refer to VCL source code (DB.pas). If you assign a value to Params[0], you will get the same value in Params[1] and vice versa. If the SQL is: UPDATE MYTABLE SET Name1=:Value1

TDBXFulcrumBugsSuite.Native.DB.TEst.exe connection=ibconnection -s:TestRaid_274231 -OR- procedure TTest_DB.Test_TParams_SameParameter_AtLast; const M1 = 'unmatch parameter datatype'; M2 = 'unmatch value'; var S: string; P: TParams; F: TFieldType; begin S := 'UPDATE MYTABLE ' + 'SET Name1=:Value1 ' + 'WHERE Name2=:Value2 ' + 'AND Name1=:Value1'; P := TParams.Create(nil); try P.ParseSQL(S, True); P[0].AsString := 'aValue'; CheckEquals('Value1', P[0].Name); CheckEquals('Value2', P[1].Name); CheckEquals('Value1', P[2].Name); {$if CompilerVersion<=20}F := ftString{$else}F := ftWideString{$ifend};

WHERE Name2=:Value2 AND Name1=:Value1 You may notice the 1st and 3rd param items are repeated in this case. If you assign a value to Params[0], you will not get the value in Params[2]. This happen if there are repeated param item falls on the last item in TParams collection. Added by Sysop <<<<<<<<<<<< If 3 different paramters are used as below, this issue does not occur. UPDATE MYTABLE SET Name1=:Value1 WHERE Name1=:Value2 AND Name2=:Value3 >>>>>>>>>>>> QC Entry 77698

CheckTrue(P[0].DataType = F, M1); CheckEquals('aValue', P[0].AsString, M2); CheckTrue(P[1].DataType = ftUnknown, M1); CheckEquals('', P[1].AsString, M2); CheckTrue(P[2].DataType = F, M1); CheckEquals('aValue', P[2].AsString, M2); finally P.Free; end; end;

QC #: 77701 - Status: Closed

QC #: Project Date Reported: Area:77701 Delphi 9/15/2009 IDE\Project Management\Project Manager

Description Steps:[QC Short Description] The Debug configuration has Optimisation enabled by default. [QC Description] Creating new project in Delphi has the Optimisation on for the Debug configuration. Debug configurations should have the optimisation Off by dafault. QC Entry 77701

1. Create a new Delphi project. 2. Check the debug configuration compiler options. The Optimisation is On instead of Off.

QC #: 77723 - Status: Closed

QC #: Project Date Reported: Area: 77723 C++Builder 9/15/2009 Linker Description Steps:[QC Short Description] DLL base binary size is too large [QC Description] The VCL overhead of C++Builder projects has always been a little larger than the comparable Delphi counterpart. However, starting with C++Builder 2009 and continuing in C++Builder 2010 the overhead of a do-nothing VCL DLL project has risen by many times the previously acceptable size. QC Entry 77723

Consider a do-nothing VCL DLL project. The project is created, modified to specify output directory and to build standalone (turn off packages and runtime library). Here are the results on my pc: Delphi 6: unavailable since I do not own Delphi 6 C++Builder 6: 155k Delphi 2007: 81k C++Builder 2007: 194k Delphi 2009: 127k C++Builder 2009: 628k Delphi 2010: 295k C++Builder 2010: 947k Note, with C++Builder 2010 a do-nothing, standalone VCL DLL project starts out at 1MB in size. Even Delphi's number exceeds a reasonable do-nothing size at a quarter of a megabyte. A do-nothing non-VCL DLL project is 56k.

QC #: 77724 - Status: Closed

QC #: Project Date Reported: Area: 77724 Delphi 9/15/2009 Database\TParams Description Steps:[QC Short Description] TParams.ParseSQL does not handle parameter names with spaces [QC Description]

TDBXFulcrumBugsSuite.Native.DB.Test.exe connection=ibconnection -s:TestRaid_272900 -OR-

TParams.ParseSQL does not correctly parse named parameters when the parameter name is quoted and contains a space. For instance, when the SQL statement 'SELECT * FROM test10a WHERE lastname = :"Last Name" ' is passed to TParams.ParseSQL, the parameter that is created is named "Last". This is a regression from behavior in Delphi 2009. QC Entry 77724

The following code will produce the errant behavior: procedure TForm1.FormCreate(Sender: TObject); oQuery1 : TQuery; begin oQuery1 := TQuery.Create( self ); oQuery1.SQL.Clear; oQuery1.SQL.Add( 'SELECT * FROM test WHERE lastname = :"Last Name" ' ); ShowMessage( 'Parameter Name = ' + oQuery1.Params[0].Name ); end; The output of the above code is "Last", when it should be "Last Name". (Delphi 2009, and prior versions of Delphi would return "Last Name" properly.)

QC #: 77733 - Status: Closed

QC #: Project Date Reported: Area: 77733 Delphi 9/15/2009 Midas\TClientDataSet Description Steps:[QC Short Description] TClientDataSet does not stream out "empty" TWideStringField values properly [QC Description] TClientDataSet does not preserve empty string values when streaming out TWideStringField data. The empty strings are incorrectly converted into null values causing the IsNull property to return the wrong value. QC Entry 77733

TDBXWeaverBugsSuite.Native.DB.Test.exe connection=ibconnection -s:TestRaid_272894 -or- Compile and run this test case: program WideStringIsNullTest; {$APPTYPE CONSOLE} uses DB, DBClient, SysUtils; procedure IsNullTest; var CDS: TClientDataSet; begin CDS := TClientDataSet.Create(nil); try CDS.FieldDefs.Add('F1', ftWideString, 10); CDS.CreateDataSet; CDS.AppendRecord(['']); Assert(not CDS.Fields[0].IsNull, 'IsNull check before streaming'); CDS.Data := CDS.Data; Assert(not CDS.Fields[0].IsNull, 'IsNull check AFTER streaming'); finally CDS.Free; end; end; begin try IsNullTest; except on E: Exception do Writeln(E.ClassName, ': ', E.Message); end; end.

QC #: 77738 - Status: Closed

QC #: Project Date Reported: Area: 77738 Delphi 9/15/2009 Database Description Steps:[QC Short Description] PSQLTimeStampOffset Declaration Incorrect in SQLTimSt unit [QC Description] The PSQLTimeStampOffset declaration in the SQLTimSt unit: PSQLTimeStampOffset = ^TSQLTimeStamp; is incorrect. It should read: PSQLTimeStampOffset = ^TSQLTimeStampOffset; I'm not sure if this is the case in the shipped dcu, however, and I did not check it. QC Entry 77738

see SqlTimSt.pas Look at PSQLTimeStamp and PSQLTimeStampOffset define. PSQLTimeSTampOffset is wrong

QC #: 77765 - Status: Closed

QC #: Project Date Reported: Area: 77765 Delphi 9/16/2009 IDE\Project Management Description Steps:[QC Short Description] Removing files from project performance decreased [QC Description] There is a huge performance difference between D2009 and D2010 when you remove files from a project using the Project Manager or the OTA. -> see steps QC Entry 77765

- save the attached project files - start Delphi - open TestProject.dpr - multiselect the units TestUnit0001.pas till TestUnit0100.pas in the Project Manager - press the DEL key or call "Remove From Project" from the Project Manager popup menu expected: the operation is finished in less then a second actual: it takes more than two minutes to finish the operation (Vista x64 on and old Core2 Duo)

QC #: 77766 - Status: Closed

QC #: Project Date Reported: Area: 77766 Delphi 9/16/2009 Compiler\Delphi\Generics Description Steps:[QC Short Description] A const generic record parameter in a reference function doesn't compile QC Entry 77766

Compile the attached application below. See the following unexpected compile-time error. BTS272931.dpr(24) Error: E2010 Incompatible types: 'TMyFunc<TRegistration<System.Integer>,System.Boolean>' and 'Procedure' Change the "const" parameters on the lines marked #1 and #2 to value parameters, ie. remove the keyword "const", and see that the program compiles. program BTS272931; {$APPTYPE CONSOLE} uses SysUtils, Generics.Collections; type

TRegistration<T> = record Id: Integer; CreateFunc: T; end; type TMyFunc<T1, TResult> = reference To function(const Arg : T1) : TResult; //#1// procedure Test; var Func: TMyFunc<TRegistration<Integer>, Boolean>; begin Func := function(const Arg : TRegistration<Integer>) : Boolean //#2//begin end; end; begin WriteLn('PASS'); // PASS on compile // end.

QC #: 77773 - Status: Closed

QC #: Project Date Reported: Area: 77773 Delphi 9/16/2009 Compiler\Delphi\Generics Description Steps:[QC Short Description] F2084 Internal Error: C21504 (test case attached) [QC Description] Added by Sysop <<<<<<<<<<< if 'TEventReg.Detach<TProc<T1, T2>>(FSubscribers, Event);' is commented out, it does compile without error. ... ... Procedure TEvent<T1, T2>.Detach(Const Event : TProc<T1, T2>); Begin //TEventReg.Detach<TProc<T1, T2>>(FSubscribers, Event); End; >>>>>>>>>>> QC Entry 77773

Compile the attached application below. See the following unexpected compile-time error indicating failure. Fatal: F2084 Internal Error: C21504 program BTS272921; {$APPTYPE CONSOLE} uses Generics.Collections, SysUtils; type TArray = Class class procedure Delete<T>(Var X: TArray<T>; Index: Integer); static;end; TEventReg = Record public class Procedure Detach<T> (Var Events : TArray<T>; Const Value : T); static; end; TEvent<T1, T2> = Record private FSubscribers : TArray<TProc<T1, T2>>; public Procedure Detach(Const Event : TProc<T1, T2>); end; TTestEvent = TEvent<Integer, String>; class procedure TArray.Delete<T>(Var X: TArray<T>; Index: Integer); begin Finalize(X[Index]); end; class Procedure TEventReg.Detach<T>(Var Events : TArray<T>;

Const Value : T); var I : Integer; begin TArray.Delete<T>(Events, I); end; procedure TEvent<T1, T2>.Detach(Const Event : TProc<T1, T2>); begin TEventReg.Detach<TProc<T1, T2>>(FSubscribers, Event); end; begin WriteLn('PASS'); // PASS on compile // end.

QC #: 77820 - Status: Closed

QC #: Project Date Reported: Area: 77820 Delphi 9/18/2009 Midas\TClientDataSet Description Steps:`[QC Short Description] Dataset.locate on many fields and when one (or more field) is numeric doesnt work QC Entry 77820

TDBXFulcrumBugsSuite.Native.DB.Test.exe connection=ibconnection -s:TestRaid_274885 -OR- I Have a table with two fields I want to use to locate a record. When try to locate and one the column are integer locate will not find the record., but if I use only string columns it will work. Example: // search on integer fields if cdsMxDataSet.locate('articleIdNo;SortSeqNo', VarArrayOf([82888,1]),[] ) then showmessage('yes'); // Not working // search on string fields if cdsMxDataSet.locate('ArtNr;SortSeq', VarArrayOf(['10-12-12', '1']),[] ) then showmessage('yes'); // working

QC #: 77841 - Status: Closed

QC #: Project Date Reported: Area: 77841 Delphi 9/19/2009 IDE\Code Editor\ Description Steps:[QC Short Description] single instruction in "if" and "case" [QC Description] a great option could be to let single instruction in "then" clauses and case labels on a single line and to format everything else so this code if not Test then Exit; if dummy then begin dosomething end else dosomethingelse; case Prop of 0: Result := 'case zero';

[vk] Fixed #249981. see parameters in Delphi: - NewLineAfterLabelInCaseContents (additional new value NoForSingle) - "Line break after labels in case statements" - NewLineBeforeBeginInControlBlock - "Line break before Begin in structured statements" - NewLineBeforeSimpleInstructionInControlBlock (new parameter) - "Line break before simple instruction in structured statements and try-except blocks" For the testers - probably NewLineBeforeSimpleInstructionInControlBlock is it necessary to split to 2 parameters - for try-catch blocks and for structured statements?

1: begin Result := 'case one'; dosomethingagain; end; else Result := 'else case'; end; could be formatted as if not Test then Exit; if dummy then begin dosomething end else dosomethingelse; case Prop of 0: Result := 'case zero'; 1: begin Result := 'case one'; dosomethingagain; end; else Result := 'else case'; end; instead of if not Test then Exit; if dummy then begin dosomething end else dosomethingelse; case Prop of 0: Result := 'case zero'; 1: begin Result := 'case one'; dosomethingagain; end; else Result := 'else case'; end; QC Entry 77841

QC #: 77845 - Status: Closed

QC #: Project Date Reported: Area: 77845 Delphi 9/19/2009 VCL\Ribbon Controls Description Steps:[QC Short Description] Application Menu stay beyond save as dialog box [QC Description] Ribbon Application Menu stay beyond 'Save as' and 'Print' dialog boxQC Entry 77845

Open Ribbon demo run application click on Application menu click on Save As button (not on then arrow) Exp: Application menu is close Act: Application menu is show over save as dialog box NB: this happens in Delphi 2009 too

QC #: 77846 - Status: Closed

QC #: Project Date Reported: Area: 77846 Delphi 9/19/2009 VCL\Ribbon Controls Description Steps:

[QC Short Description] Acces violation on ribbon [QC Description] Acces violation on ribbon application menu QC Entry 77846

Open Ribbon demo run application click on Application menu click on Save As button (not on then arrow) change task (for example go to the delphi IDE) then return to Ribbon demo click on cancel from save as dialog box NB: this happens in Delphi 2009 too

QC #: 77898 - Status: Closed

QC #: Project Date Reported: Area: 77898 Delphi 9/21/2009 Compiler\Delphi\RTTI Description Steps:[QC Short Description] Invoke fails with Variant stored in a TValue as parameter [QC Description] TRttiMethod.Invoke fails to call the method correctly. The apparent cause it that variant is not getting loaded in the register correctly. Looking in Invoke() inside of RTTI.pas you will find PutArg() whichrequires the datasize to be returned or it places the item on the stack. TValue.DataSize returns 0 if a variant is stored in it. var vTest : Variant; vTest2 : TValue; begin vTest := '123'; vTest2 := TValue.From<Variant>(vTest); Writeln(SizeOf(Variant)); Writeln(vTest2.DataSize); end. Changing function TValue.GetDataSize: Integer; to return 4 for a variant allows this test case to work. .... tkMethod: Exit(8); tkInt64: Exit(8); tkVariant : Exit(4); else Exit(0); end; .... I don't believe this would be correct however, I think that DataSize may need to return the size of the data correctly, which would mean changing the TValue.GetDataSize from: ... tkArray, tkRecord, tkString : Exit(IValueData(FData.FHeapData).GetDataSize); ... tkArray, tkRecord, tkString,tkVariant : Exit(IValueData(FData.FHeapData).GetDataSize); Doing this, however would require changes on the Invoke() side to pass the parameters correctly. QC Entry 77898

Compile and run the attached application below. See the following program output indicating failure. FAIL #1 - Args[0].DataSize is Zero FAIL - Exception Error ClassName=EAccessViolation Message=Access violation at address 00406F22 in module 'BTS272964.exe'. Write of address 00000000 program BTS272964; { Invoke fails with Variant stored in a TValue as parameter } {$APPTYPE CONSOLE} uses Sysutils, Classes, TypInfo, Rtti; var Counter: Integer = 0; type TBookQuery = class(TObject) public function FindBook(ISBN : Variant;var Title : String) : Boolean; end; function TBookQuery.FindBook(ISBN : Variant;var Title : String) : Boolean; begin result := false; title := 'This line causes an A/V'; //#1// end; procedure DoTest; var ctx : TRttiContext; BQ : TBookQuery; Args : Array Of TValue; FindBook : TRttiMethod; RetSize: Integer; RetVal: Boolean; begin ctx := TRttiContext.Create; BQ := TBookQuery.Create; try FindBook := Ctx.GetType(TBookQuery.ClassInfo).GetMethod('FindBook'); SetLength(args,2); Args[0] := TValue.From<Variant>('123');

RetSize := Args[0].DataSize; // Note Zero!!! if RetSize = 0 then WriteLn('FAIL #1 - Args[0].DataSize is Zero') else Inc(Counter); Args[1] := ''; RetVal := FindBook.Invoke(BQ,Args).AsBoolean; if not RetVal then Inc(Counter) else WriteLn('FAIL #2 - Expected result not found'); finally BQ.Free; ctx.Free; end; end; begin try DoTest; if Counter = 2 then WriteLn('PASS') else WriteLn('FAIL Counter=', Counter); except on e : Exception do begin writeln('FAIL - Exception Error'); WriteLn(' ClassName=', E.ClassName); WriteLn(' Message=', E.Message); end; end; end.

QC #: 77903 - Status: Closed

QC #: Project Date Reported: Area: 77903 Delphi 9/21/2009 Compiler\Delphi\Interfaces Description Steps:[QC Short Description] Getting interface from record function from record returned by function generates incorrect code QC Entry 77903

1. Open attached project 2. Run it Expected text in console: About to call DoStuff Finished calling Dostuff About to call free TTest destroyed Finished calling free Actual: About to call DoStuff TTest destroyed Finished calling Dostuff About to call free Finished calling free DETAILS: If you can check generated code for Procedure DoStuff (Const A : THolder); 00406D23 33D2 xor edx,edx 00406D25 8955F8 mov [ebp-$08],edx 00406D28 8BD8 mov ebx,eax 00406D2A 8D45FC lea eax,[ebp-$04] 00406D2D 8B15BC6A4000 mov edx,[$00406abc] 00406D33 E80CECFFFF call @InitializeRecord you will see that firstly it initialize 2 temporary variable. One initialized with zero and one initialized via InitializeRecord. then you can see following generated code: InterfaceInRecord.dpr.59: A.GetWrapperRecord.DoStuff; //This line causes the problem 00406D46 8D55F8 lea edx,[ebp-$08] 00406D49 8BC3 mov eax,ebx 00406D4B E8B0FFFFFF call THolder.GetWrapperRecord 00406D50 8B45F8 mov eax,[ebp-$08] 00406D53 8945FC mov [ebp-$04],eax 00406D56 8D45FC lea eax,[ebp-$04] 00406D59 E846FFFFFF call TTestWrapper.DoStuff To call function THolder.GetWrapperRecord compiler passes ebp - $08 so this function will place result to that address. Then compiler by some reason generates code to copy everything located at [ebp - $08] to [ebp - $04] and then when its generate code to call TTestWrapper.DoStuff it passes ebp - $04 to it instead of ebp - $08 then later at hidden finalization there is following code: 00406D6B 8D45F8 lea eax,[ebp-$08] 00406D6E 8B15BC6A4000 mov edx,[$00406abc] 00406D74 B902000000 mov ecx,$00000002 00406D79 E8E2ECFFFF call @FinalizeArray

Compiler generates code which finalizes the record and its exact copy twice. as result this function increase reference count once and decrease it twice and TTestWrapper.FValue destroyed.

QC #: 77914 - Status: Closed

QC #: Project Date Reported: Area:77914 C++Builder 9/22/2009 IDE\Project Management\Project Options

Description Steps:[QC Short Description] Unable to clear a boolean option from an option-set in CB2010 [QC Description] Sometimes it is necessary to clear a boolean option from a set which means I don't want to change the value of the boolean option in any way. In CB2009 you could just press "Backspace" and the override would be removed from the option set. In CB2010 "Backspace" does nothing. In CB2010 you can only set the value to "false" or "true", but you can't change it to 'no change'. It seems there is no way to remove a "boolean" option from an option set in CB2010. QC Entry 77914

- Create option set - Set any boolean value to true or false - Try to clear that setting

QC #: 77934 - Status: Closed

QC #: Project Date Reported: Area:77934 C++Builder 9/22/2009 IDE\Project Management\Project Manager

Description Steps:[QC Short Description] Since CB2009 it is no longer possible to arrange "Virtual folders" [QC Description] In CB2007 it was possible to arrange virtual folders as wanted. Since CB2009 "virtual folders" can no longer rearranged. They always are sorted alphabetically. QC Entry 77934

- create project - create several virtual folders - try to move the virtual folders up or down via drag&drop

QC #: 77939 - Status: Closed

QC #: Project Date Reported: Area:77939 Delphi 9/22/2009 Database\Data Access Controls\TQuery

Description Steps:[QC Short Description] Error ParamByName result IsEmpty [QC Description] After being reviewed, I have encountered a problem in a TQuery, then add the data to PARAM this way: query1.ParamByName('name').AsString: = 'Boa'; query1.open; and then to validate the result with: if query1.IsEmpty ShowMessage ( 'Empty'); else

BAD: query1.ParamByName('name').AsString: = 'Boa'; query1.open; if query1.IsEmpty ShowMessage ( 'Empty'); else ShowMessage ( 'Not Empty'); GOOD: query1.ParamByName('name').Value: = 'Boa'; query1.open; then if query1.IsEmpty ShowMessage ( 'Empty'); else ShowMessage ( 'Not Empty');

ShowMessage ( 'Not Empty'); gives always empty because it does not filter well, but if it works well if I do this: query1.ParamByName('name').Value: = 'Boa'; query1.open; and then to validate the result with: then if query1.IsEmpty ShowMessage ( 'Empty'); else ShowMessage ( 'Not Empty'); It gives me the desired result. The query is, is this a modification of Delphi 2010 and earlier versions that no such breakdown, then it is a modification or some inconveniete surmountable with any update? How to solve this problem? Thank you. QC Entry 77939

QC #: 77948 - Status: Closed

QC #: Project Date Reported: Area: 77948 Delphi 9/22/2009 IDE\Code Editor\ Description Steps:[QC Short Description] Code Formatter Doesn't Handle Complier Defines [QC Description] The code formatter incorrectly formats code following a method that has two different signatures, dependant on a compiler definition. See the steps for how to replicate this. QC Entry 77948

Copy the following code into a new unit (adjust unit name to match) //////////////start ////////////////////////// unit unit2; {$DEFINE A_COMPILER_DEF} interface uses Windows, SysUtils, Classes, WideStrings; type TClass1 = class private public procedure MakeSomething; function GetSomething: Integer; {$IFDEF A_COMPILER_DEF} procedure Init(AValue: Integer); {$ELSE} procedure Init; {$ENDIF} end; implementation {$IFDEF A_COMPILER_DEF} procedure TClass1.Init(AValue: Integer); {$ELSE} procedure TClass1.Init; {$ENDIF} var Astring: string; begin Astring := 'A string value'; end; procedure TClass1.MakeSomething; var I: Integer; begin I := 123; end; function TClass1.GetSomething: Integer; begin Result := 123; end; end. ///////////////////// end ////////////////////////////////// Now click the Format Source item in the Edit menu. If you have the "Indent|Nested Routines" option set to true in the Delphi Options, all the code from the line procedure TClass1.Init; will be idented by two spaces. I.e. the code formatter thinks the second version of the method signature is a nested method and never recovers. //////////////start ////////////////////////// unit unit2; {$DEFINE A_COMPILER_DEF} interface uses Windows, SysUtils, Classes, WideStrings; type TClass1 = class private public procedure MakeSomething; function GetSomething: Integer; {$IFDEF A_COMPILER_DEF} procedure Init(AValue: Integer); {$ELSE} procedure Init; {$ENDIF} end; implementation {$IFDEF A_COMPILER_DEF} procedure TClass1.Init(AValue: Integer); {$ELSE} procedure TClass1.Init; {$ENDIF} var Astring: string; begin Astring := 'A string value'; end; procedure TClass1.MakeSomething; var I: Integer; begin I := 123; end; function TClass1.GetSomething: Integer; begin Result := 123; end; end. //////////////end ////////////

QC #: 77950 - Status: Closed

QC #: Project Date Reported: Area:77950 Delphi 9/22/2009 Compiler\Delphi\RTTI\Custom attributes

Description Steps:[QC Short Description] Compile the attached application below.

Internal compiler error with Attributes and set types [QC Description] TCustomAttribute descendants cannot take Set types as parameters. Attempting to do so results in an internal compiler error : [DCC Fatal Error] Unit1.pas(29): F2084 Internal Error: TI2357 QC Entry 77950 (JJS: Expected in delivery after 14.0.3565.25148.2)

See the following compile-time error indicating failure. Fatal: F2084 Internal Error: TI2357 program BTS273022; {$APPTYPE CONSOLE} uses SysUtils; type TTestEnum = (enOne,enTwo); TTestSet = set of TTestEnum; TSimpleAttribute = class(TCustomAttribute) private FSet : TTestSet; public constructor Create(const AValue : TTestSet); property SetTest : TTestSet read FSet; end; [TSimpleAttribute([enOne,enTwo])] TForm1 = class end; var Form1: TForm1; begin WriteLn('PASS'); { PASS on compile } end.

QC #: 77961 - Status: Closed

QC #: Project Date Reported: Area: 77961 Delphi 9/23/2009 IDE\Search\Find Description Steps:[QC Short Description] Add a hotkey for "Search from beginning" in search bar [QC Description] The "Search from beginning" button in the Search Bar has no hotkey associated with it. If you want to search from the beginning you have to use the mouse which should not be necessary. QC Entry 77961

QC #: 77969 - Status: Closed

QC #: Project Date Reported: Area: 77969 Delphi 9/23/2009 RTL\Delphi\WinAPI Description Steps:(JJS: Fix may not apply to Weaver Update 2 builds) [QC Short Description] RTL Source is full of syntax issues with procedure modifiers involving stdcall. [QC Description] While I tried to understand why error insight is always showing

Issue a recursive text search in folder c:\Program Files\CodeGear\RAD Studio\6.0\source\ (or where you installed them) for pattern: t stdcall (t space stdcall) or n stdcall (n space stdcall) This will list many source files with such errors: function CoRevokeMallocSpy: HResult stdcall; TGetChildCallback = function (Param: Pointer; ComponentInterface: TIComponentInterface): Boolean stdcall; There is also 'stdcall stdcall' typo. (Of course you can try all letters before stdcall to see all possible errors)

'Cannot resolve unit name 'xxx' I found that in the RTL source code there are many missing semicolons before a lot of 'stdcall'. The problems are mostly the missing semicolon before stdcall. Or stdcall stdcall typo. Some files that are affected (list is _not_ complete, see Steps) Windows.pas ActiveX.pas Controls.pas ComServ.pas CommDlg.pas MMSystem.pas Ole2.pas OleCtl.pas OleDlg.pas AxCtrls.pas Forms.pas QC Entry 77969

QC #: 77991 - Status: Closed

QC #: Project Date Reported: Area: 77991 C++Builder 9/23/2009 IDE\Code Editor Description Steps:[QC Short Description] Editor works incorrect if there is a "\0" symbol inside a string expression. [QC Description] If there is a "\0" while declare a char/TCHAR string, the editor always append a '}' symbol after press [ENTER] key. And the symbol to Collapse/Expand source the following functions disappear. However, Compiler/Build is not affected. QC Entry 77991

1. Create a new "Console Application "project. It shows the default source like this: int _tmain(int argc, _TCHAR* argv[]) { return 0; } 2. Add a declare inside _tmain() char test_array[] = "this is test!\n\0"; 3. Press [ENTER] key outside the _tmain(), an '}' char automatically appended. But it is incorrect. 4. Remove the '}' character. Append a void function define for test only like this: void Test(void) { } Notice that there is a collapse/expand symbol in front of the function _tmain(). But is is not appear in front of the function Test().

QC #: 78006 - Status: Closed

QC #: Project Date Reported: Area: 78006 Delphi 9/24/2009 Compiler\Delphi\Generics Description Steps:[QC Short Description] Local array type definition produces an Internal AV error at compile-time. Global okay. [QC Description] If a generic list is implemented for an array type, and they're declared locally inside a procedure, the compiler will complain about incompatible types when trying to add an item to the list. QC Entry 78006

Compile the attached application below. See the following compile-time error indicating failure. Fatal: F2084 Internal Error: AV00487C33-R00000000-0 program BTS273024; {$APPTYPE CONSOLE} uses Generics.Collections, SysUtils; procedure Test(); type TMyArray = array[0..2] of Integer; TMyArrayList = TList<TMyArray>; var

LMyArray: TMyArray; LMyArrayList: TMyArrayList; begin LMyArrayList := TMyArrayList.Create(); LMyArrayList.Add(LMyArray); FreeAndNil(LMyArrayList); end; begin try Test(); except on E:Exception do Writeln(E.Classname, ': ', E.Message); end; end.

QC #: 78015 - Status: Closed

QC #: Project Date Reported: Area: 78015 Delphi 9/24/2009 RTL\Delphi\WinAPI Description Steps:[QC Short Description] MINENUMSIZE missing in DirectShow and DirectX units [QC Description] Delphi 2010 includes many new DirectShow and DirectX units that were taken from my site at http://tib.s.songbeamer.eu/downloads/DSPack.zip These units used to include the file DirectX.inc which also defines $MINENUMSIZE 4. These files depend on MINENUMSIZE 4 and will definitely not work without it. QC Entry 78015 trunk rev: 24885 update rev: 24886

** See comments for different test case ** Compile and run the following console app with src\DirectX9 and alsowith ...\RAD Studio\7.0\source\Win32\rtl\win. In rtl.bpl is ...\source\Win32\rtl\win included... program DSFilterTest; {$APPTYPE CONSOLE} uses SysUtils, DSPack, DSUtils; var F: TFilter; SysDevEnum: TSysDevEnum; begin SysDevEnum := TSysDevEnum.Create; SysDevEnum.SelectIndexCategory(0); F := TFilter.Create(nil); F.BaseFilter.Moniker := SysDevEnum.GetMoniker(2); IFilter(F).NotifyFilter(foAdding); IFilter(F).NotifyFilter(foRemoving); end.

QC #: 78036 - Status: Closed

QC #: Project Date Reported: Area: 78036 Delphi 9/24/2009 IDE\Desktop Layouts Description Steps:[QC Short Description] Component Toolbar won't stay "gone..." [QC Description] The Component Toolbar (located under the main menu [File, Edit, Search, etc...]) does not stay "gone" when removed. Typically, I would expect that I could right click the Component Toolbar's handle, (or anywhere in the toolbar,) and deselect the

Start the IDE Switch to Classic Undocked Layou // Component Toolbar appears View | Toolbars and uncheck "Component" Save the desktop layout Shutdown and restart IDE // Exp: Component Toolbar not shown // Act: It is.

checkmark to show the Component toolbar to hide it. I would expect that I should save my desktop layout, and be able to close out Delphi, and reopen it, and have the Component Toolbar remain hidden. Instead, the Component Toolbar is again visible, as though none of my layout preferences were saved. QC Entry 78036

QC #: 78041 - Status: Closed

QC #: Project Date Reported: Area: 78041 Delphi 9/25/2009 Midas\TClientDataSet Description Steps:[QC Short Description] Using GotoBookmark with TClientDataset raise "Record not found" exception [QC Description] I encounter a situation using TClientDataSet.GotoBookmark in Delphi 2010 and a "Record Not Found" exception raised. This problem doesn't happen to Delphi 2007 and Delphi 2009. Please run the following test case to replay the problem. I suspect the problem is related to Delphi 2010 midas.dll. If you have Delphi 2007, 2009 and 2010 install on the machine, make sure you add midaslib into the probject file in order to test with correct version of midas library. QC Entry 78041

TDBXWeaverBugsSuite.Native.DB.Test.exe connection=ibconnection -s:TestRaid_273067 -or- Please run the following test case: var D: TClientDataSet; B: TBookmark; i: Integer; begin D := TClientDataSet.Create(nil); try D.FieldDefs.Add('SWID', ftInteger); D.CreateDataSet; for i := 1 to 5 do D.AppendRecord([i]); // go to any record D.RecNo := 3; // obtain bookmark of current record B := D.GetBookmark; // modify current record D.Edit; D.FindField('SWID').AsInteger := 10; D.Post; // go to last bookmark will raise exception D.GotoBookmark(B); finally D.Free; end; end;

QC #: 78058 - Status: Closed

QC #: Project Date Reported: Area: 78058 C++Builder 9/25/2009 Compiler\C++ Description Steps:[QC Short Description] Massive performance drop in C++ compiler from CB2009 to CB2010 [QC Description] After converting my projects from CB2009 to CB2010 I noticed that compilation times were significantly longer in CB2010 in comparison to CB2009. After reading an article from another user in the newsgroups (https://forums.embarcadero.com/thread.jspa?threadID=25040&tstart=0) I spent some time investigating.

- open projects in CB2009 & CB2010 - compile 'testUnit1.cpp' two times (to ensure precompiled headers are loaded) - compare second run compilation times

I attached two example-projects which contain the same sources. CB2009 takes only half as long to compile the source in question (testUnit1.cpp). In this example the difference is about one second, but in larger and more complex sources this difference grows. One of my projects now takes about 4 minutes to compile with CB2010 and only one minute in CB2009. QC Entry 78058

QC #: 78075 - Status: Closed

QC #: Project Date Reported: Area: 78075 Delphi 9/25/2009 10:33:32 AM Install\Files Description Steps: The following dcu files are not being installed: cor.dcu CorError.dcu CorHdr.dcu D3DX8.dcu D3DX9.dcu Direct3D.dcu Direct3D8.dcu Direct3D9.dcu DirectDraw.dcu DirectInput.dcu DirectMusic.dcu DirectPlay8.dcu DirectShow9.dcu DirectSound.dcu DX7toDX8.dcu DxDiag.dcu DXFile.dcu DXTypes.dcu WMF9.dcu

QC #: 78086 - Status: Closed

QC #: Project Date Reported: Area: 78086 C++Builder 9/26/2009 CodeGuard Description Steps:[QC Short Description] "invalid stack" error triggered by sscanf [QC Description] Running this code char *temp = "1/1/09"; int d, m, y, r; r = sscanf(temp, "%d%*c%d%*c%d", &d, &m, &y); Produces this from CodeGuard Access in invalid stack in process: Project1.exe(5460) - Unit1.cpp#22Attempt to access 20 byte(s) at 0x0012F4BC. 0x3296726C Call to [via 0x00404896] sscanf(0x004051B8, 0x004051BF ["%d%*c%d%*c%d"], 0x12F4E0 [1242336], 0xFFFFFFD8 ['?'], 0x12F4D0 [1242320], 0xFFFFFF98 ['?'], 0x77A5B539 [2007348537], ...) Same problem in C++Builder 2007. The issue seems to be the

bcc32 -vG 273060.cpp 273060.exe exp: no errors from codeguard act: Access in invalid stack in process: Project1.exe(5460) - Unit1.cpp#22Attempt to access 20 byte(s) at 0x0012F4BC. 0x3296726C Call to [via 0x00404896] sscanf(0x004051B8, 0x004051BF ["%d%*c%d%*c%d"], 0x12F4E0 [1242336], 0xFFFFFFD8 ['?'], 0x12F4D0 [1242320], 0xFFFFFF98 ['?'], 0x77A5B539 [2007348537], ...)

handling of the "%*c" specifiers. QC Entry 78086

QC #: 78091 - Status: Closed

QC #: Project Date Reported: Area: 78091 Delphi 9/26/2009 Compiler\Delphi\Generics Description Steps:[QC Short Description] cannot assign a NIL to a generic variable [QC Description] A result of a generic type even when constrained will not accept nil as a result. (JJS: May also be related to RAID 270229 per Uwe Schuster) QC Entry 78091

Compile and run the attached application below. See the following compile-time errors indicating failure. BTS273074.dpr(22) Error: E2010 Incompatible types: 'T' and 'Pointer'BTS273074.dpr(22) Error: E2015 Operator not applicable to this operand type BTS273074.dpr(23) Error: E2089 Invalid typecast The errors are indicated for the lines marked #1, #2, and #3 in the source. On line #4, the assignment of a local variable cast to the parameter type represents a workaround. Setting Result to Default(T) will also compile-time as expected program BTS273074; { cannot assign a NIL to a generic variable } {$APPTYPE CONSOLE} uses SysUtils, Classes; type TMyClass = class function Test<T: TList>:T; end; function TMyClass.Test<T>: T; var a : TObject; begin Result := nil //#1 Compile will Fail here Result := nil as T; //#2 Fail again Result := T(nil); //#3 Fail too a := nil; //Workaround// Result := T(a); //#4 Compile will pass here end; procedure DoTest; var MyClass: TMyClass; List: TList; begin MyClass := TMyClass.Create; List := MyClass.Test<TList>; if List = nil then WriteLn('PASS') else WriteLn('FAIL #1'); end; begin try DoTest;

except on E: Exception do begin WriteLn('FAIL - Exception Error'); WriteLn(' ClassName=', E.ClassName); WriteLn(' Message=', E.Message); end; end; end.

QC #: 78094 - Status: Closed

QC #: Project Date Reported: Area:78094 Delphi 9/26/2009 IDE\Code Editor\Error Insight Description Steps:[QC Short Description] "Expected ... but received ..." with boolean expressions with more two parts [QC Description] Valid boolean expressions with more then two parts lead to "Expected ... but received ..." errors. -> see steps QC Entry 78094

- save the following code at the end of the steps as BooleanExpressionTest.dpr - start Delphi - open BooleanExpressionTest.dpr - compile (it should compile) expected: no Error Insight errors in the Structure view and the editor actual: Expected ) but received = at line 17 (17:16) Expected END but received ) at line 17 (17:22) after commenting out line 17 the next error is Expected THEN but received = at line 18 (18:12) program BooleanExpressionTest; {$APPTYPE CONSOLE} var X, Y: Integer; begin X := 1; Assert((X <> 1) = False, 'X should be one'); if (X = 0) = True then WriteLn('X = 0') else if (X <> 0) = True then WriteLn('X <> 0'); Y := 0; Assert(Y = 0 = True); if Y = 1 = False then WriteLn('Y <> 1') else if Y <> 1 = False then WriteLn('Y = 1'); ReadLn; end.

QC #: 78095 - Status: Closed

QC #: Project Date Reported: Area: 78095 Delphi 9/26/2009 Compiler\Delphi\Generics

Description Steps:[QC Short Description] F2084 Internal Error: T888 with overloaded functions in a generic class that define an anon method that does use the func param [QC Description] I've noticed an issue with overloaded functions in a generic class that creates an anonymous method that uses the function param while playing with the code from the thread "Problems with the Delphi 2010 Compiler" in .public.delphi.non-technical https://forums.embarcadero.com/thread.jspa?messageID=163492&tstart=0#163492Message-ID: <[email protected]> -> see steps QC Entry 78095

- save the following two files or the attachment - dcc32 BTS273075.dpr expected: it compiles actual: BTS273075.dpr(19) Fatal: F2084 Internal Error: T888 Additional notes: The error goes away with one of the following modifications: - turn TGenericList<T> into a normal class by removing the "<T>" type parameter - remove the overload and name the methods Sort1 and Sort2 - don't use the function parameter in one of the anon methods (commenting out line 28 ["Comparer.Compare;"] leads to "T888.dpr(10) Fatal: F2084 Internal Error: AV00487031-R00000000-0") unit uBTS273075; interface type TProc = reference to procedure; IComparer = interface procedure Compare; end;

TComparerFunc = procedure; TGenericList<T> = class(TObject) public procedure Sort(Comparer: IComparer); overload; procedure Sort(Comparer: TComparerFunc); overload; end; implementation procedure TGenericList<T>.Sort(Comparer: IComparer);var Proc: TProc; begin Proc := procedure begin Comparer.Compare; end; end; procedure TGenericList<T>.Sort(Comparer: TComparerFunc); var Proc: TProc; begin Proc := procedure begin Comparer; end; end; end. program BTS273075; { F2084 Internal Error: T888 with overloaded functions in a generic class that define an anon method that does use the func param } {$APPTYPE CONSOLE} uses uBTS273075; var GenericList: TGenericList<TObject>; begin GenericList := TGenericList<TObject>.Create; GenericList.Free; WriteLn('PASS'); end.

QC #: 78112 - Status: Closed

QC #: Project Date Reported: Area: 78112 Delphi 9/27/2009 Compiler\Delphi\Generics Description Steps:[QC Short Description] TypeInfo() does not work with specialized generics types, even though type info has clearly been generated for these types QC Entry 78112

program Generics7; {$APPTYPE CONSOLE} uses RTTI; type IGenInterface<T> = interface(IInvokable) function GenInterface: T; end; TGenRecord<T> = record GenRecord: string; end; TGenClass<T> = class GenClass: string; end; IGenInterfaceString = IGenInterface<string>; TGenRecordString = TGenRecord<string>; TGenClassString = TGenClass<string>; TContainer = record GenInterface: IGenInterfaceString; GenRecord: TGenRecordString;

GenClass: TGenClassString; end; var ctx: TRttiContext; begin with ctx.GetType(TypeInfo(TContainer)).AsRecord do begin Assert(Length(GetFields) = 3); Assert(GetFields[0].FieldType.ToString = 'IGenInterface<System.string>'); Assert(GetFields[1].FieldType.ToString = 'TGenRecord<System.string>'); Assert(GetFields[2].FieldType.ToString = 'TGenClass<System.string>'); end; //[DCC Error] Generics7.dpr(43): E2134 Type 'IGenInterfaceString' has no type info Assert(ctx.GetType(TypeInfo(IGenInterfaceString)).ToString = 'IGenInterface<System.string>'); //[DCC Error] Generics7.dpr(46): E2134 Type 'TGenRecordString' has no type info Assert(ctx.GetType(TypeInfo(TGenRecordString)).ToString = 'TGenRecord<System.string>'); //[DCC Error] Generics7.dpr(49): E2134 Type 'TGenClassString' has no type info Assert(ctx.GetType(TypeInfo(TGenClassString)).ToString = 'TGenClass<System.string>'); end.

QC #: 78122 - Status: Closed

QC #: Project Date Reported: Area: 78122 Delphi 9/27/2009 IDE\Code Editor\ Description Steps:[QC Short Description] Not mandatory missing semi colon not handled correctly [QC Description] if we missed a semi colon at not mandatory posifion, formatter add extra indentation to next lines following code: procedure Test; begin try if flag then begin end // missing (but not mandatory) semi colon at end of the previous line finally end; end; is formated as procedure Test; begin try if flag then begin end finally end; end; QC Entry 78122

QC #: 78124 - Status: Closed

QC #: Project Date Reported: Area: 78124 Delphi 9/27/2009 RTL\Delphi\WinAPI Description Steps:[QC Short Description] ksproxy.h from windows SDK:

DirectShow9 IKSControl declared wrong [QC Description] The IksControl interface in DirectShow9.pas needs to be changed to using functions: Currently: IKsControl = interface(IUnknown) ['{28F54685-06FD-11D2-B27A-00A0C9223196}'] (*** IKsControl methods ***) procedure KsProperty(Property_: PKSPROPERTY; PropertyLength: ULONG; PropertyData: Pointer; DataLength: ULONG; out BytesReturned: ULONG); stdcall; procedure KsMethod(Method: PKSMETHOD; MethodLength: ULONG; MethodData: Pointer; DataLength: ULONG; out BytesReturned: ULONG); stdcall; procedure KsEvent({OPTIONAL}Event: PKSEVENT; EventLength: ULONG; EventData: Pointer; DataLength: ULONG; out BytesReturned: ULONG); stdcall; end; Should be: IKsControl = interface(IUnknown) ['{28F54685-06FD-11D2-B27A-00A0C9223196}'] (*** IKsControl methods ***) function KsProperty(Property_: PKSPROPERTY; PropertyLength: ULONG; PropertyData: Pointer; DataLength: ULONG; out BytesReturned: ULONG): HResult; stdcall;function KsMethod(Method: PKSMETHOD; MethodLength: ULONG; MethodData: Pointer; DataLength: ULONG; out BytesReturned: ULONG): HResult; stdcall;function KsEvent({OPTIONAL}Event: PKSEVENT; EventLength: ULONG; EventData: Pointer; DataLength: ULONG; out BytesReturned: ULONG): HResult; stdcall;end; QC Entry 78124 trunk rev: 24910 update rev: 24916

DECLARE_INTERFACE_(IKsControl, IUnknown) { STDMETHOD(KsProperty)( THIS_ IN PKSPROPERTY Property, IN ULONG PropertyLength, IN OUT LPVOID PropertyData, IN ULONG DataLength, OUT ULONG* BytesReturned ) PURE; STDMETHOD(KsMethod)( THIS_ IN PKSMETHOD Method, IN ULONG MethodLength, IN OUT LPVOID MethodData, IN ULONG DataLength, OUT ULONG* BytesReturned ) PURE; STDMETHOD(KsEvent)( THIS_ IN PKSEVENT Event OPTIONAL, IN ULONG EventLength, IN OUT LPVOID EventData, IN ULONG DataLength, OUT ULONG* BytesReturned ) PURE; }; #define STDMETHOD(method) HRESULT (STDMETHODCALLTYPE * method)

QC #: 78125 - Status: Closed

QC #: Project Date Reported: Area:78125 Delphi 9/27/2009 Compiler\Delphi\RTTI Description Steps:[QC Short Description] RTTI reports const parameters wrong [QC Description] - untyped consts parameters are reported as var parameters- typed const parameters are reported without the "const" While this doesn't make a difference in regards to how parameters are passed in, it does make a difference if RTTI information is used to dynamically implement a method or interface. QC Entry 78125

Compile and run the attached program whose fragments are seen below. FAIL #10 S=var c FAIL #13 S=i: IBar FAIL Counter=11 See that typed and untyped const parameters are not represented corrected. program BTS273062; {$APPTYPE CONSOLE} uses SysUtils, RTTI; var Counter: Integer = 0; type

IBar = interface ['{FF5F7264-25EB-4C22-B6BE-922525A76D57}'] end; TFoo = class procedure ParamConst(const c); procedure ParamVar(var v); procedure ParamOut(out o); procedure ParamConstIntf(const i: IBar); end; ... procedure DoTest; var ctx: TRttiContext; S: String; I: Integer; begin I := Length(ctx.GetType(TypeInfo(TFoo)).GetDeclaredMethods); if I = 4 then Inc(Counter) else WriteLn('FAIL #1'); ... //error, returns 'var c' S := ctx.GetType(TypeInfo(TFoo)).GetDeclaredMethods[0].GetParameters[0].ToString;if S = 'const c' then Inc(Counter) else WriteLn('FAIL #10 S=', S); //ok S := ctx.GetType(TypeInfo(TFoo)).GetDeclaredMethods[1].GetParameters[0].ToString;if S = 'var v' then Inc(Counter) else WriteLn('FAIL #11'); //ok S := ctx.GetType(TypeInfo(TFoo)).GetDeclaredMethods[2].GetParameters[0].ToString;if S = 'out o' then Inc(Counter) else WriteLn('FAIL #12'); //error, returns 'i: IBar' S := ctx.GetType(TypeInfo(TFoo)).GetDeclaredMethods[3].GetParameters[0].ToString;if S = 'const i: IBar' then Inc(Counter) else WriteLn('FAIL #13 S=', S); end; ...

QC #: 78136 - Status: Closed

QC #: Project Date Reported: Area: 78136 Delphi 9/27/2009 IDE Description Steps:[QC Short Description] Open project with multiple units. Open the Search for Units dialog by

Problem using Shift key multi-select in Search for Units/Forms dialogs [QC Description] If you open the 'Search for Units' or 'Search for Forms' dialogs (View->Units and View->Forms), when you try and multi-select a number of forms/units, the OK button is always disabled once you select more than one unit/form. So, it is not possible to make contiguous multi-selections with the shift key. If you use the Ctrl key then you can make multi-selections, but you have to click on each file individually. QC Entry 78136

choosing Units from the View menu. Click on the first unit then hold down shift and click on the last unit. The selection is made but the OK button becomes disabled.

QC #: 78149 - Status: Closed

QC #: Project Date Reported: Area: 78149 Delphi 9/28/2009 Compiler\Delphi\RTTI Description Steps:REGRESSION [QC Short Description] F2084 Internal Error: L817 when defining an own IEnumerable<T> interface and using a class that does use the original IEnumerable<T> Additional internal note by USc: This is regression that happened between FT build 3417 (revision 21151) and 3449 (revision 21988) [QC Description] The attached demo project can be compiled but failed to be linked with the error message: [DCC Fatal Error] F2084 Internal Error: L817 After the failed linking, it will be ok to make it again. more details, please see the source code "ProblemUnit.pas" QC Entry 78149

Steps by USc: - extract the attached files from the subdir simplified - dcc32 -B InternalError_L817.dpr expected: it compiles actual: Fatal: F2084 Internal Error: L817 Additional notes: - the error disappears with one of the following modifications: o rename the new IEnumerable interface o comment the ICollection var in ProblemUnit.pas (from original unit) o define a type alias for the closed constructedl TListAdapter<T> type (from original unit) - the original testcase creates the L817 error also with every second make (dcc32 -M) Original steps using the test case in subdir original: 1. Open the attached project "InternalError_L817.dpr" 2. Build the project 3. Linking Failed...

QC #: 78156 - Status: Closed

QC #: Project Date Reported: Area: 78156 Delphi 9/28/2009 RTL\Delphi\WinAPI Description Steps:[QC Short Description] D3DX9.pas D3DXVec2Minimize and D3DXVec2Maximize return wrong result [QC Description] D3DXVec2Minimize and D3DXVec2Maximize in D3DX9.pas assign values to vOut.y instead of vOut.x QC Entry 78156 trunk rev: 24908 update rev: 24915

function D3DXVec2Minimize(out vOut: TD3DXVector2; const v1, v2: TD3DXVEctor2): PD3DXVector2; begin if v1.x < v2.x then vOut.x:= v1.x else vOut.y:= v2.x; // <-- BAD (vOut.y is changed) if v1.y < v2.y then vOut.y:= v1.y else vOut.y:= v2.y; Result:= @vOut; end; function D3DXVec2Minimize(out vOut: TD3DXVector2; const v1, v2: TD3DXVEctor2): PD3DXVector2; begin if v1.x < v2.x then vOut.x:= v1.x else vOut.x:= v2.x; // <-- OK if v1.y < v2.y then vOut.y:= v1.y else vOut.y:= v2.y; Result:= @vOut; end; -------------------------------------------- // Maximize each component. x = max(x1, x2), y = max(y1, y2) function D3DXVec2Maximize(out vOut: TD3DXVector2; const v1, v2: TD3DXVector2): PD3DXVector2; begin if v1.x > v2.x then vOut.x:= v1.x else vOut.y:= v2.x; // <-- BAD (vOut.y is changed) if v1.y > v2.y then vOut.y:= v1.y else vOut.y:= v2.y; Result:= @vOut; end; // Maximize each component. x = max(x1, x2), y = max(y1, y2) function D3DXVec2Maximize(out vOut: TD3DXVector2; const v1, v2: TD3DXVector2): PD3DXVector2; begin if v1.x > v2.x then vOut.x:= v1.x else vOut.x:= v2.x; // <-- OK if v1.y > v2.y then vOut.y:= v1.y else vOut.y:= v2.y; Result:= @vOut; end;

QC #: 78157 - Status: Closed

QC #: Project Date Reported: Area: 78157 Delphi 9/28/2009 RTL\Delphi\WinAPI Description Steps:[QC Short Description] Update DirectX headers to the latest version [QC Description] Update DirectX headers to the latest version from http://tib.s.songbeamer.eu/downloads/DSPack.zip Changes include an update to the latest DirectX version, some bugfixes and some unicode bugfixes. Care should be taken because of bugfixes that are in the codegear version of the units, but not in the dspack DirectX units. Also the dspack DirectX units are using a newer version of the d3dx9_33.dll dll. QC Entry 78157 trunk rev: 24914 update rev: 24917

Examples: Direct3D8.pas, DirectDraw.pas INCORRECT (Using Char instead of ansichar) function MAKEFOURCC(ch0, ch1, ch2, ch3: Char): DWord; begin Result:= Byte(ch0) or (Byte(ch1) shl 8) or (Byte(ch2) shl 16) or (Byte(ch3) shl 24 ); end; CORRECT: function MAKEFOURCC(ch0, ch1, ch2, ch3: AnsiChar): DWord; begin Result:= Byte(ch0) or (Byte(ch1) shl 8) or (Byte(ch2) shl 16) or (Byte(ch3) shl 24 ); end;

QC #: 78182 - Status: Closed

QC #: Project Date Reported: Area: 78182 Delphi 9/29/2009 Compiler\Delphi Description Steps:[QC Short Description] "Compile All" and "Build All" commands are produced the different exe-file when using packages Additional internal note by USc: This is regression that happened between FT build 3478 (revision 22926) and 3494 (revision 23552) [QC Description] -> see steps QC Entry 78182 (JJS: Expected in delivery after 14.0.3565.25148.2)

Steps by USc: - save the attached files from the dir "simplified" - dcc32 -B package1.dpk - dcc32 -B -LUrtl;package1 project1.dpr - execute project1.exe expected: the output is PASS actual: message box "...\project1.exe is no valid Win32-App" and output "Access denied" on the command line (messages translated from german) - dcc32 -M -LUrtl;package1 project1.dpr - execute project1.exe expected: the output is PASS actual: the output is PASS - save the attached files from the dir "original" - start Delphi 1) Open attached project group "Test_20090929" 2) Select Project1 as active project 3) Click "Project -> Build All" 4) Click "Run -> Run". See the results. (i got the message like "Unable to create process: <Path>\Project1.exe: is not valid Win32 application") 5) Click "Project -> Compile All" 6) Click "Run -> Run". See the results. (all is fine. Project1.exe is started as expected.)

QC #: 78188 - Status: Closed

QC #: Project Date Reported: Area: 78188 Delphi 9/29/2009 Database\DBExpress Description Steps:[QC Short Description] List index out of bounds if only some fields are persistent [QC Description] If you have a SELECT * but only create persistent fields for some columns, Delphi 2010 gives a &quot;List index out of bounds&quot; when you open the clientdataset. This worked in previous versions. According to Dmitry Arefiev, this may be the problem:

TGUIFulcrumBugsSuite.Zombie.DB.Test.exe connection=oracleconnection -s:TestRaid_273138 -or- Open and run raid273138.zip push the button exp: to show recordcount act: shows error message as described

As I see, the problem is in TCustomSQLDataSet.GetFieldData. There are few places, where the code is accessing to the dataset fields as &quot;Fields[Ordinal]&quot;. But there Ordinal is FieldNo-1 and not a index. Instead must be used Fields.FieldByNumber(FieldNo). This issue is introduced in D2010 - in D2009 there is no such issue. QC Entry 78188

-or- Run this script in Oracle10 to create the table: {code} CREATE TABLE MITABLA -- TABLE WITH 4 FIELDS ( CAMPO1 VARCHAR2(10) NOT NULL, CAMPO2 VARCHAR2(250) NOT NULL, CAMPOFECHA DATE NOT NULL, CAMPO4 VARCHAR2(10) NOT NULL, CONSTRAINT PKMITABLA PRIMARY KEY (CAMPO1, CAMPO2) ) And insert some data: / INSERT INTO MITABLA VALUES ('CAMPO UNO', 'CAMPO DOS', SYSDATE, 'CAMPO CUA'); / {code} Change the attached program to use your user and password. Run the program and press Button1: Expected: showmessage should show a 1. Actual: list index out of bounds(3) This is the call stack: {code} :7c812afb kernel32.RaiseException + 0x52 :0043ce6e TList.Get + $1A :0043ce6e TList.Get + $1A :005989b4 TCustomSQLDataSet.GetFieldData + $134 :005006d6 TDataSet.GetFieldData + $E2 :0050fa95 TDataPacketWriter.PutWideStringField + $45 :00513012 TDataPacketWriter.GetDataPacket + $42 :00515b78 TDataSetProvider.CreateDataPacket + $70 :005143b3 TBaseProvider.InternalGetRecords + $43 :005157ef TDataSetProvider.InternalGetRecords + $E7 :00513e0d TCustomProvider.DoGetRecords + $61 :00513da3 TCustomProvider.GetRecords + $2F :0051ac15 TLocalAppServer.AS_GetRecords + $51 :0052998f TCustomClientDataSet.DoGetRecords + $C3 :00520ca8 TCustomClientDataSet.OpenCursor + $1BC :004ff86b TDataSet.SetActive + $5B :004ff6b2 TDataSet.Open + $A :004919f5 TControl.Click + $75 :00495d4d TWinControl.WndProc + $56D :0046d091 TButtonControl.WndProc + $71 :00495ea0 DoControlMsg + $28 :00495d4d TWinControl.WndProc + $56D :004b6369 TCustomForm.WndProc + $599 :004953eb TWinControl.MainWndProc + $2F :0044a50e StdWndProc + $16 :7e398734 USER32.GetDC + 0x6d :7e398816 ; C:\WINDOWS\system32\USER32.dll

QC #: 78189 - Status: Closed

QC #: Project Date Reported: Area: 78189 Delphi 9/29/2009 Compiler\Delphi\Generics Description Steps:[QC Short Description] 'Implements' keyword does not work with generic interface

(* The following code produces the error: *) IMyInterface<T>; = interface function GetValue: T; end; TMyClassA<T>; = class(TInterfacedObject, IMyInterface<T>) public function GetValue:

[QC Description] Attempting to use the 'implements' keyword to let a class member provide the implementation of an interface does not work with generic interfaces as it would without generics. Code attempting to let an instance of a generic class 'implement' a generic interface does not compile, emitting instead two errors on the line containing the property that 'implements' the interface. QC Entry 78189

T; end; TMyClassB<T> = class(TInterfacedObject, IMyInterface<T>) private FMyClassA: TMyClassA<T>; public property MyClassA: TMyClassA<T> read FMyClassA implements IMyInterface<T>; end; (* Compiling the above three classes raises two errors: E2259 Implements clause only allowed for properties of class or interface type E2086 Type 'IMyInterface<T>' is not yet completely defined *)

QC #: 78205 - Status: Closed

QC #: Project Date Reported: Area: 78205 Delphi 9/29/2009 International\Translation Description Steps:[QC Short Description] English ION version of RAD Studio 2010 Architect has Japanese translations on SQL Window tab [QC Description] The English InstantOn version of RAD Studio 2010 Architect has Japanese translations shown on the SQL Window tab. Not all labels are shown in Japanese, and I have not noticed this anywhere else in the IDE. I have attached a screenshot for reference QC Entry 78205 //Masahiro Arai This is not only for ION but Installer.

- Right-click a valid database connection in the Data Explorer window and select 'SQL Window' from the contest menu Expected: The SQL Window tab is shown with all text in English Actual: The SQL Window tab is shown with a mixture of English and Japanese text

QC #: 78251 - Status: Closed

QC #: Project Date Reported: Area: 78251 Delphi 10/1/2009 AddOn\RAVE Description Steps:[QC Short Description] Rave 7.7: memo with RTF prints garbage [QC Description] When I try to print RTF text, that text appears followed by a lot of garbage. This problem exists since D2009 and is a real showstopper to migrate some projects. This is similar to QC 70407 except that I don't use datasets and still have the same problem. Also, that report doesn't have attached a sample project. QC Entry 78251

Run the attached program and press the button. Expected: the report should show only the text in the richedit. Actual: that text is followed by a lot of garbage.

QC #: 78253 - Status: Closed

QC #: Project Date Reported: Area:78253 Delphi 10/1/2009 Internet\Controls\TUdpSocket Description Steps:[QC Short Description] Sockets.TIpSocket.ReceiveFrom has wrong signature [QC Description] (same problem as in Report 1966, but still not fixed)

The function ReceiveFrom is declared like this: TIpSocket.ReceiveFrom(var buf; bufsize: Integer; ToAddr: TSockAddr; var len: Integer; flags: Integer): Integer; And it calls WinSock.recvfrom to do the work. That is declared like this: function recvfrom(s: TSocket; var Buf; len, flags: Integer; var from: TSockAddr; var fromlen: Integer): Integer; stdcall; If you compare the two signatures, you will see two differences for the third parameter: the name (to instead of from, not a real problem) and that it is not a var parameter in your abstraction (the winsock signature is correct) Without declaring the address as var parameter, the function is not usable, as you will not be able to get the sockaddr from where you got the packet. QC Entry 78253

QC #: 78257 - Status: Closed

QC #: Project Date Reported: Area: 78257 Delphi 10/1/2009 IDE Description Steps:[QC Short Description] It seems that the resources added by resource manager are ignored in packages [QC Description] Added by Sysop <<<<<<<<<<<<<<<< {$R *.dres} is missing in the main source. So, one workaround is adding {$R *.dres} into 'Package1.dpk' as below ------------------------ package Package1; {$R *.res} {$R *.dres} ... ... ------------------------ >>>>>>>>>>>>>>>> QC Entry 78257

1) Create package. 2) Open resource manager (Project -> Resources). 3) Add some bitmap. 4) Close dialog and compile the package. 5) Try to explore the package by ResHacker or another like tools. It does not contain added bitmap.

QC #: 78258 - Status: Closed

QC #: Project Date Reported: Area: 78258 Delphi 10/1/2009 IDE\Project Management Description Steps:[QC Short Description] Some enhancement to resource manager (Project -> Resources) [QC Description] It would be useful if after insertion of some resource into the project the corresponding line in the list became selected. Because it's needed to change the name of the resource in most cases. QC Entry 78258

QC #: 78273 - Status: Closed

QC #: Project Date Reported: Area: 78273 C++Builder 10/1/2009 Compiler\C++ Description Steps:[QC Short Description] Various failures trying to build a project [QC Description] The attached project is impossible to build with BCB 2010. It shows all kinds of failures - from the ICE in the compiler, to 'out of memory', to skipping compiling files. Here is a sample of the error messages: bcc32 command line for "pad.cpp" bcc32 command line for "impl.cpp" bcc32 command line for "uiDocHandlerImpl.cpp" bcc32 command line for "H:\RAD Studio\6.0\Imports\MSHTML_TLB.cpp" [ILINK32 Error] Fatal: Unable to open file 'PAD.OBJ' ====================================== This one without the -CX512 parameter bcc32 command line for "impl.cpp" [BCC32 Fatal Error] utilcls.h(2544): F1004 Internal compiler error at 0x566d88e with base 0x55d0000 Exception EAccessViolation: Access violation at address 055F45F8 in module 'COMP32X.DLL'. Read of address 00000A0D [BCC32 Error] Catastrophic failure (Exception from HRESULT: 0x8000FFFF (E_UNEXPECTED)) QC Entry 78273

Open the attached project and try to build it. You will notice that some .obj files are simply not produced, though all appearance is that the .cpp files were compiled. If you remove the -CX512 parameter from the options, you will see the ICE.

QC #: 78277 - Status: Closed

QC #: Project Date Reported: Area: 78277 C++Builder 10/1/2009 Documentation Description Steps:[QC Short Description] CodeGuard Configuration F1/Help button does not work [QC Description] Clicking the Help button or F1 button in the CodeGuard Configuration for any of the 4 tabs does not bring up context sensitive help. Using the Help>Contents and Index from the Menu brings up the Help file to the main topic. QC Entry 78277

From the RAD Studio 2010, go to Tools > Codeguard Configuration. Select any of the configuration tabs. Press the Help button or F1 to receive the error.

QC #: 78284 - Status: Closed

QC #: Project Date Reported: Area: 78284 Delphi 10/1/2009 VCL\Graphics Description Steps:[QC Short Description] Make sure the error messages are proper English

Added by Sysop <<<<<<<<< This report is TPngImage component specific problem. Please see comments for more details. >>>>>>>>>

[QC Description] If you look in the error messages of the pngImage component, you have some "English" being used that we cannot really qualify as the "Queen's English": EPNGInvalidFileHeaderText = 'The file being readed ... I know, it's an extreme case but my customer seeing this error message would thing I am illiterate (while the truth is (a) I let a bug through and (b) the component's original creator was not a native English speaker). It will take 5 minutes to check the sentences. QC Entry 78284

QC #: 78289 - Status: Closed

QC #: Project Date Reported: Area: 78289 Delphi 10/1/2009 IDE\Open Tools API Description Steps:[QC Short Description] Read/Write of keyboard macros broken (IOTARecord.ReadFromStream, WriteToStream) [QC Description] Using IOTARecord to read/write macros to a stream always fails with this error message: "Invalid Key macro format." I believe the problem is that the code to read/write the macro stream (VEdTypes.TRecord.ReadFromStream) was not adjusted for unicode compatibility. The attached test case works fine in older releases. This bug prevents the macro library tool in GExperts from working. QC Entry 78289

Compile and install the attached package into the IDE with the default keymapping Focus the code editor, Shift+Ctrl+R to begin a macro, type "zzz" and then CR, Shift+Ctrl+R to end recording, Shift+Ctrl+P to playback the macro, and the zzz CR should appear in the editor Help, Test Wizard which tries to read the macro to a stream and then write it immediately back to the IDE stream Resulting error from VEdTypes.TRecord.ReadFromStream: --------------------------- Error --------------------------- Invalid Key macro format. --------------------------- OK Details << --------------------------- [208899ED]{coreide140.bpl} VEdTypes.Error (Line 641, "VEdTypes.pas" + 0) + $11 [20889AB7]{coreide140.bpl} VEdTypes.TRecord.ReadFromStream (Line 654, "VEdTypes.pas" + 4) + $0 [502717F7]{vcl140.bpl } Dialogs.ShowMessagePos (Line 6202, "Dialogs.pas" + 0) + $F [131D2D2B]{WizPackage.bpl} Testrecord.Register + $167 [2075F021]{coreide140.bpl} ExptMain.TExpertServices.WizardItemClick (Line 659, "ExptMain.pas" + 2) + $12 [50075663]{rtl140.bpl } Classes.TBasicAction.Execute (Line 12512, "Classes.pas" + 3) + $7 [502B182D]{vcl140.bpl } ActnList.TContainedAction.Execute (Line 448, "ActnList.pas" + 8) + $2C [502B2608]{vcl140.bpl } ActnList.TCustomAction.Execute (Line 1094, "ActnList.pas" + 7) + $8 [50075527]{rtl140.bpl } Classes.TBasicActionLink.Execute (Line 12441, "Classes.pas" + 2) + $7 [214BB9E1]{vclactnband140.bpl} ActnMenus.TCustomActionMenuBar.ExecAction (Line 1066, "ActnMenus.pas" + 6) + $D [214BCEA7]{vclactnband140.bpl} ActnMenus.TCustomActionMenuBar.TrackMenu (Line 1748, "ActnMenus.pas" + 15) + $15 [214C0460]{vclactnband140.bpl} ActnMenus.TCustomActionMainMenuBar.TrackMenu (Line 3474, "ActnMenus.pas" + 3) + $3 [214BB5A5]{vclactnband140.bpl} ActnMenus.TCustomActionMenuBar.CMItemClicked (Line 945, "ActnMenus.pas" + 3) + $4 [50295DFC]{vcl140.bpl } Controls.TControl.WndProc (Line 7062, "Controls.pas" + 91) + $6 [50295A20]{vcl140.bpl } Controls.TControl.Perform (Line 6840, "Controls.pas" + 10) + $8 [50299E58]{vcl140.bpl } Controls.GetControlAtPos (Line 9563, "Controls.pas" + 4) + $76 [5029A583]{vcl140.bpl } Controls.TWinControl.WndProc (Line 9776, "Controls.pas" + 101) + $1D [5029A6C0]{vcl140.bpl } Controls.TWinControl.WndProc (Line 9819, "Controls.pas" + 144) + $6 [214BCF96]{vclactnband140.bpl} ActnMenus.TCustomActionMenuBar.WndProc (Line 1783, "ActnMenus.pas" + 25) + $4 [50299D60]{vcl140.bpl } Controls.TWinControl.MainWndProc (Line 9540, "Controls.pas" + 3) + $6 [50076360]{rtl140.bpl } Classes.StdWndProc (Line 13014, "Classes.pas" + 8) + $0 [50290916]{vcl140.bpl } Controls.FindControl (Line 3377, "Controls.pas" + 6) + $9 [502C8749]{vcl140.bpl } Forms.TApplication.ProcessMessage (Line 9784, "Forms.pas" + 30) + $1 [502C878E]{vcl140.bpl } Forms.TApplication.HandleMessage (Line 9814, "Forms.pas" + 1) + $4 [502C8AB9]{vcl140.bpl } Forms.TApplication.Run (Line 9951, "Forms.pas" + 26) + $3 [0042D94A]{bds.exe } bds.bds (Line 200, ""

+ 8) + $FFFB

QC #: 78295 - Status: Closed

QC #: Project Date Reported: Area: 78295 Delphi 10/2/2009 Compiler\Delphi\Generics Description Steps:(JJS: This might be another instance of RAID 272825) [QC Short Description] [DCC Fatal Error] F2084 Internal Error: URW1111 [QC Description] The internal error occurs when two units reference each other. for more details, see the attached project. QC Entry 78295

Compile the attached project with the following command-line. dcc32 -b Project2.dpr See the following compile-time error indicating failure. Unit1.pas(23) Fatal: F2084 Internal Error: URW1111 Omitting the build option, -b, compiles w/o error. There are two units: // Unit1.pas unit Unit1; interface uses Unit2; type TProblem = class(TGenericClass<TObject>) end; procedure DoSomething; implementation procedure DoSomething; begin end; end. // Unit2.pas unit Unit2; interface type TGenericClass<T> = class public procedure DoSomething; end; implementation uses Unit1; // Occurs when uses Unit1. { TGenericClass<T> } procedure TGenericClass<T>.DoSomething; begin Unit1.DoSomething; end; end.

QC #: 78297 - Status: Closed

QC #: Project Date Reported: Area:78297 Delphi 10/2/2009 VCL\Dialog Controls\TSaveDialog

Description Steps:[SB] Handle and FileName properties are not returned properly when accessed from event handlers while the dialog is showing. [QC Short Description] inconsistent behaviour of TSaveDialog instance (handle not assigned, [QC Description] Under special circumstances, the handle of TSaveDialog instances is not assigned properly as well as the OnTypeChange event. In the TSaveDialog.Execute function there is a special handling if the following condition is met: (Win32MajorVersion >= 6) and UseLatestCommonDialogs and (Template = '') and not (Assigned(FOnIncludeItem) or Assigned(FOnClose) or Assigned(FOnShow)) In the case that this condition is met, the TSaveDialog.Handle is not assigned properly (stays zero) and OnTypeChange is fired even when the Dialog is opened. In the case that this condition is not met, the handle is assigned properly and OnTypeChange is only fired when the type is changed. QC Entry 78297

1. place a TSaveDialog component on a form 2. Assign a method to OnTypeChange, that shows a message box showing the handle of the SaveDialog. 3. run the application on Windows Vista and show the Save Dialog ==> SaveDialog.Handle is 0 and the OnTypeChange fires before the Dialog is shown 4. Now also assign OnShow (code does not matter) and repeat Step 3. ==> SaveDialog.Handle is assigned correctly and OnTypeChange is only fired when the type is changed.

QC #: 78315 - Status: Closed

QC #: Project Date Reported: Area:

78315 Delphi 10/2/2009 Documentation

Description Steps: [QC Short Description] [Documentation] Can't understand sample source code (Japanese version) [QC Description] The source code is single-line and it is difficult to understand the content. "Declarations and Statements" [Delphi 2007] ms-help://borland.bds5/devcommon/declarationsandstatements_xml.html [Delphi 2009] ms-help://embarcadero.rs2009/devcommon/declarationsandstatements_xml.html [Delphi 2010] ms-help://embarcadero.rs2010/rad/%E5%AE%A3%E8%A8%80%E3%81%A8%E6%96%87.html ms-help://embarcadero.rs2010/rad/(sengen to bun).html [Docwiki] http://docwiki.embarcadero.com/RADStudio/ja/%E5%AE%A3%E8%A8%80%E3%81%A8%E6%96%87QC Entry 78315

QC #: 78323 - Status: Closed

QC #: Project Date Reported: Area:78323 Delphi 10/2/2009 IDE

Description Steps:[QC Short Description] Using the Code Formatter on "(X as SomeClass).SomeProperty" does not work as expected. [QC Description] Based on: https://forums.embarcadero.com/thread.jspa?messageID=166822&tstart=0#166822 Code like ... procedure TForm1.Button1Click(Sender: TObject); begin (Sender as TButton).Caption := 'test'; end; ... after formatting it by the code formatter in D2010 results in: procedure TForm1.Button1Click(Sender: TObject); begin (Sender as TButton) .Caption := 'test'; end; QC Entry 78323

Fixed for a long time. It was a bug in Weaver only

QC #: 78326 - Status: Closed

QC #: Project Date Reported: Area: 78326 Delphi 10/2/2009 Compiler\Delphi\Generics Description Steps:REGRESSION [QC Short Description] Codegen generates incorrect code for Generics in some cases with optimization enabled Additional internal note by USc: This is regression that happened between FT build 3417 (revision 21151) and 3449 (revision 21988) [QC Description] see steps. in this case, TMyArray<T>.GetItem will be optimized as: {function TMyArray<Single>.GetItem} Unit2.pas.67: begin 004A7058 51 push ecx Unit2.pas.68: Result := Fdata[x]; 004A7059 8B00 mov eax,[eax] 004A705B 8B0490 mov eax,[eax+edx*4] 004A705E 894500 mov [ebp+$00],eax ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Unit2.pas.69: end; 004A7061 D94500 fld dword ptr [ebp+$00] ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 004A7064 5A pop edx 004A7065 C3 ret it should be [ESP], not [EBP]. QC Entry 78326

Steps by USc (turned the original steps into complete test case): - save the attachment or the following code as QC78326.dpr - dcc32 QC78326.dpr - execute QC78326.exe expected: PASS actual: FAIL - Exception Error Additional notes: - works with optimization disabled -also doesn't work for exam. with Real, Double, Extended - work for exam. with Integer ("foo[0] := 0.1" needs an adjustment then) program QC78326; {$APPTYPE CONSOLE} {.$OPTIMIZATION OFF} uses SysUtils; type TMyArray<T> = record private fdata: array of T; FCount: Cardinal; function GetItem(X: Cardinal): T; procedure SetItem(X: Cardinal; const Value: T); procedure SetCount(const Value: Cardinal); public property Item[X: Cardinal]: T read GetItem write SetItem; default; property Count: Cardinal read FCount write SetCount; end; function TMyArray<T>.GetItem(X: Cardinal): T; begin Result := fdata[x]; end; procedure TMyArray<T>.SetCount(const Value: Cardinal); begin FCount := Value; SetLength(fdata, Value); end; procedure TMyArray<T>.SetItem(X: Cardinal; const Value: T); begin fdata[X] := Value; end; procedure TestSingleGenericRecord; var foo: TMyArray<Single>; begin foo.Count := 10; foo[0] := 0.1; FloatToStr(foo[0]); end; function ReturnString: string; begin Result := ''; end; begin try TestSingleGenericRecord; if ReturnString = '' then WriteLn('PASS') else WriteLn('FAIL'); except on E: Exception do begin WriteLn('FAIL - Exception Error'); WriteLn(' ClassName=', E.Classname); WriteLn(' Message=', E.Message); end; end; end. ---- Original steps: 1. define a generic record TMyArray<T>: TMyArray<T> = record private fdata: array of T; FCount: Cardinal; function GetItem(X: Cardinal): T; procedure SetItem(X: Cardinal; const Value: T); procedure SetCount(const Value: Cardinal); public property Item[X: Cardinal]: T read GetItem write SetItem; default; property Count: Cardinal read FCount write SetCount; end; function TMyArray<T>.GetItem(X: Cardinal): T; begin Result := fdata[x]; end; procedure TMyArray<T>.SetCount(const Value: Cardinal); begin FCount := Value; SetLength(fdata, Value); end; procedure TMyArray<T>.SetItem(X: Cardinal; const Value: T); begin fdata[X] := Value; end; 2. use a TMyArray<Single> var(must be Single): var

foo: TMyArray<Single>; 3. call it's GetItem: foo.Count := 10; foo[0] := 0.1; FloatToStr(foo[0]); * and then a procedure somewhere else will cause an error of memory addressing.

QC #: 78374 - Status: Closed

QC #: Project

Date Reported:

Area:

78374 Delphi 10/5/2009

Documentation

Description Steps:[QC Short Description] [Documentation] The hyphen is written by "Numeric character reference" [QC Description] The hyphen is written by "Numeric character reference". [EN] http://docwiki.embarcadero.com/RADStudio/en/IDE_Command_Line_Switches_and_Options [DE] http://docwiki.embarcadero.com/RADStudio/de/IDE-Befehlszeilenoptionen [FR] http://docwiki.embarcadero.com/RADStudio/fr/Options_et_commutateurs_de_la_ligne_de_commande_de_l%27EDI [JA] http://docwiki.embarcadero.com/RADStudio/ja/IDE_%E3%82%B3%E3%83%9E%E3%83%B3%E3%83%89_%E3%83%A9%E3%82%A4%E3%83%B3_%E3%82%B9%E3%82%A4%E3%83%83%E3%83%81%E3%81%A8%E3%82%AA%E3%83%97%E3%82%B7%E3%83%A7%E3%83%B3 - Delphi 2007 Help - Delphi 2009 Help - Delphi 2010 Help - PDF manual - CHM Help also the same. QC Entry 78374

EXP: bds.exe -sdc:\test\source -d c:\test\myprog.exe \mbox{-}td ACT: bds.exe -sdc:\test\source -d c:\test\myprog.exe \mbox{-}td

QC #: 78376 - Status: Closed

QC #: Project Date Reported: Area:78376 Delphi 10/5/2009 IDE\Code Editor\Error Insight Description Steps:[QC Short Description] Regression: Inherited methods are unknown when using unit with parent class without "in" in the uses clause [QC Description] It seems that inherited methods are unknown when the unit with the parent class is used without "in" in the uses clause. This is regression from D2010 RTM. -> see steps QC Entry 78376

- save the attached files - start Delphi - open EIRegression.dpr - open JvAppRegistryStorageSimplified.pas expected: no Error Insight errors actual: 'GetRoot' is not a field or method identifier at line 13 (13:24) The error goes away when you use JvAppStorageSimplified with "in" in the projects uses clause: - close JvAppRegistryStorageSimplified.pas - change line 6 in EIRegression.dpr from JvAppStorageSimplified, into JvAppStorageSimplified in 'JvAppStorageSimplified.pas', - open JvAppRegistryStorageSimplified.pas again and see there is no Error Insight error

QC #: 78431 - Status: Closed

QC #: Project Date Reported: Area: 78431 Delphi 10/7/2009 Compiler\Delphi\RTTI Description Steps:[QC Short Description] D2010 RTTI - SetValue() Bug [QC Description] Example Program is crashing while returning from ChangeData() Procedure. see also https://forums.embarcadero.com/thread.jspa?threadID=26136&tstart=0 Marc Rohloff [TeamB]: "It seems like it is messing up shared references to TValueData. I would add it to QC. " QC Entry 78431

compile and run: Program testRtti; {$APPTYPE CONSOLE} Uses SysUtils, Rtti; Type tmyObject = Class(tObject) Private fStr: String; Procedure SetStr(Const Value: String); Public Procedure BeginChange; Procedure DoneChange; Property Str: String Read fStr Write SetStr; End; Procedure tmyObject.BeginChange; Begin Writeln('BeginChange'); End; Procedure tmyObject.DoneChange; Begin Writeln('DoneChange'); End; Procedure tmyObject.SetStr(Const Value: String); Begin Writeln('SetStr(' + Value + ')'); fStr := Value; End; Procedure ChangeObject(Const Instance: tObject); var ctx: tRttiContext; typ: tRttiType; Begin ctx := tRttiContext.Create; Try typ := ctx.GetType(Instance.ClassType); If Assigned(Instance) Then Begin typ.GetMethod('BeginChange').Invoke(Instance, []); typ.GetProperty('Str').SetValue(Instance, 'Just a teststring ...'); typ.GetMethod('DoneChange').Invoke(Instance, []); End; Finally ctx.Free; End; End; Var Obj: tmyObject; Begin Try Obj := tmyObject.Create; ChangeObject(Obj); FreeAndNil(Obj); Except End; End.

QC #: 78433 - Status: Closed

QC #: Project Date Reported: Area: 78433 Delphi 10/7/2009 Compiler\Delphi\Generics Description Steps:[QC Short Description] Generic Class with two generic types destroy previous call EBP [QC Description] If i define a generic class with two generic types like TClass<A,R> and i define a function GetSomething(const I: R):A this function will destroy loose the stack frame of the previous call. See the example that is a console application. QC Entry 78433 (JJS: Changing the calling convention for TGenClass<>.GetItemByReference to stdcall, pascal, or cdecl seems to workaround the problem.)

Run the following program See... FAIL #1 - Value of C lost FAIL #2 - ebp lost program BTS273211; {$APPTYPE CONSOLE} uses SysUtils, Generics.Collections; var Counter: Integer = 0; type TClassName = class end; TClassNameRef = class(TClassName) private Fref: TClassName; published public property Ref: TClassName read Fref write Fref; end; TGenClass<R: TClassName; T: TClassNameRef> = class(TList<T>)private function GetItemByReference(const Index: R): T; public property ItemByReference[const Index: R]:T read GetItemByReference; end;

TGenClassName = class(TGenClass<TClassName, TClassNameRef>); function TGenClass<R, T>.GetItemByReference(const Index: R): T;var j: Integer; a: TClassNameRef; r: TClassName; _t: T; begin _t:= default(T); r:= Index; for j := 0 to Count - 1 do begin _t:= Items[j]; a:= _t; if a.Ref = r then Exit(_t); end; Result:= _t; end; procedure DoError; begin with TGenClassName.Create do try Add(TClassNameRef.Create); Items[0].Ref:= Items[0]; ItemByReference[Items[0]].Ref:= nil; Items[0].Free; Delete(0); finally Free; end; end; procedure Use(var Value); begin if Integer(Value) = 42 then Inc(Counter) else WriteLn('FAIL #1 - Value of C lost'); end; procedure DoMegaError; var b: Integer; a: Integer; C: Integer; begin { Save ebp } asm mov a, ebp end; c:= 42; DoError; { Save ebp again } asm mov b, ebp end; Use(C); if a=b then Inc(Counter) else WriteLn('FAIL #2 - ebp lost'); end; begin

try DoMegaError; if Counter = 2 then WriteLn('PASS') else WriteLn('FAIL - Counter=', Counter); except on E: Exception do begin WriteLn('FAIL - Exception Error'); WriteLn(' ClassName=', E.ClassName); WriteLn(' Message=', E.Message); end; end; end.

QC #: 78456 - Status: Closed

QC #: Project Date Reported: Area: 78456 C++Builder 10/8/2009 SOAP\Transfers Description Steps:[QC Short Description] TByteDynArray generate memory leak over SOAP. [QC Description] It's hard to reproduce but I will show the code in OPToSOAPDomConv.pas We want to send a ByteDynArray over SOAP. We have the ByteDynArray incapsulated in an other Class that inherits from TRemotable. When we recieve the ByteDynArray that array is not cleaned up. The reason for that is that the refcount in inc. and when tested if it was Incremented the code is looking at the wrong addres. Here is the code . // get current refcount or set it to zero if Assigned(ArrayPtr) then L := PInteger(PByte(ArrayPtr)-8)^ else L := 0; //Copy dyn array ( inc refcount) SetDynArrayProp(Instance, PropList[I], ArrayPtr); // test if refcount was incremented ( at the wrong address) if (L > 0) and ((PInteger(PChar(ArrayPtr)-8)^) > L) then //decrement the refcount if it was incremented Dec(PInteger(PByte(ArrayPtr)-8)^); in the second "if" the address is calculated with a PChar and with UNICODE wchar_t That is 2 * PByte(x). the result is that "if (L > 0) and ((PInteger(PChar(ArrayPtr)-8)^) > L) then" is looking at the wrong place to check if it should decrement the refcount. As you can see all other places to get the refcount use: (PInteger(PByte(ArrayPtr)-8)^) So we corrected the if to "if (L > 0) and ((PInteger(PByte(ArrayPtr)-8)^) > L) then". The result is now that the refcount is decremented and the array is released from memory. This is where this code can be found. file: TSOAPDomConv.pas

procedure: procedure TSOAPDomConv.InitObjectFromSOAP(Instance: TObject; RootNode, Node: IXMLNode); line: 4403 (my file from 14-01-2009). We have seen in QC that there is a simular problem reported( 21223) in D7 that was solved in D2007. It seems that the fix of that problem(21223) is now causing the Bug. jvdn & jvd. QC Entry 78456

QC #: 78497 - Status: Closed

QC #: Project Date Reported: Area:78497 Delphi 10/8/2009 RTL\Delphi\RTL Exceptions Description Steps:[QC Short Description] REGRESSION If simple program raises exception during initialization then program will consume all stack in _ExceptionHandler until it crashes QC Entry 78497

Steps by USc: - save the attached files from dir "simplified" - dcc32 InitializationTestProject.dpr - execute InitializationTestProject.exe expected: output is Exception Exception in module InitializationTestProject.exe at ... Just an exception. actual: with Tiburon or Weaver till FT build 3494 (revision 23552): as expected with Weaver since FT build 3505 (revision 23995): "InitializationTestProject.exe has stopped working" in Vista (free translation of DE message) Original steps (uses the project from dir "original"): Firstly it is not special project. Just project with couple of units and last one raises exception in initialization. So I basically added only one line which produces code : raise Exception.Create("Bla") 1. Open attached project 2. Run it under debugger 3. When program raises exception press Continue 4. Then program crashes because stack I believe overlaps code. Anyway you can compile it with debug dcus and put breakpoint at first line in _ExceptionHandler in system.pas you will see that it calls itself indefinatelly. 5. If you run application without debugger it will display that dialog that program ecountered problem indefinatelly until you kill it in task manager. This happend in RTL and Beta Update 2 In D2009 the same code works fine.

QC #: 78563 - Status: Closed

QC #: Project Date Reported: Area: 78563 Delphi 10/12/2009 Compiler\Delphi\Generics Description Steps:[QC Short Description] Wrong InstanceSize using derived generic classes [QC Description] Summary : - take a generic class containing a field of the generic type - derive the generic class to another generic class - classes built from the derived class have the wrong instancesize. To reproduce, see attached code, the compiler computes the wrong instance size on the derived class TClassBugInstanceSize. Needless to say, this bug is quite critical... QC Entry 78563

Steps by USc: - save the two console applications in the steps (Project1.dpr is the original test case) - dcc32 Project1.dpr - execute Project1.exe expected: output is 4008 4008 actual: output is 4008 12 - dcc32 GenericInstanceSizeTest.dpr - execute GenericInstanceSizeTest.exe expected: output is PASS actual: output is FAIL #2 FAIL #6 Additional note: the sizes are based on the default compiler options/are for $A8 and i386/Win32 //--- Original test case --- program Project1; {$APPTYPE CONSOLE} type TClass1<T> = class(TObject) FField : T; end; TClass2<T> = class(TClass1<T>) end; TData = record Data : ARRAY [1..1000] OF Cardinal; // just a sample... end; TClassOkInstanceSize = class(TClass1<TData>); TClassBugInstanceSize = class(TClass2<TData>); begin Writeln(TClassOkInstanceSize.InstanceSize); // Returns 4008 Writeln(TClassBugInstanceSize.InstanceSize); // Ouch, should be the same as previously but returns 12, obviously no room for ffield !!! end. //--- test case by USc --- program GenericInstanceSizeTest; {$APPTYPE CONSOLE} type TClass1<T> = class(TObject) FField: T; function Class1GetSizeOfT: Integer; end; TClass2<T> = class(TClass1<T>) function Class2GetSizeOfT: Integer; end; function

TClass1<T>.Class1GetSizeOfT: Integer; begin Result := SizeOf(T); end; function TClass2<T>.Class2GetSizeOfT: Integer; begin Result := SizeOf(T); end; type TData = record Data: array [1..1000] of Cardinal; // just a sample... end; TClassOkInstanceSize = class(TClass1<TData>); TClassBugInstanceSize = class(TClass2<TData>); TClass1Int64 = class(TClass1<Int64>); TClass2Int64 = class(TClass2<Int64>); { these constants may need an adjustment depending on the alignment and architecture (the current values are for $A8 and i386/Win32) } const ExpectedClass1DataInstanceSize = 4008; ExpectedClass2DataInstanceSize = 4008; ExpectedClass1Int64InstanceSize = 20; ExpectedClass2Int64InstanceSize = 20; var Class2Data: TClassBugInstanceSize; Class2Int64: TClass2Int64; FailCounter: Integer; begin FailCounter := 0; if TClassOkInstanceSize.InstanceSize <> ExpectedClass1DataInstanceSize then begin WriteLn('FAIL #1'); Inc(FailCounter); end; if TClassBugInstanceSize.InstanceSize <> ExpectedClass2DataInstanceSize then begin WriteLn('FAIL #2'); Inc(FailCounter); end; Class2Data := TClassBugInstanceSize.Create; try if Class2Data.Class1GetSizeOfT <> SizeOf(TData) then begin WriteLn('FAIL #3'); Inc(FailCounter); end; if Class2Data.Class2GetSizeOfT <> SizeOf(TData) then begin WriteLn('FAIL #4'); Inc(FailCounter); end; finally Class2Data.Free; end; if TClass1Int64.InstanceSize <> ExpectedClass1Int64InstanceSize then begin WriteLn('FAIL #5'); Inc(FailCounter); end; if TClass2Int64.InstanceSize <> ExpectedClass2Int64InstanceSize then begin WriteLn('FAIL #6'); Inc(FailCounter); end; Class2Int64 := TClass2Int64.Create; try if Class2Int64.Class1GetSizeOfT <> SizeOf(Int64) then begin WriteLn('FAIL #7'); Inc(FailCounter); end; if Class2Int64.Class2GetSizeOfT <> SizeOf(Int64) then begin WriteLn('FAIL #8'); Inc(FailCounter); end; finally Class2Int64.Free; end; if FailCounter = 0 then WriteLn('PASS'); end.

QC #: 78565 - Status: Closed

QC #: Project Date Reported: Area:78565 Delphi 10/12/2009 VCL\Win 32 Controls\THeaderControl

Description Steps:[QC Short Description] events are not triggered on vista [QC Description] i have something like this: ...DoOnSectionDrag(Sender: TObject; FromSection, ToSection: THeaderSection; var AllowDrag: Boolean); begin ..... AllowDrag := MessageDlg('Move section?', mtConfirmation, mbYesNo, 0) = IDYES .... .... end; ...DoOnSectionEndDrag(Sender: TObject); begin ..... end; if i display a message dialog or a form in the OnSectionDrag event, the OnSectionEndDrag event is never triggered on vista. this code it's working just fine on xp. QC Entry 78565

QC #: 78575 - Status: Closed

QC #: Project Date Reported: Area: 78575 Delphi 9/16/2009 9:28:36 AM Debugger\Execution Description Steps:On Windows 7, running under the debugger often causes the debugee to crash on shutdown. This manifests when debugging the IDE in the IDE and in the simple DB application which is attached.

Load the attached project and run it. Wait about 30 seconds and then shutdown. Repeat if necessary. Usually after 2 or 3 runs it crashes on shutdown.

QC #: 78576 - Status: Closed

QC #: Project Date Reported:

Area:

78576 Delphi 10/12/2009

Database\TField\TBlobField

Description Steps: [QC Short Description] TBlobField DataSize should return zero [QC Description] A change was made to TBlobField in D2010 that causes the DataSize property to return the size of the blob stream contents rather than zero. This change breaks the previously documented behavior for the DataSize property which requires fields with "data of indeterminate size" to return zero. The new behavior is cleary inconsistent with Delphi documentation and hazardous for code that depends on the previous behavior: http://docs.embarcadero.com/products/rad_studio/delphiAndcpp2009/HelpUpdate2/EN/html/delphivclwin32/DB_TField_DataSize.html "The value of DataSize for TField is 0. Most descendants of TField override this property to specify the size required by the specific field type they represent. BLOB fields, however, represent data of indeterminate size. They do not override the inherited method, so the value of DataSize for BLOB fields is 0. A value of zero should not be interpreted as meaning the field value requires no memory. A value of zero indicates that the memory required for the field is indeterminate." QC Entry 78576

Compare the TBlobField definition in D2010 with that from D2009 and earlier. D2010 adds the following GetDataSize override to TBlobField: // From DB.pas in D2010 TBlobField = class(TField) ... function GetDataSize: Integer; override; public ... function TBlobField.GetDataSize: Integer; begin Result := GetBlobSize; end;

QC #: 78595 - Status: Closed

QC #: Project Date Reported: Area: 78595 C++Builder 10/13/2009 Compiler\C++ Description Steps:[QC Short Description] 'new' returns the same pointer over and over in release mode [QC Description] Compiler generates incorrect code in Release Mode for the following code. Attached code: #include <vcl.h> #pragma hdrstop #include <tchar.h> template <class T> class TFooBase : public TObject {};

compile the test case below as: bcc32 -vi -c -S 273303.cpp && grep call 273303.asm exp: 2 calls to _ClassCreate res: 1 call to _ClassCreate -------- compiler results for test case below -------------- CB2007: bcc 5.90 works (i.e. the asm contains 2 calls to _classCreate)CB2009: bcc 6.13 fails, and has calls to @__borland_set_unhandled_cpp_exception$qpvi CB2010: bcc 6.21 fails ------------------------------------------------------------------ struct __declspec(delphiclass) TObject { TObject(); }; struct TBar {};

template <class T> class TFoo : public TFooBase<T> { public: __fastcall TFoo() {} }; class TBar : public TObject {}; int _tmain() { typedef TFoo<TBar> TTest; TTest* test1 = new TTest; TTest* test2 = new TTest; TTest* test3 = new TTest; TTest* test4 = new TTest; TTest* test5 = new TTest; if ((test1 == test2) || (test2 == test3) || (test3 == test4) || (test4 == test5)) { throw Exception("Test"); } return 0; } . QC Entry 78595

template <class T> // Works if not template struct TFooBase : TObject {}; template <class T> // Works if not template or inherits TFooBase<TBar> struct TFoo : TFooBase<T> { //#pragma option push -vi- // This is a work-around TFoo() {} //#pragma option pop // This is a work-around }; int main() { TFoo<TBar>* test1; test1 = new TFoo<TBar>; return test1 != 0; } === original steps === bcc32 -WCV qc78595.cpp qc78595.exe Exp: no exceptions. Act: exception "Test" (shows if run in IDE - from command line shows "Abnormal program termination") Builds and runs without error in earlier versions of C++ Builder Test passes by disabling expand inline function: bcc32 -WCV -vi- qc78595.cpp

QC #: 78598 - Status: Closed

QC #: Project Date Reported: Area: 78598 C++Builder 10/13/2009 Documentation Description Steps:[QC Short Description] AnsiString description missing in Help [QC Description] In C++ Builder 2010 Help there is no description for AnsiString (I mean the old good "Properties", "Methods", "Members" links etc.). All that can be found after a while is a chapter on String Types which gives an overview of existing Delphi string types, but not the full description of the types. The same problem occurs with: UnicodeString and String Actually this problem occurs with most of the types found in the Delphi System unit. QC Entry 78598

A1) Go to Help/C++ Builder Help/Index A2) write the text AnsiString in the "Look for" field and press Enter A preformatted page titled System.AnsiString is shown which lacks any information. B) Repeat steps A1- A2 for the text UnicodeString (or the text String) C1) Repeat steps A1-A2 for the text System A page for the unit System is shown C2) Scroll down to Types and try clicking on the individual type names (e.g. AnsiChar, Booleand, Byte...) almost all of them will not show any information.

QC #: 78613 - Status: Closed

QC #: Project Date Reported: Area: 78613 C++Builder 10/13/2009 VCL\Emulation Classes Description Steps:[QC Short Description] Both assignment operator overloads of DelphiInterface<> should take a const parameter [QC Description] The DelphiInterface<> smart pointer defined in systobj.h specifies two

- Compile the following code (bcc32 -WCV qc78613.cpp): // ----- #include <vcl.h> class IInterfaceWithoutGuid : public IInterface { }; typedef DelphiInterface <IInterfaceWithoutGuid> _di_IInterfaceWithoutGuid; int main (void) { _di_IInterfaceWithoutGuid i1, i2; i2 = i1; } // ----- Exp.: compiles Act.: Error E2497 systobj.h 349: Type IInterfaceWithoutGuid wasn't

operator overloads for the assignment operator. In Update 2, one of them was changed to accept a const reference, but the other one wasn't: // ----- // systobj.h, l. 344f template <class ANOTHERINTF> DelphiInterface<T>& __fastcall operator =(DelphiInterface<ANOTHERINTF> &rhs) [...] DelphiInterface<T>& __fastcall operator =(const DelphiInterface<T>& rhs) // ----- This discrepancy changes the overload resolution rules: it causes the non-const one to be invoked whenever something that isn't constant is passed. The primary difference between the two operator overloads is that the first one invokes QueryInterface() with the IID of ANOTHERINTF whereas the second one simply copies the interface. As a result, the first overload will fail on all interfaces that don't have a GUID assigned to them. To fix it, simply change the first overload to accept a "const DelphiInterface<ANOTHERINTF>&" parameter (i.e. add the "const"). QC Entry 78613

assigned a GUID in function _fastcall operator _di_IInterfaceWithoutGuid & _di_IInterfaceWithoutGuid::= <IInterfaceWithoutGuid>(_di_IInterfaceWithoutGuid &)

QC #: 78620 - Status: Closed

QC #: Project Date Reported: Area:78620 Delphi 10/13/2009 Database\TField\TNumericField\TBCDField

Description Steps:[QC Short Description] TBCDField.GetDataSize returns incorrect value [QC Description] A change was made to TBCDField in D2010 that causes the DataSize property to return the wrong value. In previous versions of Delphi, the GetDataSize method of TBCDField returned SizeOf(TBcd). The GetDataSize method has been changed in D2010 to return SizeOf(System.Currency) instead. This change breaks code that depends on the previous behavior, in particular code that manipulates DataSet record buffers. QC Entry 78620

Compare the GetDataSize method implementation for TBCDField in D2010 with that from D2009 and earlier. // DB.pas D2010 function TBCDField.GetDataSize: Integer; begin Result := SizeOf(System.Currency); end; // DB.pas D2009 function TBCDField.GetDataSize: Integer; begin Result := SizeOf(TBcd); end;

QC #: 78652 - Status: Closed

QC #: Project Date Reported: Area: 78652 Delphi 10/14/2009 IDE\Build Tools Description Steps:[QC Short Description] "cancel build on error" is flawed [QC Description] If you use multiple pre-build events the build isn't canceled if an event causes en error and another one doesn't. This makes the build unreliable because you can't be sure all pre-build events succeeded. QC Entry 78652

- Create a new VCL app - Add a compiled version if this as a pre-build event: program Project1; {$APPTYPE CONSOLE} uses SysUtils; begin ExitCode := 1; end. - build the VCL app. The build fails as expected - Add a compiled version if this as a second pre-build event: program Project2; {$APPTYPE CONSOLE} uses SysUtils; begin ExitCode := 0; end. - build the VCL app again Expected: the build fails Observed: build succeeds

QC #: 78657 - Status: Closed

QC #: Project Date Reported: Area: 78657 Delphi 10/14/2009 Compiler\Delphi\Generics Description Steps:[QC Short Description] Compiler generates incorrect VMT for class used from generic and with CreateA as name of constructor QC Entry 78657

Run following program: program Project13; Type TMyClass = Class Public Constructor CreateA(A : Integer); End; TMyClass2<T : TMyClass, Constructor> = Class Public Procedure TestMe; End; constructor TMyClass.CreateA(A: Integer); begin end; procedure TMyClass2<T>.TestMe; begin T.CreateA(0); // It will crash here end; Procedure Test; Var C : TMyClass2<TMyClass>; Begin C:= TMyClass2<TMyClass>.Create; C.TestMe; End; begin Test; end. as you will see it will crash with Access Violation on line with comment //It will crash here. After short investigation I found that compiler generates incorrect VMT. Additional note by USc: It does not compile if the name of the constructor is Create instead of CreateA, because then the compiler allows only the use of the parameterless constructor (constructor constraint). It fails with "[DCC Error] Project34.dpr(20): E2029 ')' expected but number found" and this is similar to QC 78104 (RAID 270162).

QC #: 78660 - Status: Closed

QC #: Project Date Reported: Area: 78660 Delphi 10/14/2009 Install\Files Description Steps:[QC Short Description] Parts of Indy 10 Source are missing [QC Description] The following Indy10 source files were found to be missing from the RadStudio 7 installation. The absence of these source files prevents rebuilding of the version of Indy included in D2010 RTM and complicates debugging of some Indy applications. The resource files for Indy packages are also missing, but do not present a serious issue since they can be readily recreated. FYI this issue seems to be related to QC 68314 which is marked as Closed and fixed. Indy10\Protocols\IdAllAuthentications.pas Indy10\Protocols\IdAllHeaderCoders.pas Indy10\Protocols\IdBlockCipherIntercept.pas Indy10\Protocols\IdCompressorZLib.pas Indy10\Protocols\IdFTPListParsePCNFSD.pas Indy10\Protocols\IdFTPListParseSuperTCP.pas Indy10\Protocols\IdFTPListParseTandemGuardian.pas Indy10\Protocols\IdFTPListParseUnisysClearPath.pas Indy10\Protocols\IdHMAC.pas Indy10\Protocols\IdHMACMD5.pas Indy10\Protocols\IdHMACSHA1.pas Indy10\Protocols\IdHeaderCoder2022JP.pas Indy10\Protocols\IdHeaderCoderBase.pas Indy10\Protocols\IdHeaderCoderPlain.pas Indy10\Protocols\IdMessageBuilder.pas Indy10\Protocols\IdSASLDigest.pas Indy10\Protocols\IdSASL_CRAMBase.pas Indy10\Protocols\IdSASL_CRAM_SHA1.pas Indy10\Protocols\IdWebDAV.pas Indy10\Protocols\IdZLib.pas Indy10\Protocols\IdZLibConst.pas Indy10\Protocols\IdZLibHeaders.pas QC Entry 78660

Compare the units listed in the IndyProtocols DPK file with those available in the RTM source directories. Compiling the Indy DPK files in the IDE is *not* a valid means of checking for missing files since the missing units exist in compiled form and will not result in a compile error without first altering the library path to exclude Indy.

QC #: 78666 - Status: Closed

QC #: Project Date Reported: Area: 78666 Delphi 10/15/2009 Database\DBExpress Description Steps:[QC Short Description] "Mismatched in datapacket" with DSUtil.StreamToDataPacket [QC Description] StreamToDataPacket is a private method used by StreamToVariant in unit DSUtil.pas. It has an implementation problem. QC Entry 78666

TDBXFulcrumBugsSuite.Native.DB.Test.exe connection=ibconnection -s:TestRaid_277616 -OR- Run the following code and you will encounter "mismatched in datapacket" var D: OleVariant; S: TStream; C: TClientDataSet; begin C := TClientDataSet.Create(nil); S := TMemoryStream.Create; try C.FieldDefs.Add('Name', ftString, 20); C.CreateDataSet; VariantToStream(C.Data, S); S.Position := 0; StreamToVariant(S, D); C.Close; C.Data := D; finally S.Free; C.Free; end; end;

QC #: 78674 - Status: Closed

QC #: Project Date Reported: Area: 78674 Delphi 10/15/2009 Compiler\Delphi\Generics Description Steps:[QC Short Description] E2008 Incompatible types when using Low or High with a param of type TArray<T> [QC Description] USc tried to perform a loop with a Rtti TArray<T> parameter using Low and High, but that does not compile - it creates "E2008 Incompatible types" errors. The following code does create two E2008 errors procedure DoSomethingWithRttiArray(ARttiFieldsArray: TArray<TRttiField>); var I: Integer; begin for I := Low(ARttiFieldsArray) to High(ARttiFieldsArray) do;//<- two times E2008 end; Beside a "for in" loop a workaround seems to be using a local helper variable procedure DoSomethingWithRttiArrayWorkaround(ARttiFieldsArray: TArray<TRttiField>); var

- save the following console app or the attachment - dcc32 LowHighArrayTest.dpr expected: it compiles actual: LowHighArrayTest.dpr(28) Error: E2008 Incompatible types LowHighArrayTest.dpr(28) Error: E2008 Incompatible types program LowHighArrayTest; {$APPTYPE CONSOLE} //array of function TestClassicArrayAsLocalVar: Integer; var LocalArray: array of Integer; begin Result := High(LocalArray) - Low(LocalArray) + 1; end; function TestClassicArrayAsParam(AParamArray: array of Integer): Integer; begin Result := High(AParamArray) - Low(AParamArray) + 1; end; //TArray<> function TestTArrayAsLocalVar: Integer; var LocalArray: TArray<Integer>; begin Result := High(LocalArray) - Low(LocalArray) + 1; end; function TestTArrayAsParam(AParamArray: TArray<Integer>): Integer; begin Result := High(AParamArray) - Low(AParamArray) + 1; end; function TestTArrayAsParamWithLocalHelper(AParamArray: TArray<Integer>): Integer; var LocalArray: TArray<Integer>; begin LocalArray := AParamArray; Result := High(LocalArray) - Low(LocalArray) + 1; end; begin WriteLn('PASS');//on compile end.

I: Integer; RttiFieldsArray: TArray<TRttiField>; begin RttiFieldsArray := ARttiFieldsArray; for I := Low(RttiFieldsArray) to High(RttiFieldsArray) do;//does workend; -> see steps QC Entry 78674

QC #: 78688 - Status: Closed

QC #: Project Date Reported: Area: 78688 Delphi 10/15/2009 Compiler\Delphi\Linker Description Steps:[JJS] [QC Short Description] Warnings enabled lead to false positive W1056 warning 'duplicate resource warning' on make [QC Description] It seems that warnings enabled (default) can create strange make errors even if there are no warnings or hints. The following behavior was observed with a 2 million LoC app depending on the code and the compiler version: D2010 RTM and D2009 U#3: - Warning: W1056 Warning: Duplicate resource: Type 10 (RCDATA), ID T...; File ....dfm resource kept; file <path>\....dfm resource discarded. (in one specical case and repeatable: two times this message) D2009 U#3 only: - ....dpr(...) Fatal: F2092 Program or unit '...' recursively uses itself -> see D2010 W1056 test case in the steps QC Entry 78688 (See also RAID 273915) [FT]

1. save the attachment 2. dcc32 -B -W+ -UBuildUnits FalseW1056WithWarningsEnabled.dpr 3. dcc32 -M -W+ -UMakeUnits FalseW1056WithWarningsEnabled.dpr expected: it compiles actual: when repeating 2. and 3. ten times then at least once Warning: W1056 Warning: Duplicate resource: Type 10 (RCDATA), ID TDMBEWERTUNGSLAUF; File bewerl.dfm resource kept; file <path>\bewerl.dfm resource discarded. 4. dcc32 -M -W+ -UMakeUnits FalseW1056WithWarningsEnabled.dpr (should be successful) 5. dcc32 -B -W- -UBuildUnits FalseW1056WithWarningsEnabled.dpr 6. dcc32 -M -W- -UMakeUnits FalseW1056WithWarningsEnabled.dpr 7. repeat 5. and 6. ten times and see there is no error 8. copy BuildUnits\BewerlTypes.pas to .\BewerlTypes.pas 9. start the IDE 10. open FalseW1056WithWarningsEnabled.dpr and make sure warnings are enabled (should be enabled by default) 11. call build 12. copy MakeUnits\BewerlTypes.pas to .\BewerlTypes.pas 13. call make expected: it compiles actual: [DCC Warning] W1056 Warning: Duplicate resource: Type 10 (RCDATA), ID TDMBEWERTUNGSLAUF; File bewerl.dfm resource kept; file <path>\bewerl.dfm resource discarded. 14. call make again and see it is successful

QC #: 78706 - Status: Closed

QC #: Project Date Reported: Area:78706 C++Builder 10/16/2009 Compatibility\BCB<->Delphi Description Steps:[QC Short Description] IDropTarget not defined in BCB [QC Description] Probably, forgotten IDropTarget macro definition in svstobj.h P.S. Due to support request, I split 78582 in 3 reports. This is third. QC Entry 78706

Compile Delphi_IDropTarget_Problem.dproj. Not mandatory, I already included generated HPPs in folder Delphi/hpp. Open CPP_IDropTarget_Problem.cbproj. Compile and see the error message.

QC #: 78758 - Status: Closed

QC #: Project Date Reported: Area: 78758 C++Builder 10/18/2009 VCL\Emulation Classes Description Steps:

[QC Short Description] DynamicArray is not thread-safe [QC Description] The following code suggests that DynamicArray is not thread-safe. template <class T> void DynamicArray<T>::IncRefCount() { if (Data) { int* p_i = (int*)Data; int &refcount = *(p_i-2); refcount++; // shouldn't this be interlocked? } } template <class T> void DynamicArray<T>::DecRefCount() { if (Data) { int* p_i = (int*)Data; int &refcount = *(p_i-2); if (--refcount == 0) // shouldn't this be interlocked? FreeData(); } } whereas the Delphi's implementation of DynamicArray *is* thread-safe (system.pas _DynArrayClear, _DynArrayAsg, _DynArrayAddRef). QC Entry 78758

Open file sysdyn.h Search for the implementation of IncRefCount and DecRefCount. Notice that the refcount var is not locked when incremented / decremented.

QC #: 78772 - Status: Closed

QC #: Project Date Reported: Area: 78772 C++Builder 10/19/2009 Compiler\C++ Description Steps:[QC Short Description] String parameter is deleted before function call [QC Description] I have a function with two String parameters: void __fastcall TForm1::checkVersion(String version, String temp) { String wrongVersion = "*wrong*"; ShowMessage(version); } I call the function this way: checkVersion(adsVersion->FieldByName("version")->AsString, Application->Name); The version field contains the string "1.2.0.0". Still the ShowMessage shows the text "*wrong*". When I debug the code, after the TStringField.GetAsString method call, a call to UnicodeFree(var s: UnicodeString) in StrHlpr.pas is made. The parameter of this last call is "1.2.0.0". So the version string is deleted, and the string wrongVersion is created on the same address of the previous string. I have attached a demo project which shows this error. QC Entry 78772

bcc32 -WCV raid273359.cpp raid273359.exe exp: 1.2.0.0 1.2.0.0 1.2.0.0 act: #wrong# 1.2.0.0 1.2.0.0 Here is a simpler testcase: >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> #include <vcl.h> #include <tchar.h> struct TInvalidPtr { String FielName; String GetSomeText() { return "1234567"; }; __property String SomeText = { read = GetSomeText }; }; String Headerfunc (String s1, String s2) { OutputDebugString(UnicodeString().sprintf(L"Refcount %s = %d %s %d", s1, s1.RefCount(), s2 ,s2.RefCount()).c_str()); return s1;

} int _tmain(int argc, _TCHAR* argv[]) { Headerfunc(TInvalidPtr().SomeText, L"SomeField"); } >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>

QC #: 78790 - Status: Closed

QC #: Project Date Reported: Area: 78790 Delphi 10/19/2009 IDE\Code Editor\ Description Steps:[QC Short Description] Code formatter not working properly after assembly-only routines [QC Description] When placing an assembly-only procedure (containing only an asm..end; block but not a begin..end; block), the code formatter will format subsequent routines wrongly w.r.t. indentation. See also: https://forums.codegear.com/thread.jspa?threadID=26703 QC Entry 78790

Paste the following code into the IDE, select all and use code formatter: program Project1; {$APPTYPE CONSOLE} procedure AsmProc1; asm nop end; procedure DelphiProc1; begin writeln ('Proc1'); end; begin writeln('Test'); end. Expected: formatting for AsmProc1 and DelphiProc1 should be similar. Observed: Code indentation for DelphiProc1 is different (more highly indented).

QC #: 78803 - Status: Closed

QC #: Project Date Reported: Area: 78803 Delphi 10/19/2009 Compiler\Delphi\Generics Description Steps:[QC Short Description] F2084 Internal Error: URW1111 (test case attached) QC Entry 78803

Compile the attached project with the following command-line. dcc32 -b BTS273371.dpr See the following compile output indicating failure. uBTS273371c.pas(36) Fatal: F2084 Internal Error: URW1111 program BTS273371; uses uBTS273371c; begin WriteLn('PASS'); // PASS on compile // end. unit uBTS273371c; interface uses SysUtils, uBTS273371b; type TSingleClientPipeServer<TClientClass> = Class private procedure ExecuteInThreadPool(Const Action, Completed : TCompletedProc; Const Failed : TFailedProc); protected

function InternalStartAccept : Boolean; end; implementation procedure TSingleClientPipeServer<TClientClass>.ExecuteInThreadPool( const Action, Completed : TCompletedProc; const Failed : TFailedProc); begin end; function TSingleClientPipeServer<TClientClass>.InternalStartAccept : Boolean; begin ExecuteInThreadPool( procedure begin end, procedure begin end, procedure(Const E : Exception) begin end ); end; end. unit uBTS273371b; interface uses SysUtils, uBTS273371a; type TCompletedProc = TAction; TFailedProc = TAction<Exception>; implementation end. unit uBTS273371a; interface type TAction = reference To Procedure; TAction<T> = reference To Procedure(const Arg : T); implementation end.

QC #: 78827 - Status: Closed

QC #: Project Date Reported: Area: 78827 Delphi 10/20/2009 Install\Registry settings Description Steps:[QC Short Description] Invalid library path for Indy (Language Library Path) [QC Description] After installation of Delphi 2010, the "$" sign is missing in variable ($(BDS)) of second path in "Language Library Path" making this Indy path invalid: [HKEY_LOCAL_MACHINE\SOFTWARE\CodeGear\BDS\7.0\Library]"Language Library Path"="$(BDS)\\lib\\$(LANGDIR);(BDS)\\lib\\$(LANGDIR)\\Indy10"

Note that there is no straight forward way to see "Language Library Path" and "Package Search Path" in IDE (not displayed in Tools -> Options -> Environment Options -> Delphi Options -> Library - Win32 or Library - Translated). For these two, use regedit and open coresponding key.

After IDE is started for the first time, these paths are futher copied to user registry hive (and EnvOptions.proj), so [HKEY_CURRENT_USER\Software\CodeGear\BDS\7.0\Library] will also contain this. ------- But all in all this is only minor "bug" that won't affect anyone seriously.QC Entry 78827

QC #: 78831 - Status: Closed

QC #: Project Date Reported: Area: 78831 Delphi 10/20/2009 IDE\Code Editor\ Description Steps:[QC Short Description] Problem after formatting project source file with default formatter settings. QC Entry 78831

1. Create new VCL application project 2. Create new frame 3. Add a simple button to created frame 4. Add frame to form 5. Save project 6. View source of project 7. Check Options / Formatter / Delphi / Spaces / Set spacing for { and {* comments - must be INNER AND OUTER (default setting) 8. Format source of project file with CTRL+D 9. Save a project file (CTRL+S) and close all. After reopen project IDE cannot find a class of created frame. When i set formatter setting to ONLY OUTER it's fine, but IDE should accept both forms. Best regards. Fixed in 25684 in trunk. Now inner spaces in comments in uses section are always formatted as is

QC #: 78845 - Status: Closed

QC #: Project Date Reported: Area:78845 C++Builder 10/21/2009 IDE\Code Editor\Formatting Description Steps:[QC Short Description] formatting of array inconsistent [QC Description] I have an array of numbers in my code, and code formatting rearranges the items. I'm not sure if it should do this at all, but the current result looks strange to me. QC Entry 78845

Type this table to a C++ File const int data[] = { 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, }; Now press Ctrl-D and you get const int data[] = { 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000,

2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, }; [vk] Already fixed in #273292 (rev.25187) Refixed rev.28045

QC #: 78855 - Status: Closed

QC #: Project Date Reported: Area: 78855 C++Builder 10/21/2009 Compiler\C++ Description Steps:[QC Short Description] Simple class with its object in global crashes app [QC Description] If dynamic rtl is linked in, the app runs fine. Otherwise, it'll crash. If 'Foo foo' is not global, then the app runs fine as well. Most likely the app cleanup code stuffed up. derived_class_bug.exe: MSVC2005: MyClassBase::ctor() 4227476 MyClassDerived1::ctor()4227476 MyClassDerived2::ctor()4227476 Start MyClassBase::ctor() 1310596 MyClassDerived1::ctor()1310596 MyClassBase::ctor() 1310600 MyClassDerived1::ctor()1310600 MyClassDerived2::ctor()1310600 MyClassDerivedGeneric::ctor()1310600 ~MyClassDerived1::dtor()1310596 ~MyClassBase::dtor() 1310596 End DoSomething() ~MyClassDerivedGeneric::dtor()1310600 ~MyClassDerived2::dtor()1310600 ~MyClassDerived1::dtor()1310600 ~MyClassBase::dtor() 1310600 ~MyClassDerived2::dtor()4227476 ~MyClassDerived1::dtor()4227476 ~MyClassBase::dtor() 4227476 CB2010: MyClassBase::ctor() 4401632 MyClassDerived1::ctor()4401632 MyClassDerived2::ctor()4401632 Start MyClassBase::ctor() 1310596 MyClassDerived1::ctor()1310596 MyClassBase::ctor() 1310600 MyClassDerived1::ctor()1310600 MyClassDerived2::ctor()1310600 MyClassDerivedGeneric::ctor()1310600 ~MyClassDerived2::dtor()1310552 <<-- too many dtors (covered by QC 78859) ~MyClassDerived1::dtor()1310552 <<-- too many dtors (covered by QC 78859) ~MyClassBase::dtor() 1310552 <<-- too many dtors (covered by QC

bcc32 derived_class_bug.cpp and bcc32 -vi- derived class_bug.cpp will both produce wrong code.

78859) ~MyClassDerived1::dtor()1310596 ~MyClassBase::dtor() 1310596 End DoSomething() ~MyClassDerivedGeneric::dtor()1310600 ~MyClassDerived2::dtor()1310600 ~MyClassDerived1::dtor()1310600 ~MyClassBase::dtor() 1310600 ~MyClassDerived2::dtor()4401632 <<-- app hard crash Compiles fine in Comeau non-strict mode. QC Entry 78855

QC #: 78859 - Status: Closed

QC #: Project Date Reported: Area: 78859 C++Builder 10/21/2009 Compiler\C++ Description Steps:[QC Short Description] Too many d'tors calls in stack unwind [QC Description] This is a show stopper for CB2010 - neither of our production apps are working because of this bug, which was never a problem in CB2007. MSVC2005 / CB2007: Start MyClassBase::ctor() 1310556 MyClassDerived1::ctor() 1310556 MyClassDerived2::ctor() 1310556 MyClassBase::ctor() 1310568 MyClassDerived1::ctor(MyClassDerived1 const& other) 1310568 ~MyClassDerived2::dtor() 1310556 ~MyClassDerived1::dtor() 1310556 ~MyClassBase::dtor() 1310556 MyClassBase::ctor() 1310572 MyClassDerived1::ctor(MyClassDerived1 const& other) 1310572 MyClassDerived2::ctor(MyClassDerived1<T> const& other) 1310572MyClassDerivedGeneric::ctor(const MyClassDerived1<U>& obj) 1310572 ~MyClassDerived1::dtor() 1310568 ~MyClassBase::dtor() 1310568 End DoSomething() ~MyClassDerivedGeneric::dtor() 1310572 ~MyClassDerived2::dtor() 1310572 ~MyClassDerived1::dtor() 1310572 ~MyClassBase::dtor() 1310572 CB2010: bcc32 -vi- template_class_crash_bug.cpp and bcc32 template_class_crash_bug.cpp Start MyClassBase::ctor() 1310544 MyClassDerived1::ctor() 1310544 MyClassDerived2::ctor() 1310544 MyClassBase::ctor() 1310596 MyClassDerived1::ctor(MyClassDerived1 const& other) 1310596 ~MyClassDerived2::dtor() 1310544 ~MyClassDerived1::dtor() 1310544 ~MyClassBase::dtor() 1310544 MyClassBase::ctor() 1310600 MyClassDerived1::ctor(MyClassDerived1 const& other) 1310600

bcc32 -vi- template_class_crash_bug.cpp and bcc32 template_class_crash_bug.cpp

MyClassDerived2::ctor(MyClassDerived1<T> const& other) 1310600MyClassDerivedGeneric::ctor(const MyClassDerived1<U>& obj) 1310600 ~MyClassDerived2::dtor() 1310556 <<-- bogus dtor!!! ~MyClassDerived1::dtor() 1310556 <<-- bogus dtor!!! ~MyClassBase::dtor() 1310556 <<-- bogus dtor!!! ~MyClassDerived1::dtor() 1310596 ~MyClassBase::dtor() 1310596 End DoSomething() ~MyClassDerivedGeneric::dtor() 1310600 ~MyClassDerived2::dtor() 1310600 ~MyClassDerived1::dtor() 1310600 ~MyClassBase::dtor() 1310600 QC Entry 78859

QC #: 78892 - Status: Closed

QC #: Project Date Reported: Area: 78892 Delphi 10/22/2009 Compiler\Delphi\Generics Description Steps:[QC Short Description] When I specified class type as generic constraint I cannot use AS operator [QC Description] Related to Report No: 75435 (RAID: 270644) Status: Open Compiler doesn't treat generics with class constraints as class types http://qc.embarcadero.com/wc/qcmain.aspx?d=75435 Report No: 78091 (RAID: 273074) Status: Open cannot assign a NIL to a generic variable http://qc.embarcadero.com/wc/qcmain.aspx?d=78091 The difference is that there it is "as parameter type" and here "as actual type". QC Entry 78892

Try to compile following code: program Project13; Type TMyClass1 = Class End; TMyClass2<T : TMyClass1> = Class Private FA : T; Public Procedure Test; End; Procedure TMyClass2<T>.Test; var M: TMyClass1; Begin M := (FA As TMyClass1); End; begin end. You will get : [DCC Error] Project13.dpr(17): E2015 Operator not applicable to this operand type

QC #: 78898 - Status: Closed

QC #: Project Date Reported: Area:78898 C++Builder 10/22/2009 Compiler\C++\Front End\Exception Handling

Description Steps:[QC Short Description] Exception causes d'tor to be skipped [QC Description] A combination of for and if causes d'tor to be skipped when exception occurs. bcc32 if_exception_bug.cpp act results: <snipped> FAILED 3 exp results: MSVC++ 2005, cmdline - cl /EHsc if_exception_bug.cpp Start barbase() 1310556

bcc32 if_exception_bug.cpp run if_exception_bug.exe act: Start barbase() 1310588 bar() 1310588 barbase() 10670328 bar() 10670328 Inner() 10670328 barbase() 1310572 bar() 1310572 barbase() 1310556 bar() 1310556 barbase() 10670352 bar() 10670352 Inner() 10670352 barbase(copy ctor) 1310548 TFoo() 1310528 OK4 ~TFoo() 1310528 ~barbase() 1310548 barbase(copy ctor) 1310548 TFoo() 1310528 OK3 ~TFoo() 1310528 ~barbase() 1310548 barbase(copy ctor) 1310548 TFoo() 1310528 OK2 ~TFoo() 1310528 ~barbase() 1310548 ~barbase() 1310548 ~Inner() 10670352 ~bar() 10670352 ~barbase() 10670352 ~bar() 1310556 ~barbase() 1310556 ~bar() 1310572 ~barbase() 1310572 ~barbase() 1310588 FAILED 3 exp: ... PASSED

bar() 1310556 barbase() 210792 bar() 210792 Inner() 210792 barbase() 1310544 bar() 1310544 barbase() 1310552 bar() 1310552 ~bar() 1310544 ~barbase() 1310544 barbase() 210808 bar() 210808 Inner() 210808 barbase(copy ctor) 1310550 TFoo() 1310549 OK4 ~TFoo() 1310549 ~barbase() 1310550 barbase(copy ctor) 1310550 TFoo() 1310549 OK3 ~TFoo() 1310549 ~barbase() 1310550 barbase(copy ctor) 1310550 TFoo() 1310549 OK2 ~TFoo() 1310549 ~barbase() 1310550 ~Inner() 210808 ~bar() 210808 ~barbase() 210808 ~bar() 1310552 ~barbase() 1310552 ~Inner() 210792 ~bar() 210792 ~barbase() 210792 ~bar() 1310556 ~barbase() 1310556 PASSED QC Entry 78898

QC #: 78901 - Status: Closed

QC #: Project Date Reported: Area:78901 C++Builder 10/22/2009 Compiler\C++\Front End\Exception Handling

Description Steps:[QC Short Description] if- and for- statements - CB2010 fatal compiler bug [QC Description] This is fatal in CB2010. CB2007 exhibits problem in executing the attached code as well, but it 'only' missed 2 d'tor calls when unwinding. CB2010 calls the wrong d'tor and missed 4 d'tor calls for if-statement while calling the wrong d'tor *twice* for the for-statement! Calling the wrong d'tor (~Helper() ) with a bogus 'this' pointer is fatal in any non-trivial apps, let alone doing it twice in case of the for-statement. In CB2007 some classes may get by just fine, but with CB2010 caling the *wrong* d'tor with an invalid 'this' pointer (it can't be valid anyway since there's no corresponding c'tor called for this d'tor) will most likely crash an app. Not to mention also that it missed 4 d'tors instead of just 2 (which is already bad enough).

bcc32 if_exception_bug.cpp run if_exception_bug.exe bcc32 for_exception_bug.cpp run for_exception_bug.exe

CB2010: bcc32 if_exception_bug.cpp barbase() 1310588 bar() 1310588 barbase() 10670328 bar() 10670328 Inner() 10670328 barbase() 1310572 bar(copy ctor) 1310572 FATAL COMPILER ERROR!!!!!!!!!!!!!!!!!! ~Helper() 1310564 ~bar() 1310572 ~barbase() 1310572 ~barbase() 1310588 FAILED 3 CB2007: bcc32 if_exception_bug.cpp barbase() 1310588 bar() 1310588 barbase() 9516528 bar() 9516528 Inner() 9516528 barbase() 1310572 bar(copy ctor) 1310572 ~Inner() 9516528 ~bar() 9516528 ~barbase() 9516528 ~bar() 1310588 ~barbase() 1310588 FAILED 2 MSVC2005: cl /EHsc if_exception_bug.cpp barbase() 1310556 bar() 1310556 barbase() 210792 bar() 210792 Inner() 210792 barbase() 1310548 bar(copy ctor) 1310548 ~bar() 1310548 ~barbase() 1310548 ~Inner() 210792 ~bar() 210792 ~barbase() 210792 ~bar() 1310556 ~barbase() 1310556 PASSED ------------------------------------------------ CB2010: bcc32 for_exception_bug.cpp barbase() 1310588 bar() 1310588 barbase() 10670328 bar() 10670328 Inner() 10670328 barbase() 1310564 bar(copy ctor) 1310564 FATAL COMPILER ERROR!!!!!!!!!!!!!!!!!! ~Helper() 1310580 ~bar() 1310564 ~barbase() 1310564 FATAL COMPILER ERROR!!!!!!!!!!!!!!!!!! ~Helper() 1310580 ~Inner() 10670328 ~bar() 10670328 ~barbase() 10670328

~bar() 1310588 ~barbase() 1310588 FAILED -2 CB2007: bcc32 for_exception_bug.cpp barbase() 1310588 bar() 1310588 barbase() 9516528 bar() 9516528 Inner() 9516528 barbase() 1310564 bar(copy ctor) 1310564 ~Inner() 9516528 ~bar() 9516528 ~barbase() 9516528 ~bar() 1310588 ~barbase() 1310588 FAILED 2 MSVC2005: cl /EHsc if_exception_bug.cpp barbase() 1310556 bar() 1310556 barbase() 210792 bar() 210792 Inner() 210792 barbase() 1310548 bar(copy ctor) 1310548 ~bar() 1310548 ~barbase() 1310548 ~Inner() 210792 ~bar() 210792 ~barbase() 210792 ~bar() 1310556 ~barbase() 1310556 PASSED Compiles fine in Comeau non-strict mode. QC Entry 78901

QC #: 78935 - Status: Closed

QC #: Project Date Reported: Area: 78935 Delphi 10/23/2009 Debugger Description Steps:[QC Short Description] TAdoConnection Errors on close [QC Description] Only occurs within debugger while using TAdoConnection with ODBC, Stand Alone app work without error. TADOConnection fails in Debugger When using Debug DCUs ADODB.pas Error occurs on line 1651 procedure TADOConnection.DoDisconnect; begin if Assigned(ConnectionObject) then begin while InTransaction do RollbackTrans; ConnectionObject.Close; <-- Errors here end; end;

Procedure Any; begin AdoConnection1. Open; //Queries and data work perfectly AdoConnection1.Close; <--- Error Application terminates end;

QC Entry 78935 Added by Sysop <<<<<<<<<<<<<<<<< Please see comments of QC for more details. >>>>>>>>>>>>>>>>>

QC #: 78952 - Status: Closed

QC #: Project Date Reported: Area: 78952 Delphi 10/24/2009 IDE\Project Management Description Steps:[QC Short Description] Ctrl + Space n? funciona na IDE [QC Description] Nas vers?s anteriores do Delphi 2010 , utiliza a tecla Ctrl + Space para abrir a lista de propriedades, fun?es e procedures, agora no Delphi 2010 n? funciona. ========= In earlier versions of Delphi 2010, use CTRL + Space to open the list of properties, functions, and procedures now in Delphi 2010 does not work. QC Entry 78952

[ See resolution comment - MD ] Added by Sysop <<<<<<<<<<< I have noticed that after putting in project-> Options-> Delphi Compiler-> Unit aliases information WinTypes = Windows; Windows; WinProcs = DbiTypes = BDE; DbiProcs = BDE; DbiErrs = BDE the Properties popup appears again when I leave this option blank, no more popup appears. I have a new project with our which was imported from Delphi 2007. Project-> Options-> Delphi Compiler-> Unit aliases = BLANK occurs problem Project-> Options-> Delphi Compiler-> Unit aliases = WinTypes = Windows; Windows; WinProcs = DbiTypes = BDE; DbiProcs = BDE; DbiErrs = BDE is correct >>>>>>>>>>>

QC #: 78987 - Status: Closed

QC #: Project Date Reported: Area: 78987 C++Builder 10/26/2009 Linker Description Steps:[QC Short Description] Link Error detected LME1542 [QC Description] Our project has over 400 files and use the precompiled Heder. The main include file was created by precompile header expert form RAD Studio 2010. If I build my Project I get the link error detected LME1542 [ILINK32 Warnung] Warning: BSS : 0x00000000 / 0x00800000 [ILINK32 Warnung] Warning: CODE : 0x000ab3b8 / 0x00800000 [ILINK32 Warnung] Warning: DATA : 0x0004ef0a / 0x00800000 [ILINK32 Warnung] Warning: DEBNAM : 0x003c74c2 / 0x00800000[ILINK32 Warnung] Warning: DEBSYM : 0x000a76d9 / 0x00800000[ILINK32 Warnung] Warning: DEBTYP : 0x006517ca / 0x00800000[ILINK32 Warnung] Warning: Extdef flags : 0x0000053e / 0x00004000 [ILINK32 Warnung] Warning: Extdefs : 0x000014f8 / 0x00004000 [ILINK32 Warnung] Warning: External types : 0x00000d18 / 0x00040000 [ILINK32 Warnung] Warning: Import symbols : 0x0000030c / 0x00100000 [ILINK32 Warnung] Warning: Line number cache : 0x0001b74a / 0x00060000

Create a large project with more than 400 obj files an precompile header to link.

[ILINK32 Warnung] Warning: OBJ symbols : 0x0003dea4 / 0x00100000 [ILINK32 Warnung] Warning: Public GSX : 0x0000c5e4 / 0x000c0000 [ILINK32 Warnung] Warning: Public types : 0x0002cc58 / 0x00080000 [ILINK32 Warnung] Warning: Publics : 0x0006f504 / 0x000c0000 [ILINK32 Warnung] Warning: SegRelocs : 0x000dd824 / 0x00800000[ILINK32 Warnung] Warning: StringBlock : 0x0000c9f7 / 0x00800000 [ILINK32 Warnung] Warning: TLS : 0x0000009c / 0x00800000 [ILINK32 Warnung] Warning: Type names : 0x00086372 / 0x00100000 [ILINK32 Warnung] Warning: UNKNOWN : 0x00000018 / 0x00800000 [ILINK32 Warnung] Warning: Virdefs : 0x00004234 / 0x00020000 [ILINK32 Warnung] Warning: CODE : 0x00000000 / 0x00800000 [ILINK32 Warnung] Warning: D:/SVN_home/Debug/ERiskPower/ERiskPower.ilc: 0x02208000 / 0x08000000 [ILINK32 Warnung] Warning: D:/SVN_home/Debug/ERiskPower/ERiskPower.ild: 0x00629000 / 0x08000000 [ILINK32 Warnung] Warning: D:/SVN_home/Debug/ERiskPower/ERiskPower.ilf: 0x03307000 / 0x08000000 [ILINK32 Warnung] Warning: D:/SVN_home/Debug/ERiskPower/ERiskPower.ils: 0x03002000 / 0x03000000 [ILINK32 Warnung] Warning: D:/SVN_home/Debug/ERiskPower/ERiskPower.tds: 0x069c0000 / 0x08000000 [ILINK32 Warnung] Warning: DATA : 0x00031790 / 0x00800000 [ILINK32 Warnung] Warning: Extdef flags : 0x00000000 / 0x00004000 [ILINK32 Warnung] Warning: Extdefs : 0x00000000 / 0x00004000 [ILINK32 Warnung] Warning: Import symbols : 0x00000000 / 0x00100000 [ILINK32 Warnung] Warning: OBJ symbols : 0x000a0cc8 / 0x00100000 [ILINK32 Warnung] Warning: Public GSX : 0x0000c5e4 / 0x000c0000 [ILINK32 Warnung] Warning: Publics : 0x0006f504 / 0x000c0000 [ILINK32 Warnung] Warning: StringBlock : 0x0000000d / 0x00800000 [ILINK32 Warnung] Warning: Virdefs : 0x0000c5e4 / 0x00020000 [ILINK32 Warnung] Warning: unknown heap name : 0x08000000 / 0x08000000 [ILINK32 Warnung] Warning: Fehler gefunden (LME1542) [ILINK32 Fehler] Error: Linken kann nicht ausgeführt werden This Project was created and strated C++ Builder 2010! QC Entry 78987

QC #: 78995 - Status: Closed

QC #: Project Date Reported: Area: 78995 Delphi 10/26/2009 Compiler\Delphi\Generics Description Steps:[QC Short Description] F2084 Internal Error: URW1111 with Turbu revision 62 and QC 67762 code [QC Description] Enabling the Turbu code (http://turbu.googlecode.com/svn/trunk revision 62) that depends on a fix for QC 67762 can lead to an URW1111 error. -> see steps

- save the attached files - dcc32 -B TurbuQC67762URW1111.dpr expected: it compiles actual: turbu_tilesets.pas(17) Fatal: F2084 Internal Error: URW1111

QC Entry 78995 [Affect by NEW_ENGINE reintroduction]

QC #: 79001 - Status: Closed

QC #: Project Date Reported: Area: 79001 Delphi 10/26/2009 Compiler\Delphi\Generics Description Steps:[QC Short Description] F2084 Internal Error: URW1111 with an enumerator in QC 67762 related code in Turbu revision 62 [QC Description] Enabling the Turbu code (http://turbu.googlecode.com/svn/trunk revision 62) that depends on a fix for QC 67762 can lead to some URW1111 errors. One was reported as QC 78995/RAID 273429. This one is related to an enumerator. -> see steps QC Entry 79001 [Affected by NEW_ENGINE reintroduction]

- save the attached files - dcc32 -B TurbuQC67762URW1111_2.dpr expected: it compiles actual: after a little delay turbu_tilesets.pas(54) Fatal: F2084 Internal Error: URW1111 additional note: - turbu_tilesets.pas defines DELAY by default and the URW error also repeats without the define, but then without a delay - it compiles when you remove the GetEnumerator method from TRpgDataList<T> in turbu_classes.pas

QC #: 79036 - Status: Closed

QC #: Project Date Reported: Area:

79036 Delphi 10/27/2009 IDE\Project Management\Project Source

Description Steps:[QC Short Description] Linked property values are lost when project source is formatted. [QC Description] Any component which has a property value that is linked to something in another form or module will be lost if the source code formatter is run on the project source file. The code formatter inserts spaces in the module name comments which the project parser doesn't handle. Original code: DataModule in 'DataModule.pas' {DataModule4: TDataModule}, After formatting the source: DataModule in 'DataModule.pas' { DataModule4: TDataModule }, Reported by Kurt Bilde in public.delphi.ide newsgroup. https://forums.embarcadero.com/thread.jspa?messageID=174961&tstart=0#174961QC Entry 79036

Open the attached project. Observe the DBGrid on MainForm is linked to the DataSource in the DataModule. View | Project Source Right click the editor and choose "Format Source". Save, Close, and Reopen the project. Look at the "DataSource" property on the DBGrid, it's now blank.

QC #: 79044 - Status: Closed

QC #: Project Date Reported: Area: 79044 Delphi 10/27/2009 Database\DataSnap Description Steps:

[QC Short Description] ISAPI based server crash when accessed from multiple client [QC Description] ISAPI based datasnap server(.dll) hosted on IIS 7.5 crash when accessed from multiple client. Tested environment, Windows 7(32bit), IIS 7.5 - ISAPI based DataSnap server which has simple server method(EchoString) - Multiple Delphi Win32 DataSnap clients which call DataSnap service every 1 second via TSQLConnection and TSQLServerMethod Please see attached projects(Server, Client). QC Entry 79044

1. use Windows 7, IIS 7.5 with ISAPI support 2. create ISAPI based simple DataSnap server using Wizard Please see isapitest project attached. 3. build the server dll and copy it to C:\inetpub\wwwroot 4. create Delphi Win32 DataSnap client Please see isapiclient project attached. 5. build it and launch 2 clients 6. press Start button 7. please wait for a while. Clients get various errors(AV, Internal Server Error(500) or Session expired etc...) and crash. In this case, the ISAPI dll has been crashed, too... Note: Even if I change LifeCycle property of TDSServerClass class from Session to Invocation, same error still occurs.

QC #: 79047 - Status: Closed

QC #: Project Date Reported: Area: 79047 Delphi 10/27/2009 Database\DataSnap Description Steps:[QC Short Description] HTTP based DataSnap client causes lots of memory leaks [QC Description] When HTTP based DataSnap standalone server is called by DataSnap client via HTTP protocol, client application causes lots of memory leaks per call. This memory leaks can be detected ReportsMemoryLeaksOnShutdownand we can see increase of memory usage with TaskManager. MemoryManager reports leaks when terninating a client application as below 21-28: TMemoryStream x NN .... This issue is caused by generated proxy and TSQLServerMethod. Please see attached quite simple test proejcts(Server/Client). QC Entry 79047

1. create simple HTTP based DataSnap server via Wizard. Hostname is localhost. Port number is 8000. Please see attached project, 'httpserver' 2. build the server and run it. 3. create simple HTTP based DataSnap client which call a server method, 'EchoString'. Please see attached project, 'httpclient' 4. build client and run it. 5. press start button and close the client 6. MemoryManager reports lots of memory leaks

QC #: 79067 - Status: Closed

QC #: Project Date Reported: Area: 79067 Delphi 10/28/2009 VCL\Additional Controls Description Steps:[QC Short Description] Tab Order Editor unavailable to TCategory Panel [QC Description] The Popup Menu "Tab Order..." in design time is unavailable to TCategorypanel component. QC Entry 79067

1 File-> New -> Vcl Forms Application - Delphi 2 Add to form TCategoryPanelGroup 3 In CategoryPanelGroup Click Right Button mouse and later Click in "New Panel" popup menu option to add TCategoryPanel. 4 Ctrl + Shift + P and add four TEdit and one TButton 5 In CategoryPanel Click Right Button and later Click in "Tab Order.." popup menu option. 6 The Edit Tab Order show message :TCategoryPanelSurface, preventing alter taborder property to refer controls.

QC #: 79153 - Status: Closed

QC #: Project Date Reported: Area: 79153 Delphi 11/1/2009 Database\DataSnap Description Steps:[QC Short Description] TJSONString.ToBytes fails to convert Unicode chars [QC Description] TJSONString.ToBytes fails to convert Unicode chars which are between U+0080 and U+00FF. For example, multiply operation charcter(x = U+00D7) has been converted invalid data, because U+00D7 has been handled as byte(ASCII character) data instead of Unicode character. It must be converted to \u00D7 by the method. The bug exist in Line#1813 of DBXJSON.pas. ----- ... or (CurrentChar > WideChar(255)) then must be ... or (CurrentChar > WideChar(127)) then ----- QC Entry 79153 Added By Sysop <<<<<<<<<<<<< In 'DBXStream.pas', TDBXJSonStreamWriter.WriteString method also has same bug. >>>>>>>>>>>>>

DataSnapJSON.Native.DB.Test.exe connection=dsconnection -s:Test_JSON_String -or- Please return U+00D7 character as string from a server method of DataSnap Server.

QC #: 79251 - Status: Closed

QC #: Project Date Reported: Area:79251 Delphi 11/4/2009 RTL\Delphi\File Management Description Steps:[QC Short Description] TPath.GetTempFileName returns incorrect length string. [QC Description] NULL character and garbage character are included in path string, the length of string is not right. ---------------------------------------- // procedure TForm1.Button1Click(Sender: TObject); var TempFile:UnicodeString; TempLeng:Integer; begin TempFile := TPath.GetTempFileName; TempLeng := Length(TempFile); Edit1.Text := TempFile; Edit2.Text := Format('%d', [TempLeng]); end; ---------------------------------------- QC Entry 79251

Compile and run the attached application below. See the following program output indicating failure. FAIL - NULL character unexpected present in string NullLoc = 65 TempLeng = 260 "C:\Documents and Settings\testuser\Local Settings\Temp\tmp74.tmp " Notice that TPath.GetTempFileName returns a string that is not terminated at the end of the filename and contains an embedded NULL. program BTS273561; { TPath.GetTempFileName returns incorrect length string. } {$APPTYPE CONSOLE} uses SysUtils, IOUtils; procedure DoTest; var TempFile:UnicodeString; TempLeng:Integer; NullLoc: Integer;

begin TempFile := TPath.GetTempFileName; TempLeng := Length(TempFile); NullLoc := Pos(#0, TempFile); if NullLoc <> 0 then begin WriteLn('FAIL - NULL character unexpected present in string'); WriteLn(' NullLoc = ', NullLoc); WriteLn(' TempLeng = ', TempLeng); WriteLn('"', TempFile, '"'); end else WriteLn('PASS'); end; begin try DoTest; except on E: Exception do begin WriteLn('FAIL - Exception Error'); WriteLn(' ClassName=', E.ClassName); WriteLn(' Message=', E.Message); end; end; end.

QC #: 79312 - Status: Closed

QC #: Project Date Reported: Area: 79312 Delphi 11/7/2009 IDE\Menus Description Steps:[QC Short Description] Bookmarks are not checked [QC Description] Set bookmarks are not shown as checked menu items like in earlier versions. Additional info by USc: This is regression from D2007 that already happened in D2009. -> see steps and attached image QC Entry 79312

Steps by USc: - start Delphi - create a new console app - place a new bookmark by CTRL+SHIFT+1 (or with the editors popup menu "Toggle Bookmarks" | "Bookmark 1") - show the editors popup menu and have a look at the submenu items of "Toggle Bookmarks" and "Goto Bookmarks" expected: the icon of "Bookmark 1" is highlighted actual: nothing is highlighted (have a look at the attached image and see the difference between D2007 and D2009/D2010) Original steps: 1. Open the bookmarks context menu 2. Click on a bookmark to set it: it is set in the editor 3. Open the bookmarks contextmenu again: you don't see which item is set already

QC #: 79342 - Status: Closed

QC #: Project Date Reported: Area:79342 C++Builder 11/9/2009 IDE\Code Editor\Formatting Description Steps:[QC Short Description] format source error when the L or LL following a digital value [QC Description] The souce code that include a L or LL (long long) in a value. Then format source will generate E2257. for example below static GUID GUID_DIBCTL = { 0xcc7bfb46L, 0xf175, 0x11d1, 0xa3, 0x92, 0x00, 0xe0, 0x29, 0x1f, 0x39, 0x59

The souce code that include a L or LL (long long) in a value. Then format source will generate E2257. for example below static GUID GUID_DIBCTL = { 0xcc7bfb46L, 0xf175, 0x11d1, 0xa3, 0x92, 0x00, 0xe0, 0x29, 0x1f, 0x39, 0x59 }; run format source then we get static GUID GUID_DIBCTL = { 0xcc7bfb46 L, 0xf175, 0x11d1, 0xa3, 0x92, 0x00, 0xe0, 0x29, 0x1f, 0x39, 0x59 }; 0xcc7bfb46L change to 0xcc7bfb46 L (a new space is added) then compile error.

}; run format source then we get static GUID GUID_DIBCTL = { 0xcc7bfb46 L, 0xf175, 0x11d1, 0xa3, 0x92, 0x00, 0xe0, 0x29, 0x1f, 0x39, 0x59 }; 0xcc7bfb46L change to 0xcc7bfb46 L (a new space is added) then compile error. QC Entry 79342

QC #: 79401 - Status: Closed

QC #: Project Date Reported: Area:79401 Delphi 11/10/2009 Resourcing\BRCC/BRCC32 Description Steps:[QC Short Description] Compile a project that has custom .RC file always create a .tmp file in %TEMP% folder [QC Description] My project has a {$R 'app.res' 'app.rc'} entry. Each time I compile the project a .tmp file will be created in %TEMP% folder. The .tmp files grows to few thousand after a period of time. QC Entry 79401

1. Extract sample project 2. Use windows explorer and navigate to %TEMP% folder. Clear all unnecessary temp files first 3. Build the project. 4. A .tmp file will be generated in %TEMP% folder. 5. Build the project one more time and a new .tmp file will be generated in %TEMP% folder.

QC #: 79449 - Status: Closed

QC #: Project Date Reported: Area:

79449 Delphi 11/12/2009 IDE\Translation Tools\Resource DLL Wizard

Description Steps:[QC Short Description] Resource DLL Wizard generates invalid DFM, ObjectTextToResource failed: Identifier expected on line [QC Description] It looks the Resource DLL wizard does not handle correctly some dfm constructs and outputs the wrong data. For example where my dfm have: ImageInfo = < item Image.Data = { 36040000424D3604000000000000360000002800000010000000100000000100 The .err_dfm has ImageInfo= <item Image.Data = 36040000424D3604000000000000360000002800000010000000100000000100

Steps by USc using a renamed version of the component from "Bug Report Details: cxImageList breaks localization project (ITE)" http://www.devexpress.com/Support/Center/p/B94485.aspx (renamed because TComponent1 isn't that good for a component name) - save the files from the subfolder New - start Delphi - open and install FoocxImageListPackage.dpk - close FoocxImageListPackage.dpk - open FoocxImageListLocalizationTest.dpr - call the Resource DLL wizard (Project | Languages | Add) and a new language following the steps expected: the language can be successfully added actual: after the question //----->>> [Window Title] Confirm [Content] ...\FoocxImageListLocalizationTest.dproj: This project needs to be compiled for the Resource DLL Wizard to finish. Compile the project? [Yes] [No] //<<<----- appears the error message //----->>> [Window Title] Error [Content] ObjectTextToResource failed: Identifier expected on line 26 - File saved: ...\<Languagefolder>\FoocxImageListLocalizationTestMain.ERR_DFM [OK] //<<<----- - open the collection editor for FoocxImageList1.Images - remove the first item - call the Resource DLL wizard again and another new language following

(that is a Devexpress TcxImageList, see also here: http://www.devexpress.com/Support/Center/p/B94485.aspx) Note the missing starting curly brace. This error is repeated several times. Therefore, our project is not localizable using Delphi. NOTE: SAME ERROR USING DELPHI 2010 TRIAL!!!!! QC Entry 79449

the steps expected: the language can be successfully added actual: //----->>> [Window Title] Error [Content] ObjectTextToResource failed: Line too long on line 26 - File saved: ...\<Languagefolder>\FoocxImageListLocalizationTestMain.ERR_DFM [OK] //<<<----- Additional notes: - repeats also with Delphi 2009 and 2010 - affects also the JVCL (see original test case) and maybe TMS too (not tested; see QC 7839) Original steps (requires the JVCL component TJvImageList to be installed; files in subfolder Original): 1) Open the attached project 2) Run the resource DLL wizard to localize the project (I select Italian language) 3) The error appears.

QC #: 79482 - Status: Closed

QC #: Project Date Reported: Area:79482 Delphi 11/13/2009 IDE\Code Editor\Error Insight Description Steps:[QC Short Description] Controls.THintInfo incorrectly underlined [QC Description] The type Controls.THintInfo is incorrectly underline by the editor when it is used in a method definition. The compiler accepts and compiles it correctly. QC Entry 79482

1) Start BDS in Delphi mode 2) Create a VCL project 3) Add to the form class, the following methods : Type TForm1 = Class(TForm) procedure FormCreate (aSender : TObject ); protected procedure ShowHint ( var HintStr : String; var CanShow : Boolean; var HintInfo : Controls.THintInfo ); end; procedure TForm1.FormCreate ( aSender : TObject ); begin ... Application.OnShowHint := ShowHint; ... end; procedure TForm1.ShowHint ( var HintStr : String; var CanShow : Boolean; var HintInfo : Controls.THintInfo ); begin ... end; 4) The editor underlines incorrectly the type Controls.THintInfo.

QC #: 79485 - Status: Closed

QC #: Project Date Reported: Area:79485 Delphi 11/13/2009 Database\Data Aware Controls\TDBGrid

Description Steps:[QC Short Description] Keyboard layout swtching when exiting dbgrid control [QC Description] Added by Sysop <<<<<<<<<<<<<<<<<< Reproducing is really easy; You should have at least 2 input locales installed to be able to duplicate. -> Create a new VCL forms application -> Put a Button, and then a DBGrid on the form, with this order. -> Double click the form and put the below code on the OnCreate event; SysLocale.FarEast := True; (this step might be unnecessary depending on your system input locale) -> Run the project -> Press Alt+Shift to change your input locale to anything other than the default one (or any other means if you've changed the default shortcut keys)

Hi everybody, I recently upgraded from DELPHI 5 to RAD Studio 2010 PRO. I receive very annoying problem: When I have dbgrid control in my form, when dbgrid lose focus, keyboard layout turns to "default". My programs are used in Bulgaria, where normaly default layout is English and alternative (but mostly used!) is Bulgarian, it present annoyng problem. In older version i haven't such problem. If someone has solution to this problem, please post it here or send me message at: office at promsoft dot bg Best regards Georgi

-> Click the DBGrid -> Click the Button expected: The input locale does not default to the default one. actual: The input locale defaults to the default locale. >>>>>>>>>>>>>>>>>> QC Entry 79485

QC #: 79612 - Status: Closed

QC #: Project Date Reported: Area:

79612 Delphi 11/18/2009 Compiler\Delphi\Code Generation/Optimization

Description Steps:[QC Short Description] AV while delayed loading of SHGetFolderPathAndSubDir [QC Description] Delayed loading of SHGetFolderPathAndSubDir failed if it the ONLY used shell function. (see reproducable sample) It should call the DelayLoadHelper but jumps to an illegal address (--> AV) If I call explicit the WideChar version "SHGetFolderPathAndSubDirW" it works correct. QC Entry 79612

program ShellTest; {$APPTYPE CONSOLE} uses Windows, SysUtils, ShlObj; var dirName : array [0..MAX_PATH] of Char; begin try SHGetFolderPathAndSubDir(HWND(0), CSIDL_WINDOWS, THandle(0), SHGFP_TYPE_CURRENT, 'system32', dirName); //--> Access violation //-- Uncomment next line and the AV is away!!?? //SHGetFolderPathAndSubDirW(HWND(0), CSIDL_WINDOWS, THandle(0), SHGFP_TYPE_CURRENT, 'system32', dirName); except on E: Exception do begin Writeln(E.ClassName, ': ', E.Message); end; end; end.

QC #: 79672 - Status: Closed

QC #: Project Date Reported: Area: 79672 C++Builder 11/20/2009 VCL\Core VCL Classes Description Steps:[QC Short Description] TStringStream Encoding -> SaveToFile -> no BOM information [QC Description] TStringStream does not support the encoding correct while saving text using SaveFromFile. So, when you want to read the file with an editor or with the StringStream and you didn't specify the encoding, the string value is defect. There is no BOM information in the file, so no auto detection of the encoding is not working. QC Entry 79672

String s_Test = L"Test???"; TStringStream * pS = new TStringStream (s_Test,TEncoding::Unicode,false); pS->SaveToFile("C:\\Testtxt.txt"); delete pS; pS = NULL; TStringStream * pS1 = new TStringStream (); pS1->LoadFromFile ("c:\\Testtxt.txt"); String sData = pS1->ReadString(1000000); delete pS1; pS1 = NULL;

QC #: 79698 - Status: Closed

QC #: Project Date Reported: Area: 79698 Delphi 11/20/2009 RTL\Delphi\Other RTL Description Steps:[AEC][JJS] [QC Short Description]

Steps by USc: - save the following test case as BcdCompareTest.dpr - dcc32 BcdCompareTest.dpr - execute BcdCompareTest.exe expected:

BcdCompare returns wrong result [QC Description] The following code returns 0, instead of 1: BcdCompare(StrToBcd('0,5'), StrToBcd('0,05')); QC Entry 79698

PASS actual: FAIL program BcdCompareTest; {$APPTYPE CONSOLE} uses SysUtils, FMTBcd; var B1, B2: TBcd; begin DecimalSeparator := '.';//to make sure that StrToBcd does not fail with different OS settings B1 := StrToBcd('0.5'); B2 := StrToBcd('0.05'); if BcdCompare(B1, B2) = 1 then WriteLn('PASS') else WriteLn('FAIL'); end. Original Steps: procedure TForm1.FormCreate(Sender: TObject); begin ShowMessage(IntToStr(BcdCompare( StrToBcd('0,5'), StrToBcd('0,05')))); end;

QC #: 79747 - Status: Closed

QC #: Project Date Reported: Area:79747 Delphi 11/23/2009 Compiler\Delphi\Generics Description Steps:[JJS] [QC Short Description] Generics fail with "E2506 Method of parameterized type declared in interface section must not use local symbol '...' " when a circular unit reference is encountered. [QC Description] When compiling the attached project, the compiler incorrectly gives the error: "Generics fail with "E2506 Method of parameterized type declared in interface section must not use local symbol '...' " QC Entry 79747

Compile the attached project below and see the following unexpected error. uBTS273734a.pas(34) Error: E2506 Method of parameterized type declared in interface section must not use local symbol 'TDataManager.CreateEntity<uBTS273734a.TEntityReferenceColumn<T>.T>' program BTS273734; {$APPTYPE CONSOLE} uses uBTS273734a, uBTS273734b; begin WriteLn('PASS'); //PASS on compile// end. unit uBTS273734a; interface uses uBTS273734b; type { TEntityReferenceColumn } TEntityReferenceColumn<T: TEntity, constructor> = class strict private FValue: T; FEntity: TEntity; public constructor Create(AEntity: TEntity); end; implementation { TEntityReferenceColumn } constructor TEntityReferenceColumn<T>.Create(AEntity: TEntity); begin inherited Create; FEntity := AEntity; FValue := FEntity.DataManager.CreateEntity<T>; //#1// end; end. unit uBTS273734b; interface

type TDataManager = class; { TEntity } TEntity = class protected FDataManager: TDataManager; public constructor Create; property DataManager: TDataManager read FDataManager; end; TEntityClass = class of TEntity; { TDataManager } TDataManager = class public function CreateEntity<T: TEntity, constructor>: T; end; implementation { Removing uBTS273734c uses I have no error } uses uBTS273734c; { TEntity } constructor TEntity.Create; begin inherited Create; end; { TDataManager } function TDataManager.CreateEntity<T>: T; begin result := T.Create; result.FDataManager := Self; end; end. unit uBTS273734c; interface // ... implementation { Removing EColumns uses I have no error } uses uBTS273734a; // ... end.

QC #: 79760 - Status: Closed

QC #: Project Date Reported: Area:

79760 Delphi 11/24/2009 Compiler\Delphi\Generics Description Steps:[AEC][JJS] [QC Short Description] 'as' and 'is' operators fail when sharing an instance of a generic class across units as TObject. [QC Description] I have declared a generic class in one unit. The same unit provides a method that returns an instance of the generic class as a TObject. In the main method of the application (another unit) the aforementioned function is called, yielding a TObject, which I then cast to its known generic type with the 'as' operator. The project compiles well, but breaks at runtime: When casting the TObject to the generic type, I receive an EInvalidCast exception. Examining the object with the 'is' operator also seems to indicate that the object is not in fact of the type I am casting to. QC Entry 79760

Compile and run the attached application below. See the following program output indicating failure. FAIL program BTS273770; { 'as' and 'is' operators fail when sharing an instance of a generic class across units as TObject. } {$APPTYPE CONSOLE} uses SysUtils; type TMyClass<T> = class public Value: T; end; function CreateObject: TObject; begin Result := TMyClass<Integer>.Create; Assert(Result.ClassNameIs('TMyClass<System.Integer>')); Assert(Result is TMyClass<Integer>); end; procedure Reproduce; var Obj: TObject; Obj2: TMyClass<Integer>; ok: boolean; begin Obj := CreateObject; ok := true; try Assert(Obj.ClassNameIs('TMyClass<System.Integer>')); // <-- Poor man's type check succeeds: ok := ok and true; except on E: EAssertionFailed do ok := ok and False; end; try // Assert(Obj is TMyClass<System.Integer>); // <-- This fails! if not(Obj is TMyClass<System.Integer>) then ok := ok and true else ok := ok and False; Obj2 := Obj as TMyClass<System.Integer>; // <-- This also fails! Obj2.Value := 3; if (Obj2.Value = 3) then ok := ok and true else ok := ok and False; except on E: EInvalidCast do ok := ok and False; end; if ok = False then writeln('FAIL') else writeln('PASS'); end; begin

Reproduce; end.

QC #: 79767 - Status: Closed

QC #: Project Date Reported: Area: 79767 Delphi 11/24/2009 IDE\Form Designer Description Steps:[QC Short Description] Editing a PopupMenu increases form height [QC Description] Drop a TMainMenu and a TPopupMenu on the form, then add at least one menuitem for the MainMenu. Now double click on the PopupMenu component, you will find the height of the form increased by 20 pix each time. Added by Sysop <<<<<<<<< Please see comments for more details. >>>>>>>>> QC Entry 79767

Drop a TMainMenu and a TPopupMenu on the form, then add at least one menuitem for the MainMenu. Now double click on the PopupMenu component, you will find the height of the form increased by 20 pix each time.

QC #: 79776 - Status: Closed

QC #: Project Date Reported: Area: 79776 Delphi 11/24/2009 IDE\Object Inspector Description Steps:[QC Short Description] Clicking on Object Inspector Rejects Focus [QC Description] This phenomenon is extremely common, but it does not happen every time -- which makes it more difficult to live with -- it kills your confidence, because when you are click on the OI, you have to hover and figure out if the click took. It would almost be better if it always happened. I experience this phenomenon in Classic Undocked mode. Expectation: click anytime on the OI, and have the focus stay where I clicked. QC Entry 79776

see Description

QC #: 79813 - Status: Closed

QC #: Project Date Reported: Area:79813 C++Builder 11/25/2009 AddOn

Description Steps:[QC Short Description] Compiler error when using boost spirit headers [QC Description] Including <boost/spirit.hpp> causes compilation error as below. Due tu this, there is no way to compile boost spirit apps, but in the CB 2009 it worked well.

1. Create new project 2. Add: #include <boost/spirit.hpp> at the main cpp file 3. Compile the project

[BCC32 Error] closures.hpp(237): E2299 Cannot generate template specialization from 'impl::closure_frame_holder<FrameT>' Full parser context Unit1.cpp(7): #include D:\Dev\RADStudio70\include\boost_1_39\boost/spirit.hpp spirit.hpp(25): #include D:\Dev\RADStudio70\include\boost_1_39\boost/spirit/include/classic.hpp classic.hpp(30): #include D:\Dev\RADStudio70\include\boost_1_39\boost/spirit/home/classic/attribute.hpp attribute.hpp(35): #include D:\Dev\RADStudio70\include\boost_1_39\boost/spirit/home/classic/attribute/closure.hppclosure.hpp(21): #include D:\Dev\RADStudio70\include\boost_1_39\boost/spirit/home/classic/phoenix/closures.hppclosures.hpp(22): namespace phoenix closures.hpp(215): class closure_frame<ClosureT> QC Entry 79813

QC #: 79875 - Status: Closed

QC #: Project Date Reported: Area: 79875 Delphi 11/28/2009 Compiler\Delphi\Generics Description Steps:[AEC][JJS] [QC Short Description] Internal Error URW1111, when using "type" keyword to force a new type based on TArray<T> [QC Description] By USc: -> see steps This issue may be related to Report No: 77575 (RAID: 272825) Status: Open F2084 Internal Error: URW1111 when using type TArray<T> http://qc.embarcadero.com/wc/qcmain.aspx?d=77575 QC Entry 79875

Steps by USc: - save the following three files or the attachment - dcc32 -B QC79875.dpr expected: it compiles actual: Unit2.pas(15) Fatal: F2084 Internal Error: URW1111 //--- QC79875.dpr --- program QC79875; {$APPTYPE CONSOLE} uses Unit1, Unit2; begin WriteLn('PASS');//on compile end. //--- Unit1.pas --- unit Unit1; interface type TIntArray = TArray<Integer>; implementation end. //--- Unit2.pas --- unit Unit2; interface uses Unit1; type TAgeArray = type TIntArray; implementation end. //--- Original steps: ------ Unit2 --------type TIntArray = TArray<Integer>; ----- Unit1 ------- uses Unit2; type TAgeArray = type TIntArray; If you try to do it within 1 unit, you get Error 2086: "Type TArray<T> Is not yet completely defined": type TIntArray = TArray<Integer>; TAgeArray = type TIntArray; // fails: Error 2086 TAgeArray2 = type TArray<Integer>; // fails: Error 2086

QC #: 79880 - Status: Closed

QC #: Project Date Reported: Area: 79880 Delphi 11/28/2009 IDE\Code Editor\ Description Steps:[QC Short Description] Cursor jumps after formatting selection [QC Description] When you format a source file with bookmarks then the cursor jumps to the last bookmark after formatting. This is regression from Delphi 2010 RTM. -> see steps QC Entry 79880

Open some unit, and set several bookmarks. Select piece of code (say, one procedure) and press Ctrl-D to format it. After formatting cursor jumps to the last bookmark, which is very unconvenient. It's not a problem when whole text is selected and formatted, but quite annoying when only selection is formatted. Steps by USc: - open the attached console app QC79880.dpr - set the following bookmarks #1 on line 13 ("function FooFunc...") #2 on line 91 ("begin") - select the lines 7 till 10 (the body of FormatMyBody) - put the cursor on line 7 - press CTRL + D to format the selection expected: the body of FormatMyBody was formatted and the cursor is on line 7 actual: the body of FormatMyBody was formatted, but the cursor is not visible and the status bar shows that the cursor is at 88:1

QC #: 79954 - Status: Closed

QC #: Project Date Reported: Area:79954 C++Builder 12/1/2009 Compiler\C++\Front End\Preprocessor

Description Steps:Regression from 2009 -P- switch does not work for cpp32 [QC Short Description] Preprocessor output changed [QC Description] For TAO/CIAO we use the cpp32 as preprocessor. with the upgrade from cb2009 to cb2010 the preprocessor output changed totally, we need to get the original output back QC Entry 79954

Create Test.idl with the contents: // // $Id: Test.idl 38436 2001-03-23 17:09:21Z coryan $ // /// Put the interfaces in a module, to avoid global namespace pollution module Test { /// A very simple interface interface Hello { /// Return a simple string string get_string (); /// A method to shutdown the ORB /** * This method is used to simplify the test shutdown process */ oneway void shutdown (); }; }; Run then cpp32 -q -P- Test.idl, with CB2009 we get: #line 1 "Test.idl" module Test { interface Hello { string get_string (); oneway void shutdown (); }; }; With CB2010 we get: /* Test.idl 1: */ /* Test.idl 2: */ /* Test.idl 3: */ /* Test.idl 4: */ /* Test.idl 5: */ /* Test.idl 6: */module Test /* Test.idl 7: */{ /* Test.idl 8: */ /* Test.idl 9: */interface Hello /* Test.idl 10: */{ /* Test.idl 11: */ /* Test.idl 12: */string get_string (); /* Test.idl 13: */ /* Test.idl 14: */ /* Test.idl 15: */ /* Test.idl 16: */ /* Test.idl 17: */ /* Test.idl 18: */oneway void shutdown (); /* Test.idl 19: */}; /* Test.idl 20: */}; /* Test.idl 21: */ /* Test.idl 22: */

QC #: 79959 - Status: Closed

QC #: Project Date Reported: Area:79959 Delphi 12/2/2009 Database\DBExpress\TSQLStoredProc

Description Steps:[Oracle] [QC Short Description] D2010: input-output parameters return garbage [QC Description] Execute a stored procedure that contains IN OUT params. It will return garbage instead of the real data. The same procedure worked in D2009. QC Entry 79959 Added by Sysop <<<<<<<<<<<<<< I think this issue is same as RAID#274657(QC#81496). >>>>>>>>>>>>>>

TDBXFulcrumBugsSuite.Native.Db.Test.exe connection=oracleconnection -s:TestRaid_274223 -OR- Run this script in Oracle10: CREATE OR REPLACE PACKAGE Packbasura AS PROCEDURE Prueba(pa_p1 VARCHAR2, pa_p2 IN OUT VARCHAR2); END Packbasura; / CREATE OR REPLACE PACKAGE BODY Packbasura AS PROCEDURE Prueba(pa_p1 VARCHAR2, pa_p2 IN OUT VARCHAR2) IS BEGIN pa_p2 := pa_p2 || ' m? salida'; END; END Packbasura; In Delphi set a SQLStoredProc schema, package and procname to run that procedure and use this code: with SQLStoredProc1 do begin Close; Parambyname('PA_P1').AsString := 'P1'; Parambyname('PA_P2').AsString := 'P2'; EXECPROC; SHOWMESSAGE(Parambyname('PA_P2').AsString); end; Expected: ShowMessage should show "P2 m? salida". Actual: it shows squares.

QC #: 79975 - Status: Closed

QC #: Project Date Reported: Area: 79975 Delphi 12/2/2009 Compiler\Delphi Description Steps:[AEC][JJS] [QC Short Description] Compiler - bad code generated for records results in a EInvalidPointer exception at runtime. [QC Description] Define a record structure type that contain dynamic parts (like string or dynamic array) and a set of functions (also operators) (See sample code). If we use this as type of a property and use the property within a open argument list (like "Format") the refernce counting of dynamic parts are destroyed at scope leaving. The attached sample demonstrates this behaviour very easy. It's absolutely FATAL behaviour, because the aftereffect are NOT predictable. QC Entry 79975

//-- call TestProcedure in a console application unit SampleClasses; interface uses SysUtils; type TSampleRecord = record //strict private m_InternalString: string; function ToString() : string; class operator Implicit(const a: string): TSampleRecord; overload; class operator Implicit(const a: TSampleRecord): string; overload; end; TSampleClass = class(TObject) strict Private FFilename : TSampleRecord; function GetFilePath(): TSampleRecord; function GetFileName(): TSampleRecord; function GetFilePathCrash: TSampleRecord; public pRefCounter : PLongInt; // ONLY a problem watcher constructor Create(const p_Filename : TSampleRecord); virtual; destructor Destroy(); override; property Filename : TSampleRecord read GetFileName; property FilePath : TSampleRecord read GetFilePath; property FilePath2 : TSampleRecord read GetFilePathCrash; end; procedure TestProcedure(); implementation { TSampleClass } constructor TSampleClass.Create(const p_Filename: TSampleRecord); var p : LongInt; begin self.FFilename := p_Filename; p := Longint(FFilename.m_InternalString); pRefCounter := PLongint(p - 8); end; destructor TSampleClass.Destroy; begin inherited; end; function TSampleClass.GetFileName: TSampleRecord; begin Result := self.FFilename; end; function TSampleClass.GetFilePath: TSampleRecord; begin Result := Format('[%s]', [self.FFilename.ToString]); // successfull (use field, NOT property) end; function TSampleClass.GetFilePathCrash: TSampleRecord; begin Result := Format('[%s]', [self.Filename.ToString]); // failed (use property, NOT field) end; { TString } class operator TSampleRecord.Implicit(const a: string): TSampleRecord; begin Result.m_InternalString := a; end; class operator TSampleRecord.Implicit(const a: TSampleRecord): string; begin Result := a.ToString(); end; function TSampleRecord.ToString: string; begin Result := m_InternalString; end; procedure TestProcedure(); var oSample : TSampleClass; oSourcePath : TSampleRecord; oFolderName : TSampleRecord; s : string; i : integer; begin try oSourcePath := 'D:\Project\Test2010\Workshop\_Output\_Source1'; oFolderName := ExtractFileName(oSourcePath); oSample := TSampleClass.Create('IMG6527.png'); WriteLn(' loop ref text'); for i := 0 to 10 do begin s := oSample.FilePath; // successfull WriteLn(i:10, oSample.pRefCounter^:5, ' ', s); end; WriteLn(' loop ref text'); for i := 0 to 10 do begin s := oSample.FilePath2; //**** Exception after N loops (look AT value of refcounter output) WriteLn(i:10, oSample.pRefCounter^:5, ' ', s); end; except on E: Exception do Writeln(E.ClassName, ': ', E.Message); end; end; end.

QC #: 80013 - Status: Closed

QC #: Project Date Reported: Area: 80013 Delphi 12/3/2009 VCL Description Steps:[QC Short Description] TreeView/TListView.OnDeletion is called when recreating the form [QC Description] The TreeView/TListView.OnDeletion event handler is called when the treeview/listview's parent form is recreated like in TForm.ShowModal.This can cause memory overwrite bugs because the nodes are backed up (including the Data property) and then restored after the recreation. Calling OnDelection can invalidate the Data property and after the recreation the Data property points to invalid memory. QC Entry 80013

1. Open the attached Delphi project 2. Start the application 3. Click on the "Demo TreeView" button 4. Click on the "Demo ListView" button Expected: None of the buttons raises an EInvalidPointer exception Actual: Both raise EInvalidPointer exceptions because OnDeletion is called twice on the same node.

QC #: 80019 - Status: Closed

QC #: Project Date Reported: Area: 80019 Delphi 12/3/2009 Midas\TClientDataSet Description Steps:[QC Short Description] Tclientdataset ignore Contraints [QC Description] Hi, In D2010 upd 2 if you set a customcontraint property on a Tfield of a TClientdataset when you post the record it doesn't check the constraints. QC Entry 80019

TDBXFulcrumBugsSuite.Native.DB.Test.exe connection=ibconnection -s:TestRaid_276675 -OR- You make a new project, you put a TClientDataset and define 2 TFields, for example a TStringField and a TIntegerField, in every field you have to set a constraint like x is null and for the integer field x > 10, now you put 2 DBedit, a dbNavigator and TDataSource and you link all, compile and run then program, now if you insert a new record ad save it, the constraint will be not fired, also if you set the constraints property of the TClientDataset component it doesn't work, this is a big problem, in my projects I use a lot the constraints, the same example in D2007 work perfectly

QC #: 80033 - Status: Closed

QC #: Project Date Reported: Area: 80033 C++Builder 12/4/2009 RTL\C++ Description Steps:[QC Short Description] StringBuilder append a String -> calling wrong overload method [QC Description] Call the Append Method of the StringBuilder object, the wrong overloaded method is called. QC Entry 80033

See following code: TStringBuilder* sb = new TStringBuilder(100); sb->Append(String ("Test")); sb->Append(";"); sb->Append("Test"); Edit1->Text = sb->ToString(); delete sb; ==> Result is: TestTrueTrue

QC #: 80110 - Status: Closed

QC #: Project Date Reported: Area: 80110 Delphi 12/7/2009 Midas\TClientDataSet Description Steps:[QC Short Description] Access Violation in Midas.dll on ClientDataSet ApplyUpdates [QC Description] Midas.dll in version 14.0.3513.24210 CDS gets data from MySQL 5.1 by TSQLDataSet. I have table with 23 fields. CDS has this fields created as persistance. Additionally in CDS is 12 InternalCalc fields. CDS.ApplyUpdates(0) generates "Access violation ... in module Midas.dll" in situation when applying updates of record and update process returns error (for ex. if another user have changed record). Problem occures during Reconcile process (I have checked this by calling Providers method ApplyUpdates and then Reconcilling result in CDS). When I have changed 3 of InternalCalc fields into Calculated fields everything is ok and error not occures. In another similar situation AV error occures after second CDS.ApplyUpdates(0) (after first is OK - normal update error in onReconcileError occures).

TDBXFulcrumbugsSuite.Native.DB.Test.exe connection=mysqlconnection -s:TestRaid_274032 -or- Click button in sample project but first read Readme.txt - some preparation is needed � @

QC Entry 80110

QC #: 80124 - Status: Closed

QC #: Project Date Reported: Area:80124 Delphi 12/7/2009 Midas\XML Midas\XMLMapper

Description Steps:[QC Short Description] Importing schema with XMLmapper in Delphi [QC Description] I try to import some valid schema (for xmlspy and oxygen) with XMLMapper in delphi and I have this error "Error Flux if:InfofileType unknown". I use namespace and this type is define in another file. Is there a way to solve this ? (I also try with Delphi 2010 demo and it still not work) http://stackoverflow.com/questions/1842420/importing-schema-with-xmlmapper-in-delphi QC Entry 80124

- Just go in XMLMapper - Import ServerAnswer.xsd you will get error

QC #: 80204 - Status: Closed

QC #: Project Date Reported: Area: 80204 C++Builder 12/9/2009 Compiler\C++ Description Steps:[QC Short Description] heap memory corruption [QC Description] I am trying to port an application from C++ Builder 2009 to 2010. I attach a skeleton program to reproduce the issue: basically, all it does is load the contents of the "famiglie.csv" file into an array of structures, and then displays this data into a Memo. On 2009, this code runs perfectly and no codeguard issues are reported. On 2010 (I am using the trial version), the first data record is correctly loaded into the corresponding structure, but gets mangled shortly after within rtl40.@System@Move$qqrpxvpvi Thanks for your help. Added by Sysop <<<<<<<<<<<<<< This issue is similar to QC#78772. Please see comments of QC for more information. >>>>>>>>>>>>>> QC Entry 80204

-Open the attached project1 in C++ Builder 2010 -Set a breakpoint at line 72 of Unit1.cpp and start the program -When the breakpoint hits, set a data breakpoint at the address of ef->desc.Data[0] with length = 4 -Continue running the program, the second breakpoint will hit and the call stack will show that the contents of that structure are being overwritten by the rtl40.@System@Move$qqrpxvpvi function. Resuming the execution results in a couple other breakpoint hits, then the messagebox indicating that the first structure is being corrupted appears (sometimes under the IDE window) and finally the Form1 displays only a couple of mixed strings (inconsistent with the data from the "famiglie.csv" file) in the Memo.

QC #: 80215 - Status: Closed

QC #: Project Date Reported: Area: 80215 Delphi 12/9/2009 Database\DBExpress Description Steps:[QC Short Description] Invalid BLOB handle when caling TAdoDbxDataReader.GetBytes multiple times [QC Description] When using AdoDbx to talk to an Interbase 2009 database, if you use TAdoDbxDataReader.GetBytes to first determine the size of the data in the blob field, and then call it again to actually read the data, the second read fails with 'Invalid BLOB handle' if the blob field contains 16383 bytes or more. QC Entry 80215

TDBXTiburonBugsSuite.Managed.Db.Test.exe connection=ibconnection -s:TestRaid_273977 -or- Download and execute the attached C# console application. The zip file includes the database used for the test.

QC #: 80304 - Status: Closed

QC #: Project Date Reported: Area:80304 Delphi 12/12/2009 Compiler\Delphi\Anonymous Methods

Description Steps:[AMP] [QC Short Description] when an inlined method, which has an anonymous method as parameter, are called twice, its proc argument won't be executed as expected. [QC Description] see the following code: procedure DoLock(obj: TObject; proc: TProc); inline; begin MonitorEnter(obj); try proc; finally MonitorExit(obj); end; end; procedure Test; var obj1: TObject; obj2: TObject; n: Integer; begin n := 0; obj1 := TObject.Create; obj2 := TInterfacedObject.Create; try DoLock(obj1, procedure begin Assert(False); // This proc won't be executed. end ); DoLock(obj2, procedure begin Inc(n); Assert(True); // This proc will be executed twice!! end ); Assert(n = 2); finally obj1.Free; obj2.Free;

Compile and run the attached application or the one below. uses SysUtils; procedure DoLock( obj: TObject; proc: TProc );inline; begin MonitorEnter( obj ); try proc; finally MonitorExit( obj ); end; end; procedure Test; var obj1: TObject; obj2: TObject; n: Integer; testOK : Boolean; begin n := 0; obj1 := TObject.Create; obj2 := TInterfacedObject.Create; try DoLock( obj1, procedure begin Writeln( 'First call.' );// This proc won't be executed. end); DoLock(obj2, procedure begin Inc(n); // This proc will be executed twice!! Writeln( 'Second call. ' ); end ); finally obj1.Free; obj2.Free; end; end;

end; end; QC Entry 80304

begin try { TODO -oUser -cConsole Main : Insert code here } Test(); Readln; except on E: Exception do Writeln( 'FAIL ' + E.ClassName, ': ', E.Message ); end; end.

QC #: 80313 - Status: Closed

QC #: Project Date Reported: Area: 80313 Delphi 12/13/2009 VCL\Docking Description Steps:[QC Short Description] Hidden dock zone blocks resize of adjoining dock zones [QC Description] The logic that constrains dock zones during resize fails to ignore hidden dock zones. During resize a dock zone is constrained so it doesn't overlap more than one adjoining dock zone. The code that looks at the adjoining dock zone fails to take the zones visibility into account. In TDockTree.GetNextLimit: if AZone.FNextSibling <> nil then LimitResult := AZone.FNextSibling.ZoneLimit should be: if AZone.NextVisible <> nil then LimitResult := AZone.NextVisible.ZoneLimit QC Entry 80313

The problem can be reproduced with the Delphi IDE. Starting with the Default Layout: 1) Undock the Project Manager pane and dock it under the Structure pane, above the Object Inspector pane. You should now have three panes docked vertically, like this: [Structure] [Project Manager] [Object Inspector] 2) Close the [Project Manager] pane. 3) Try to resize the Structure pane vertically. It is constrained by the, now hidden, Project Manager dock zone. Exp: The height of the Structure pane can be made smaller or taller. Act: The height of the Structure pane can only be made smaller.

QC #: 80314 - Status: Closed

QC #: Project Date Reported: Area:80314 Delphi 12/13/2009 IDE\Code Editor\Error Insight Description Steps:[QC Short Description] $ELSEIF allows execution of $ELSE [QC Description] If you have code that is conditionally compiled by using $IF, $ELSEIF and $ELSE and the $IF branch is taken, Error Insight will show false positives in the $ELSE branch. QC Entry 80314

1. Create a new Delphi Console application 2. Copy the code below into it Expected: No Error Insight error messages Actually: Error Insight shows error messages program Project1; procedure Test; {$IF defined(MSWINDOWS)} begin end; {$ELSEIF defined(LINUX)} Ok, you are using Linux {$ELSE} This should not happen under Windows <<< Error Insight expects "BEGIN" {$IFEND} begin end.

QC #: 80334 - Status: Closed

QC #: Project Date Reported: Area: 80334 C++Builder 12/14/2009 Documentation Description Steps:[QC Short Description] See documentation on TThread::Synchronize.

Documentation on TThread::Synchronize is incomplete [QC Description] TThread::Synchronize() was expanded in CB2006 to be callable from any thread, with and without a TThread object instance. But Help says only about "classical" Synchronize: ------------------------------------------ "static void __fastcall Synchronize (Classes::TThread * AThread, System::DelphiInterface<Classes::TThreadProcedure> AThreadProc) Executes a method call within the main thread. Synchronize causes the call specified by AMethod to be executed using the main thread, thereby avoiding multi-thread conflicts. The current thread is passed in the AThread parameter." ------------------------------------------ Usage TThread::TThread(NULL, SyncMethod); TThread::TThread(NULL, SyncProc); is completely missed in documentation. QC Entry 80334

QC #: 80398 - Status: Closed

QC #: Project Date Reported: Area:80398 Delphi 12/16/2009 AddOn\Interbase components Description Steps:[QC Short Description] Access violation at address 407709B5 in module 'ibxpress140.bpl'. [QC Description] Access violation at address 407709B5 in module 'ibxpress140.bpl'. Read of address 000000EC. IBQuery.SQL.Text := 'select FIELD from TABLE where ID = :ID; /* SQL server Firebird 2.0.5, default Charset Win1250 FIELD is BLOB subtype 1 (text) IBQuery is TIBQuery (Interbase component) */ Added by Sysop <<<<<<<<<<<<<<< Please see comments of QC for more detail and possible workaround.>>>>>>>>>>>>>>> QC Entry 80398

IBQuery.Open; exception ... Added by Sysop From a comment of QC >>>>>>>>>>>>>>>>>>>>>>>> This access violation comes from IBCustomDataSet.pas function TIBDSBlobStream.Seek(Offset: Longint; Origin: Word): Longint; ... //when opening an empty dataset, this row gives an error, because FBlobStream.Database is not assigned: if FBlobStream.Database.CharacterSetCodePage = 0 then ... Workaround: ... if Assigned(FBlobStream.Database) and FBlobStream.Database.CharacterSetCodePage = 0 then ... <<<<<<<<<<<<<<<<<<<<<<<<

QC #: 80414 - Status: Closed

QC #: Project Date Reported: Area: 80414 Delphi 12/16/2009 Compiler\Delphi\RTTI Description Steps:REGRESSION FROM D2010 Update 1 Compile and run the attached application below.

RTTI Failure with Update 4/5 - Invalid Type Cast using RTTI functions. Note that in the test case, the test procedures are almost identical, but calling the second fails with an invalid type cast error at runtime. QC Entry 80414

See the following output indicating failure. FAIL - Exception Error ClassName=EInvalidCast Message=Invalid class typecast program BTS274066; { RTTI Failure with Update 4/5 - Invalid Type Cast } {$APPTYPE CONSOLE} uses SysUtils, uBTS274066a, uBTS274066b; begin try uBTS274066a.DoTest; uBTS274066b.DoTest; WriteLn('PASS'); except on E: Exception do begin WriteLn('FAIL - Exception Error'); WriteLn(' ClassName=', E.ClassName); WriteLn(' Message=', E.Message); end; end; end. unit uBTS274066a; interface uses TypInfo, Classes, RTTI, SysUtils,Generics.Collections; procedure DoTest; implementation procedure DoTest; var L : TList<Integer>; C : TRttiContext; T : TRttiType; LV : TValue; lEnumMethod : TRttiMethod; lEnumerator : TValue; lEnumType : TRttiType; lMoveNextMethod : TRttiMethod; lCurrentProp : TRttiProperty; begin L := TList<Integer>.Create; try L.Add(1); L.Add(2); C := TRttiContext.Create; LV := L; T := C.GetType(LV.TypeInfo); lEnumMethod := T.GetMethod('GetEnumerator'); lEnumerator := lEnumMethod.Invoke(LV,[]); finally

L.Free; end; end; end. unit uBTS274066b; interface uses TypInfo, Classes, RTTI, SysUtils,Generics.Collections; procedure DoTest; implementation procedure DoTest; var L : TList<Integer>; C : TRttiContext; T : TRttiType; LV : TValue; lEnumMethod : TRttiMethod; lEnumerator : TValue; lEnumType : TRttiType; lMoveNextMethod : TRttiMethod; lCurrentProp : TRttiProperty; begin L := TList<Integer>.Create; try L.Add(1); L.Add(2); C := TRttiContext.Create; LV := L; T := C.GetType(LV.TypeInfo); lEnumMethod := T.GetMethod('GetEnumerator'); lEnumerator := lEnumMethod.Invoke(LV,[]); finally L.Free; end; end; end.

QC #: 80421 - Status: Closed

QC #: Project Date Reported: Area: 80421 C++Builder 12/16/2009 IDE Description Steps:[QC Short Description] Precompiled header wizard access violation with *.CPP files [QC Description] While running the precompiled header wizard analysis, if a file is encountered with a capitalized file extension (file1.CPP) then the analysis stops, reporting this error: Access violation at address 0628FA8A in module 'optpchwizard120.bpl'. Read of address 00000004 QC Entry 80421

Create a new console application. Save the project. Name the cpp file "file1.CPP". Run the PCH wizard.

QC #: 80442 - Status: Closed

QC #: Project Date Reported: Area:80442 Delphi 12/17/2009 IDE\Code Editor\Error Insight Description Steps:[QC Short Description] HelpInsight stops working after line 32767 [QC Description] HelpInsight doesn't work if the code line if below the line 32767. QC Entry 80442

1. Open Windows.pas 2. Goto line 32767 3. Move the mouse over a symbol 4. Error Insight pops up 5. Move the mouse over a symbol in the next line (32768) Expected: Error Insight pops up Actual: The compiler hint window pops up

QC #: 80443 - Status: Closed

QC #: Project Date Reported: Area: 80443 Delphi 12/17/2009 Midas\TClientDataSet Description Steps:[QC Short Description] AV in ClientDataSet with Count(*) aggregates [QC Description] A ClientDataSet with aggregate or aggregate field with expression containing "Count(*)" throws AV on open. QC Entry 80443 Added by Sysop <<<<<<<<<<<<< I have the same problem. It fail with version 14.0.3593.25826. It work with version 14.0.3513.24210 >>>>>>>>>>>>> stack= :7d4e237e kernel32.RaiseException + 0x4e :00405f00 NotifyNonDelphiException + $1C :7d61ec1b ntdll32.RtlRaiseStatus + 0xb1 :7d61ea56 ntdll32.KiUserExceptionDispatcher + 0xe :4DAECBD7 QCanExpr::CompileCanEx(this=:0251F460, pcanNode=:02141D32, bNullCheckOrLike=0) :4DAEC1EE QCanExpr::BuildExecStream(this=:0251F460, pCanExprArg=:02141D28) :4DAECF7D QAggregate::Prepare(this=:0251F460, pExpr=NULL, pCan=:02141D28, pDs=:024B90F0) :4DAF4D86 AGGS::InitAgg(this=:02510E00, pDs=:024B90F0, iCanLen=31, pCanExpr=:02141D28, iInitialSize=0) :4DAF53FC AGGSMNG::Add(this=:0254A8E8, iCanLen=31, pCanExpr=:02141D28, piAggId=:0207F5FC) :4DAF5A7E IDXGROUPING::AddAggs(this=:0000001F, iCanLen=39161152, pCanExpr=:02141D28, phAgg=:0207F5FC) :4DAF61D4 IDXGROUPINGMNG::AddAggs(this=:02558D40, iFields=0, iCanLen=31, pCanExpr=:02141D28, phAgg=:0207F5FC):4DAEEFAA DSCursor::AddAggregate(this=:024C04C0, iFlds=1243484, iCanLen=31, pCanExpr=:02141D28, phAgg=:0207F5FC) DBClient.TAggregate.Activate DBClient.TCustomClientDataSet.ResetAgg($207F5A0,True) DBClient.TAggregate.SetActive(True) Unit1.ShowAggrValue('*') Unit1.TForm1.Button2Click($209C340) Controls.TControl.Click StdCtrls.TCustomButton.Click StdCtrls.TCustomButton.CNCommand((48401, 5376, 0, 14947584, 0)) Controls.TControl.WndProc((48401, 5376, 14947584, 0, 5376, 0,

TDBXFulcrumBugsSuite.Native.DB.Test.exe connection=ibconnection -s:TestRaid_274166 -OR- Create a form with two buttons and use the following code: procedure TForm1.ShowAggrValue(const AFieldName: string); var cds: TClientDataSet; aggr: TAggregate; begin cds:= TClientDataSet.Create(Self); try cds.FieldDefs.Add('CODE', ftInteger); cds.FieldDefs.Add('NAME', ftString, 20); cds.CreateDataSet; cds.AppendRecord([1, 'John']); cds.AppendRecord([2, 'Michael']); cds.AppendRecord([3, 'Nick']); aggr:= cds.Aggregates.Add; try aggr.Expression:= Format('Count(%s)', [AFieldName]); aggr.Active:= True; ShowMessage(FormatFloat(',0', aggr.Value)); finally FreeAndNil(aggr); end; { try } finally FreeAndNil(cds); end; end; procedure TForm1.Button1Click(Sender: TObject); begin ShowAggrValue('CODE'); end; procedure TForm1.Button2Click(Sender: TObject); begin ShowAggrValue('*'); end;

5376, 228, 0, 0)) Controls.TWinControl.WndProc((48401, 5376, 14947584, 0, 5376, 0, 5376, 228, 0, 0)) StdCtrls.TButtonControl.WndProc((48401, 5376, 14947584, 0, 5376, 0, 5376, 228, 0, 0)) Controls.TControl.Perform(48401,5376,14947584) Controls.DoControlMsg(14947584,(no value)) Controls.TWinControl.WMCommand((273, 5376, 0, 14947584, 0)) Forms

QC #: 80448 - Status: Closed

QC #: Project Date Reported: Area: 80448 Delphi 12/17/2009 RTL\Delphi\WinAPI Description Steps:[QC Short Description] Wrong declaration of GetProcessId API in Windows.pas unit [QC Description] There is a problem in the case (upper/lower) of the declaration of the API GetProcessId in the Windows.pas unit : function GetProcessID; external kernel32 name 'GetProcessID'; should be : function GetProcessId; external kernel32 name 'GetProcessId'; If you use this API the program lose the compatibility with Windows 2000. Added by Sysop <<<<<<<<<<<<< [MSDN - GetProcessId Function] http://msdn.microsoft.com/en-us/library/ms683215(VS.85).aspx >>>>>>>>>>>>> QC Entry 80448

Try to use the API in a simple project and you get the error.

QC #: 80449 - Status: Closed

QC #: Project Date Reported: Area:80449 Delphi 12/17/2009 IDE\Code Editor\Help Insight Description Steps:[QC Short Description] HelpInsight does not html-escape string constants [QC Description] HelpInsight does not escape html tags in constant strings. QC Entry 80449

1. Create a new Delphi console application 2. Insert the following constant: const MyText = '<a href="http://www.google.com">Click me</a>'#0; 3. Move the mouse over the "MyText" constant Expected: HelpInsight shows the constant Actual: HelpInsight shows a "Click me" link that will navigate to google.com

QC #: 80451 - Status: Closed

QC #: Project Date Reported: Area: 80451 Delphi 12/17/2009 Compiler\Delphi\Generics Description Steps:[QC Short Description] Compile the attached program below with the following command-

F2084 : internal error DBG878 when compiling with standalone debug information. [QC Description] Description : the linker can fail with internal error DBG878 if standalone debug info is activated. To reproduce, take the following unit and call bug() from the main program. This bug is marqued critical as it already took me 2 days to reduce to this small reproducible case, and I still cannot compile my full project due to insuficient (read NO) information from the linker about the places impacted by this bug. ---------------------------------------------- QC Entry 80451

line. dcc32 -b -v BTS274108; See the following compile-time error indicating failure. Fatal: F2084 Internal Error: DBG897 program BTS274108; {$APPTYPE CONSOLE} uses SysUtils, uBTS274108; begin try Bug; WriteLn('PASS'); except on E: Exception do begin Writeln('FAIL - Exception Error'); WriteLn(' ClassName=', E.ClassName); WriteLn(' Message=', E.Message); end; end; end. unit uBTS274108; interface procedure bug; implementation procedure bughelper (var AArg : TArray<Integer>); begin end; procedure bug (); var LArg : TArray<Integer>; begin bughelper(LArg); end; end.

QC #: 80455 - Status: Closed

QC #: Project Date Reported: Area:80455 Delphi 12/17/2009 IDE\Code Editor\Error Insight Description Steps:[QC Short Description] Const declaration with SizeOf referencing itself causes false positive [QC Description] A const declaration with SizeOf referencing itself instead of the type, causes a false positive. QC Entry 80455

1. Create a new console application 2. Copy the following code into the *.dpr file Expetced: No error insight message Actual: "Undeclared identifier "MyConst" at line 10 (10:18)" program TestApp; type TTest = record Size: Integer; end; const MyConst: TTest = ( Size: SizeOf(MyConst); // <<< here ); begin end.

QC #: 80458 - Status: Closed

QC #: Project Date Reported: Area:80458 Delphi 12/17/2009 IDE\Code Editor\Error Insight Description Steps:[QC Short Description] Class helpers with type aliases don't work [QC Description] Using a class helper for an alias type does not work. The helper methods aren't available (for Error Insight). The compiler has no problem with this. QC Entry 80458

1. Create a new console application 2. Copy the following code into the *.dpr file Expected: No Error Insight message Actual: "SetProduct" is reported as unknown. program Project1; type TBase = class procedure Test; end; TAlias = TBase; TAliasHelper = class helper for TAlias function SetProduct: Boolean; end; procedure TBase.Test; begin SetProduct; end; function TAliasHelper.SetProduct: Boolean; begin Result := False; end; begin end.

QC #: 80473 - Status: Closed

QC #: Project Date Reported: Area:80473 Delphi 12/18/2009 VCL\Additional Controls\TSplitter

Description Steps:[QC Short Description] TSplitter issue [QC Description] Impossible to move the splitter to the bottom if top control not visible Added by Sysop <<<<<<< Please see attached sample project for more detail. >>>>>>> QC Entry 80473

Create new project (VCL Forms Apllication) on Delphi 2010 Add Panel1 on form Set Align = alTop Add Panel2 on form Set Align = alTop Set Visible = False Add Panel3 on form Set Align = alClient Add Splitter on form Set Align = alTop Move splitter at the bottom Result: impossible to move the splitter to the bottom

QC #: 80478 - Status: Closed

QC #: Project Date Reported: Area:80478 Delphi 12/18/2009 IDE\Code Editor\Error Insight Description Steps:[QC Short Description] Overload resolution doesn't work with open array parameters [QC Description] ErrorInsight's overload resolution doesn't work with open array parameters. It always takes the first method instead of the correct one.QC Entry 80478

1. Create a new console application 2. Copy the following code into the *.dpr file Expected: No Error Insight message Actual: "Expression must be BOOLEAN" program Project1; type TTest = class public function Func(const Texts: array of string; Values: array of Integer): Integer; overload; function Func(const Texts: array of string): Boolean; overload; procedure Test; end; procedure TTest.Test; begin if Func(['Foo', 'Bar']) then ; // << "Expression must be BOOLEAN" end; function TTest.Func(const Texts: array of string; Values: array of Integer): Integer; begin Result := 0; end; function TTest.Func(const Texts: array of string): Boolean; begin Result := False; end; begin end.

QC #: 80485 - Status: Closed

QC #: Project Date Reported: Area:80485 Delphi 12/18/2009 IDE\Code Editor\Error Insight Description Steps:[QC Short Description] Call-type between ")" and "of object" causes false positive [QC Description]

1. Create a new console application 2. Copy the following code into the *.dpr file Expected: No Error Insight message Actual: "Expected BEGIN but received OF at line 4 (4:46)" program Project1; type TProcTest = procedure(Obj: TObject) pascal of object; begin end.

Error Insight shows a false positive if the procedure call type is specified between ")" and "of object". QC Entry 80485

QC #: 80487 - Status: Closed

QC #: Project Date Reported: Area: 80487 Delphi 12/18/2009 VCL\Docking Description Steps:[QC Short Description] TDockCaptionDrawer.FDockCaptionOrientation is inaccessible to derived classes [QC Description] The orientation of a dock zone is a vital property for a class derived from TDockCaptionDrawer. Unfortunately, even though TDockCaptionDrawer does store the orientation internally, it does not make it accesible to derived classes, forcing them to duplicate data by storing the orientation value again. Make TDockCaptionDrawer.FDockCaptionOrientation accessible to derived classes with either a protected or a public property. QC Entry 80487

QC #: 80496 - Status: Closed

QC #: Project Date Reported: Area:80496 Delphi 12/18/2009 IDE\Code Editor\Error Insight Description Steps:[QC Short Description] "'foo..inc' could not be found in the current project" with {$I *.inc} [QC Description] Using {$I *.inc} leads to a "'foo..inc' could not be found in the current project" error. -> see steps QC Entry 80496

- save the attached two files or use the following two files here - start Delphi - open EIAsteriskIncludeTest.dpr expected: no Error Insight errors in the Structure view and the editor actual: '<path>\EIAsteriskIncludeTest..inc' could not be found in the current project at line 5 (5:1) Expected BEGIN but received an identifier 'TBar' at line 6 (6:3) //--- EIAsteriskIncludeTest.dpr --- program EIAsteriskIncludeTest; {$APPTYPE CONSOLE} {$I *.inc} TBar = class(TFoo); begin end. //--- EIAsteriskIncludeTest.inc --- type TFoo = class(TObject);

QC #: 80533 - Status: Closed

QC #: Project Date Reported: Area: 80533 Delphi 12/20/2009 Compiler\Delphi\RTTI Description Steps:[AMP] [QC Short Description] F2084 error with large structure initialization [QC Description] By USc: This is regression from D2009 due enhanced RTTI. Original description: When attempting to initialize a constant data structure with more than 2728 string elements, the compiler fails with [DCC Fatal Error] F2084 Internal Error: L3302. The compiler only fails if the structure is initialized as a const. Simply declaring the structure type without initialiation does not cause the failure. This failure is new in Delphi

Steps by USc: - save the attached file L3302.dpr - dcc32 L3302.dpr expected: it compiles actual: Fatal: F2084 Internal Error: L3302 (Internal note by USc: with Fulcrum Beta 2 the error is L4047) Additional notes: - the error goes away when disabling enhanced RTTI for fields ( {$RTTI EXPLICIT FIELDS([])} ) - the error goes away when removing the last record item "str2425: string;"

2010 - it did not occur in either D2006 or D2009. QC Entry 80533

- the error goes away when removing the const "FooConst" - the actual amount of elements depends on the length of their names Original Steps: Create a project with a large structure definition and attempt to declare constants. Example: unit CTConst; interface type vstruct = record za00 : string; za01 : string; za02 : string; za03 : string; // za01..zz99 // wa00..wb30 wb28 : string; wb29 : string; wb30 : string; end; const aconst : vstruct = (za01 : 'abcd'; za02 : 'wxyz'); implementation end. This unit causes the reported failure. Comment out lines wb29 and wb30 in the type definition and the compiler reports success

QC #: 80539 - Status: Closed

QC #: Project Date Reported: Area:80539 Delphi 12/21/2009 Compiler\Delphi\Other Compiler

Description Steps:[QC Short Description] --doc generate XML Documentation and XML (Delphi 2009) [QC Description] When generating XML documentation from Delphi 2009, the following code generates invalid XML .. TArrayUtils = class public ///<summary> /// A generic Min function ///</summary> ///<remarks> /// Finds and returns the smallest element of an array ///</remarks> class function Min<T>(const Items: array of T; const Comparer: IComparer<T>): T; overload; static; ///<summary> /// A generic Min function (Overloaded for TComparison) ///</summary> ///<seealso cref="T:Generics.Defaults.TComparison">TComparison</seealso> class function Min<T>(const Items: array of T; const Comparison: TComparison<T>): T; overload; static; class function Min<T: IComparable<T>>( const Items: array of T): T; overload; static; end; This looks like valid code to me, but the XML file generated is invalid.

Create project, then add above code to unit. Select Generate XML documentation. Try and load XML document in browser, or via C# XMLDocument.

<function name="Min" visibility="public" procflags="overload"> <devnotes> <summary> A generic Min function </summary> <remarks> Finds and returns the smallest element of an array </remarks> </devnotes> <parameters> <parameter name="Items" paramflags="const"> <array name="Items"> <element type="T" /> </array> </parameter> <parameter name="Comparer" type="IComparer<TArrayUtils.Min.T>" paramflags="const" /> <retval type="T" /> </parameters> </function> The 'parameter name="Comparer"' line is the problem here. QC Entry 80539

QC #: 80586 - Status: Closed

QC #: Project Date Reported: Area: 80586 Delphi 12/22/2009 Install Description Steps:[QC Short Description] Cannot install Update 4 without Update 5 (Delphi 2010) [QC Description] Added by Sysop <<<<<<<<<<<<<<<<<<<<<<<<<<<< > If I run Delphi 2010 as administrator, this message goes away and an > "Updates available" window appears. Yes, this is expected behavior. But, ... > Which is odd, because during setup I unchecked "Check for updates automatically". Yes, this is already known issue after applying Update4,5... Sorry for inconvenience. >>>>>>>>>>>>>>>>>>>>>>>>>>>> Since we don't use Delphi for database access, I only wanted to install Update 4. After doing a "Check for updates" and unchecking Update 5, update 4 seemed to install (although it didn't show as an update in the About dialog box). However, every time I start Delphi 2010 now, I get the error message: Error executing ?:\ProgramData\{BBD31133-40F8-4B57-9BA6-DB76C03D153B}\Setup.exe· The window does not have scroll bars (On 64-bit Windows 7) Also, when shutting down Delphi 2010 now, Windows comes up with an abnormal program termination error. That last error went away after I installed update 5, but I didn't want to do that. Please make your updates so they don't require database updates if you don't need them. You can disable database functionality in the regular Delphi 2010 setup, so updates shouldn't force them back on again. (The same goes for other features you have disabled in the regular Delphi 2010 setup). QC Entry 80586

QC #: 80587 - Status: Closed

QC #: Project Date Reported: Area: 80587 Delphi 12/22/2009 Install Description Steps:[QC Short Description] .PAS file association stopped working after Update 4/5 for Delphi 2010 [QC Description] After installing Update 4/5 for Delphi 2010 (on 64-bit Windows 7), double clicking a .PAS file in Explorer doesn't open the file in the Delphi IDE anymore. Each time I double click a .PAS file, a new instance of BDSLauncher.exe gets executed, but does not succeed. And after a while I end up with a lot of BDSLauncher.exe instances running that I need to kill manually. Added by Sysop <<<<<<<<<<<<< 32-bit Windows 7 is same. >>>>>>>>>>>>> QC Entry 80587

1. Install update 4/5 for Delphi 2010 2. Double-click a .PAS file in Explorer (or a version control system)

QC #: 80600 - Status: Closed

QC #: Project Date Reported: Area:80600 Delphi 12/22/2009 IDE\Dialogs\Project Options Description Steps:[QC Short Description] Version Info in DLL is inconsistent [QC Description] The Project options page has an option to include versioninfo in a DLL. These do not work if a library suffix is included. Is this by design (if so why?) or an error ? QC Entry 80600

To Reproduce. 1. Start a new DLL project 2. Click Projects|Options, select the VersionInfo node and check the "Include vesrion information in project". Click OK to close the dialog. 3. Compile the dll 4. Browse to the dll and check the properties, version info should be included 5. Reopen the project options dialog, select the Application node and enter a string in the "LIB_Suffix" field e.g. "_lib" 6. Switch back to the VersionInfo node. Notice the checkbox is greyed out BUT you can still enter/change info in the fields underneath. Change the version number. 7. Recompile the dll. 8. Browse to the dll (which will now have a "_lib.dll" ending) and check the properties, version info is included but has not been updated. Another sequence of steps to follow is similar to above but adding the library suffix first (clicking OK to save the change) and the try to add VersionInfo. The "Include vesrion information in project" checkbox is now greyed out and cannot be selected.

QC #: 80620 - Status: Closed

QC #: Project Date Reported: Area:80620 Delphi 12/23/2009 IDE\Code Editor\Error Insight Description Steps:[QC Short Description] False Positive: Variant records with procedure types [QC Description] Error Insight shows a false positive if a record has a variant block (case-of) and in that block is a field that has a procedure type. QC Entry 80620

1. Create a new console application 2. Copy the following code into the *.dpr file Expected: No Error Insight message Actual:

";" expected but ")" found program EI_RecCaseProc; type TMyType = record case Integer of 0: (Proc: procedure); // 1: (Proc2: function: Integer); // 2: (Proc3: procedure(Param: string) of object); end; begin end.

QC #: 80623 - Status: Closed

QC #: Project Date Reported: Area:80623 Delphi 12/23/2009 IDE\Code Editor\Error Insight Description Steps:[QC Short Description] Generic Methods from used-units are not found [QC Description] Error Insight reports generic methods like TArray.BinarySearch<T> as not existing. QC Entry 80623

1. Create a new console application 2. Copy the following code into the *.dpr file Expected: No Error Insight message Actual: 'TArray' doesn't contain a member called 'BinarySearch' program CompGenMethod; uses Generics.Collections; var FoundIndex: Integer; begin TArray.BinarySearch<string>(['A', 'B'], 'A', FoundIndex); end.

QC #: 80630 - Status: Closed

QC #: Project Date Reported: Area: 80630 C++Builder 12/24/2009 RTL\C++\Miscellaneous Description Steps:[QC Short Description] wcsncat not working [QC Description] wcsncat seems to have a bug Added by Sysop <<<<<<<<<<<<<<< Please see this thread for more information and fixed .asm code. https://forums.codegear.com/thread.jspa?threadID=30323&tstart=0 >>>>>>>>>>>>>>> QC Entry 80630

int _tmain(int argc, _TCHAR* argv[]) { wchar_t t[] = L"abcdefghijklmnopqrstuvwxyzabc"; wchar_t s[36]; s[0] = L'\0'; ::wcsncat (s, t, 35) ; if (::wcscmp (s, t) != 0) { printf ("error\n"); } return 0; }

QC #: 80691 - Status: Closed

QC #: Project Date Reported: Area: 80691 Delphi 12/28/2009 RTL\Delphi\WinAPI Description Steps:[QC Short Description] Wrong function declaration QueueUserAPC [QC Description] Function QueueUserAPC declared in windows.pas as:

function QueueUserAPC(pfnAPC: TFNAPCProc; hThread: THandle; dwData: DWORD): BOOL; The problem is a type of parameter dwData. It must be declared as PDWORD or Pointer. Added By Sysop <<<<<<<<<<< [QueueUserAPC Function] http://msdn.microsoft.com/en-us/library/ms684954(VS.85).aspx [C++] DWORD WINAPI QueueUserAPC( __in PAPCFUNC pfnAPC, __in HANDLE hThread, __in ULONG_PTR dwData ); >>>>>>>>>>> QC Entry 80691

QC #: 80751 - Status: Closed

QC #: Project Date Reported: Area:80751 Delphi 12/31/2009 VCL\System Controls\TMediaPlayer

Description Steps:[QC Short Description] TMediaPlayer has no align property [QC Description] TMediaPlayer lacks a align property although one can resize it and set its anchors as desired. So simply this property is missing. QC Entry 80751

1. create a empty VCL app 2. drop a TMediaPlayer from the System category onto it 3. look for the align property in object inspector 4. find out one can resize it 5. find the anchors property in object inspector So it seems the needed basics for align are there but not align itsself.

QC #: 80752 - Status: Closed

QC #: Project Date Reported: Area:80752 Delphi 12/31/2009 Documentation\Online Help\VCL

Description Steps:[QC Short Description] TMediaPlayer.Shareable property not documented [QC Description] The shareable property of TMediaPlayer is not documented (at least in the german version) QC Entry 80752

QC #: 80753 - Status: Closed

QC #: Project Date Reported: Area:80753 Delphi 12/31/2009 Documentation\Online Help\VCL

Description Steps:[QC Short Description] TMediaPlayer Delphi example has no scrollbars and is panned to the right [QC Description] ms-

help://embarcadero.rs2010/codesamples/MediaPlayer_(Delphi).html has no scrollbars and is panned to the right so on my 1024x768 display I cannot see the left side of it. See attached screenshot. QC Entry 80753

QC #: 80754 - Status: Closed

QC #: Project Date Reported: Area:80754 Delphi 12/31/2009 Documentation\Online Help\VCL

Description Steps:[QC Short Description] TMediaPlayer.TrackLength missing [QC Description] The TMediaPlayer.TrackLength docu points to TMediaPlayer itsself: ms-help://embarcadero.rs2010/vcl/MPlayer.TMediaPlayer.html (that is: german edition and called via F1 D2010 from editor) QC Entry 80754

QC #: 80755 - Status: Closed

QC #: Project Date Reported: Area:80755 Delphi 12/31/2009 AddOn\Interbase components Description Steps:[QC Short Description] IBX: Using asString from a text blob field returns gibberish [QC Description] When extracing ANSI data with the asString method of TIBQuery.FieldByName('my_text_blob') from a text blob field, the resultant string is full of squares or question marks. Using DBMemo reproduces the same results. All of the varchar fields are correct. This worked correctly in D2009. QC Entry 80755

In a new project, connect a DBMemo field to a text blob. Run the application to view result.

QC #: 80764 - Status: Closed

QC #: Project Date Reported: Area:80764 Delphi 1/1/2010 IDE\Code Editor\Error Insight Description Steps:[QC Short Description] Result of generic method pointers not resolved correctly [QC Description] The result type of a generic method pointer is not resolved correctly. QC Entry 80764

1. Create a new console application 2. Copy the following code into the *.dpr file Expected: No ErrorInsight messages Actual: 'TFunc<TObject>' does not contain a member named 'Free' at line 7 (7:7) program Project1; type TFunc<T> = {reference to} function: T; var F: TFunc<TObject>; begin F().Free; // << 'TFunc<TObject>' doesn't contain a member 'Free' end.

QC #: 80774 - Status: Closed

QC #: Project Date Reported: Area:80774 Delphi 1/2/2010 IDE\Dialogs\Project Options

Description Steps:[QC Short Description] Compilation fails when "Minimum enum size" is set to "Quad word" in "Project Options" QC Entry 80774

1. Open Delphi Project Options dialog. 2. In "Compiling" section set "Minimum enum size" to "Quad word" 3. Try to compile Compilation will fail with: [DCC Fatal Error] F1030 Invalid compiler directive: '-$Z8'

QC #: 80776 - Status: Closed

QC #: Project Date Reported: Area: 80776 Delphi 1/2/2010 IDE\Object Inspector Description Steps:[QC Short Description] ObjectInspector shows "EditControl" instead of the real content [QC Description] The ObjectInspector in a freshly started IDE shows "EditControl" for the selected property value when you click on the scrollbars. QC Entry 80776

1. Start RAD Studio (if it is already started, then restart it) 2. Create a new VCL Application (File/New/VCL Forms Application) 3. Have a look at the "Action" property (don't do anything, just look): it is empty 4. Now click on the ObjectInspector's vertical scrollbar's "up" button. Expected: Nothing happens because we are already at the top item. Actual: The action property edit control appears and it shows "EditControl"

QC #: 80777 - Status: Closed

QC #: Project Date Reported: Area:80777 Delphi 1/2/2010 Documentation\Online Help Description Steps:[QC Short Description] TBits - inconsistent information [QC Description] The severity of a documentation quirk ??? That all depends on how thoroughly you read the docs.... Anyway, after a discussion in https://forums.embarcadero.com/thread.jspa?threadID=30623&tstart=0 it looks like the TBits docs could use some tidying up In ms-help://embarcadero.rs2010/vcl/Classes.TBits.Bits.html we have{code} Use Bits to read or set a particular Boolean value, as indexed by the Index parameter. If Index is not in the range 0..Size - 1, an EBitsError exception is raised. {code} In ms-help://embarcadero.rs2010/vcl/Classes.TBits.html we have {code}Classes.TBits can store as many of boolean values as can fit in available memory, automatically expanding its storage space as needed{code} If you just read the description of TBits.bits then you will have the impression that accessing TBits[Index] where Index>=Size will cause an exception This is only half true, as writing will extend the storage space without error - only reading past size-1 will cause an exception And it's the other way around if you just read the main description Both pages should be specific that an exception is only raised on reading, and that extending is only done on writing QC Entry 80777

read the docs for tbits and tbits.bits

QC #: 80785 - Status: Closed

QC #: Project Date Reported: Area:80785 Delphi 1/3/2010 Compiler\Delphi\Errors - Warnings

Description Steps:[QC Short Description] Wrong hint for private class destructor [QC Description] Having class destructor in the private visibility like TTest = class(...) private class constructor Create; class destructor Destroy; end; causes compiler hint [DCC Hint] test.pas(130): H2219 Private symbol 'Destroy@' declared but never used The destructor is still called when the app terminates. Moving it to protected visibility fixes it. No such a hint for (private) class constructor. QC Entry 80785

Compile the attached application below. See the following compile-time hint indicating failure. Hint: H2219 Private symbol 'Destroy@' declared but never used program BTS274263; { Wrong hint for private class destructor } {$APPTYPE CONSOLE} type TTest = class(TObject) private class constructor Create; class destructor Destroy; end; class constructor TTest.Create; begin end; class destructor TTest.Destroy; begin WriteLn('PASS'); // PASS when class destructor is called // end; procedure DoTest; { Construct an instance to bring in the type } var TestItem: TTest; begin TestItem := TTest.Create; try finally TestItem.Free; end; end; begin try DoTest; except on E: TObject do begin WriteLn('FAIL - Unexpected Exception'); Writeln(' ClassName=', E.ClassName); end; end; end. {##FAILIFMSG.English: BTS274263.dpr(11) Hint: H2219 Private symbol 'Destroy@' declared but never used}

QC #: 80803 - Status: Closed

QC #: Project Date Reported: Area:80803 Delphi 1/3/2010 IDE\Refactoring\Introduce Variable

Description Steps:[QC Short Description] Refactoring Introduce Variable does not work properly

Create a unit with the following (not so great) code: --- begin of code --- unit Unit3; interface function Hello : integer; implementation function Hello : integer; var a: string; b: string; begin a := 'hello'; b := a

[QC Description] Sometimes the refactoring "Introduce Variable" does not work properly. Selecting a single expression and selecting the refactoring option sometimes does nothing (no error, no pop-up) and sometimes does show the pop-up, but nothing changes after entering the variable name and then pressing OK. QC Entry 80803

+ 'a string'; Result := 0; end; end. --- end of code --- Now select 'a string' including quotes. In the refactor menu select the refactoring option Introduce Variable. In the pop-up enter a name for the variable. Press OK. Nothing happens.

QC #: 80822 - Status: Closed

QC #: Project Date Reported: Area: 80822 Delphi 1/4/2010 IDE\Object Inspector Description Steps:[QC Short Description] Properties are duplicated after scrolling [QC Description] If you click on the last item, that isn't fully visible the ObjectInspector scrolls and then you see the next property twice. QC Entry 80822

1. Create a new VCL Application 2. Resize the ObjectInspector window so it shows the "DoubleBuffered" property only half. 3. Click on the "DoubleBuffered" property Expected: "DoubleBuffered" is now selected Actual: You see two "DragKind" properties and both seem to be selected

QC #: 80884 - Status: Closed

QC #: Project Date Reported: Area: 80884 Delphi 1/6/2010 Compiler\Delphi\Generics Description Steps:[QC Short Description] Yet another way to get URW1111 [QC Description] The attached minimal project fails to compile, emitting the peripatetic URW1111 internal error. The culprit appears to be the call to TObj<A>.create in the anonymous procedure assigned to the local variable p in TObj<A>.new. QC Entry 80884

Original steps: (test case from dir original) Load and attempt to compile the attached project. Note that in the original version of the failing code, the failure mode was 100% CPU consumption and eventual memory exhaustion. It wasn't until I stripped out a lot of otherstuff that I actually got a bona fide error message. Steps by USc: - save the three following files or the attached files from the dir simplified - dcc32 -B urw1111.dpr expected: it compiles actual: uURW1111.pas(8) Fatal: F2084 Internal Error: URW1111 //--- urw1111.dpr --- program urw1111; uses uURW1111; begin WriteLn('PASS'); // on compile end. //--- uURW1111.pas --- unit uURW1111; interface implementation uses uCore; procedure TForm24FormShow; begin TObj<Integer>.New; end; end. //--- uCore.pas --- unit uCore; interface type TPr = reference to procedure; TObj<A> = class public class procedure New; end; implementation class procedure TObj<A>.New; var P: TPr; begin P := procedure begin TObj<A>.Create; end; end; end.

QC #: 80887 - Status: Closed

QC #: Project Date Reported: Area:80887 Delphi 1/6/2010 Documentation\Online Help\VCL

Description Steps:[QC Short Description] Documentation for TGUID is not correct [QC Description] The documentation in the help file for System.TGUID is not correct QC Entry 80887

Go to the help entry for System.TGUID. The following information on the page is not correct (the structure is not right): "Delphi Information From System.pas TGUID = packed D1: Cardinal; D2: Word; D3: Word; end;" This information on the same page is not correct (doesn't add up to 32 hexadecimal digits): "D1 maps to the first 8 hexadecimal digits. D2 maps to the next 4 hexadecimal digits. D3 maps to the next 4 hexadecimal digits. D4 maps to the final 8 hexadecimal digits"

QC #: 80907 - Status: Closed

QC #: Project Date Reported: Area: 80907 Delphi 1/7/2010 Midas\TClientDataSet Description Steps:[QC Short Description] ClientDataset.GetNextPacket fire "Key violation." [QC Description] 1.cdsM have nested data(TDataSetField) 2.call cdsM.RefreshRecord 3.call cdsM.GetNextPacket 4.EDBClient Exception "Key violation." try cdsM.RefreshRecord; cdsM.GetNextPacket; except on e:Exception do ShowMessage(e.ClassName + ' : '+e.Message); end; Added by Sysop <<<<<<<<<<<<<< MS SQL Server 2005 via dbGo(ADO) DB: Northwind This issue is same as QC#47280. http://qc.embarcadero.com/wc/qcmain.aspx?d=47280 >>>>>>>>>>>>>> QC Entry 80907

save and open raid274349fixed.zip run and click button

QC #: 80938 - Status: Closed

QC #: Project Date Reported: Area: 80938 Delphi 1/7/2010 Compiler\Delphi\Generics Description Steps:The compiler fails to recognize generic types used in parameter lists as compatible.

Compile the attached application below and see the following unexpected compiler error indicating failure for the line marked #1 as invoked via the statement on line #2. Note, however, the similar line marked #3 in source is accepted. Error: E2250 There is no overloaded version of 'Create' that can be called with these arguments program BTS274346; { The compiler fails to recognize generic types used in parameter lists as compatible. } {$APPTYPE CONSOLE} uses SysUtils, Generics.Collections; type TMyClass = class end; TMyClassList = TObjectList<TMyClass>; function CreateList(p_SrcList : TMyClassList) : TMyClassList; begin Result:= TMyClassList.Create(p_SrcList); //#1//

// Workaround: Result:= TMyClassList.Create(TList<TMyClass>(p_SrcList)); end; procedure DoTest; var List1, List2 : TMyClassList; begin List2:= TMyClassList.Create; List1:= CreateList(List2); //#2// List1:= TMyClassList.Create(List2); //#3 OK!// WriteLn('PASS'); end; begin try DoTest; except on E: Exception do begin WriteLn('FAIL - Unexpected Exception'); WriteLn(' ClassName=', E.ClassName); WriteLn(' Message=', E.Message); end; end; end.

QC #: 80954 - Status: Closed

QC #: Project Date Reported: Area: 80954 Delphi 1/8/2010 Database\DataSnap\Client Description Steps:[QC Short Description] TSQLConnection Datasnap ConnectTimeout [QC Description] At the datasnap server I set the TSQLConnection driver to datasnap and the ConnectTimeout to 5000. The connecTimeout property value is never set to the underlying TIdTCPClientCustom IOHandler. https://forums.codegear.com/message.jspa?messageID=199490#199490 Added by Sysop <<<<<<<<<<<<<<< https://forums.embarcadero.com/thread.jspa?threadID=30868&tstart=0>>>>>>>>>>>>>>> QC Entry 80954

x

QC #: 80974 - Status: Closed

QC #: Project Date Reported: Area:80974 Delphi 1/8/2010 Debugger\Local Variables View

Description Steps:[QC Short Description] DateTime evaluator doesn't work properly in Local Variables view [QC Description] It appears that a line, in the Local Variables view, that once has displayed a DateTime value (at least if it is 0.0) gets 'sticky', and when

New VCL application with a button and a memo. In project options select: Build configuration - Debug Optimization - False Use debug .dcus - True In the buttons onclick write the following and build. Then set a breakpoint at the begin and press F9 to run. procedure TForm1.Button1Click(Sender: TObject); var dt: TDateTime; bb: boolean; begin // Breakpoint here bb := TryStrToDate('5.9.2009',dt);

tracing in to subroutines the DateTime presentation remains on that line, even if the variable that should be on the line changes in type and value. If the Local Variables view is turned off and on, the correct representation of the current variable is shown. QC Entry 80974

Memo1.Lines.Add(BoolToStr(bb,true)); Memo1.Lines.Add(FormatDateTime('d-mmm-yyyy',dt)); end; Press F8 once so the 'begin' is executed and look at the Local variables: Name Value Self ($BACE10, 'Form1', 0, $BC2... Sender () dt 30.12.1899 bb False It looks as expected, dt has a value of 0.0 therefore the base date is shown. Press F7 to trace into 'TryStrToDate' and press F8 once to execute the 'begin' function TryStrToDate(const S: string; out Value: TDateTime): Boolean; var Pos: Integer; begin Pos := 1; // execution pointer here Result := ScanDate(S, Pos, Value) and (Pos > Length(S)); end; Local variables show: Name Value S '5.9.2009' Value 30.12.1899 Result 30.12.1899 Pos 13 Value is as expected, but Result is shown as it would be a DateTime variable, allthough it is a boolean Press F8 once to execute the Pos := 1 statement and F7 to trace into ScanDate and then a few times F8 to the line: if not (ScanNumber(S, Pos, N1, L1) and ... {code:delphi} function ScanDate(const S: string; var Pos: Integer; var Date: TDateTime): Boolean; overload; var DateOrder: TDateOrder; N1, N2, N3, Y, M, D: Word; L1, L2, L3, YearLen: Byte; ... begin Y := 0; ... if not (ScanNumber(S, Pos, N1, L1) and ... Local variables shows: Name Value S '5.9.2009' Pos 30.12.1899 Date 30.12.1899 Result False DateOrder doDMY ... Pos is not as expected. Now, press F7 to trace into ScanNumber, and a few times F8 until the line ScanBlanks(S, Pos); function ScanNumber(const S: string; var Pos: Integer; var Number: Word; var CharCount: Byte): Boolean; var I: Integer; N: Word; begin Result := False; CharCount := 0; ScanBlanks(S, Pos); // execution pointer here Local variables show: Name Value S '5.9.2009' Pos 30.12.1899 Number 30.12.1899 CharCount 0 Result False ... Pos and Number are shown as if they were DateTimes allthough they are not.

QC #: 80998 - Status: Closed

QC #: Project Date Reported: Area: 80998 Delphi 1/8/2010 SOAP\WSDL Importer Description Steps:[QC Short Description] Automated Incident Report [QC Description] ''nflop.cfcSoapBinding'' is not a valid component name. Using WSDL wizard to create connector QC Entry 80998

<wsdl:definitions targetNamespace="http://cfcs"> <!--WSDL created by ColdFusion version 8,0,1,195765--> <wsdl:portType name="Nflop"> </wsdl:portType> - <wsdl:binding name="nflop.cfcSoapBinding" type="impl:Nflop"> <wsdlsoap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/> </wsdl:binding> - This is the service - it won't import because it doesn't like the 'nflop.cfcSoapBinding' name. Having said that - there's no way for me to change the name of the port binding. Any assistance in this matter would be most appreciated! <wsdl:service name="NFL Office Pool"> <wsdl:documentation> I perform multiple NFL Office Pool </wsdl:documentation> - <wsdl:port binding="impl:nflop.cfcSoapBinding" name="nflop.cfc"> <wsdlsoap:address location="http://www.dolphinsafe.net/cfcs/nflop.cfc"/> </wsdl:port> </wsdl:service> </wsdl:definitions>

QC #: 81064 - Status: Closed

QC #: Project Date Reported: Area: 81064 Delphi 1/11/2010 IDE\Search\Find Description Steps:[QC Short Description] [DE] Pick letter for "Groß-/Kleinschreibung" ("Case sensitive") in Search bar [QC Description] I tried to toggle the "Groß-/Kleinschreibung" (US: "Case sensitive")

- start the DE IDE version - make the editor visible (for exam. create a new console app) - press CTRL+F - press ALT + the pick letter for "Groß-/Kleinschreibung" (US: "Case sensitive") which is currently G -> ALT+G expected: the checkstate of "Groß-/Kleinschreibung" (US: "Case sensitive") would change actual: the checkstate of "Groß-/Kleinschreibung" (US: "Case sensitive") remains unchanged

checkbox in the Search bar with the keyboard, but that didn't work. The pick letter for "Case sensitive" is G in the DE version and it doesn't work because ALT + G is also used by "Search" | "Go to Line Number...". The pick letter for "Case sensitive" in the DE version should be changed. -> see steps and attached image QC Entry 81064

QC #: 81071 - Status: Closed

QC #: Project Date Reported: Area: 81071 Delphi 1/11/2010 Debugger\Inspector Description Steps:Currently, in order to invoke an external viewer visualizer from the debug inspector, you need to use the local menu. It would be better if the behavior matched the UI in the Locals, Watch, and Eval Tooltip Views -- clicking the glyph either shows the visualizer or provides a menu showing the available visualizers. [QC Short Description] Visualizer Glyph in Debug Inspector does not show the visualizer [QC Description] The visualizer glyph in the Debug Inspector does not show the visualizer. -> see steps QC Entry 81071

- save the code at the end of the steps as DebugInspectorVisualizerTest.dpr - start Delphi - open DebugInspectorVisualizerTest.dpr - put a breakpoint on line 39 ("FQ.Free;") - run - place the cursor on FQ in line 39 and press CTRL+F7 - press the Inspect button (now you should see the Debug Inspector and FSQL on it's Data page with the visualizer glyph) - press with the left mouse button on the visualizer glyph expected: the TStrings visualizer will be shown actual: nothing happens (double click opens the Debug Inspector for FQ.FSQL) program DebugInspectorVisualizerTest; {$APPTYPE CONSOLE} uses Classes; type TFooQuery = class(TObject) private FSQL: TStringList; public constructor Create; destructor Destroy; override; property SQL: TStringList read FSQL; end; { TFooQuery } constructor TFooQuery.Create; begin inherited Create; FSQL := TStringList.Create; end; destructor TFooQuery.Destroy; begin FSQL.Free; inherited Destroy; end; var FQ: TFooQuery; begin FQ := TFooQuery.Create; try FQ.SQL.Add('SELECT * FROM BAR'); finally FQ.Free;//<- ADD A BREAKPOINT HERE -> Run -> cursor on FQ -> CTRL+F7 -> Inspect end; end.

QC #: 81109 - Status: Closed

QC #: Project Date Reported: Area:81109 Delphi 1/12/2010 Database\Database Tools\SQL Builder

Description Steps:French & German UI can't use "Query Builder" from TQuery component. Also Japanese translation is missing. [QC Short Description] Rapport d'incident automatisé [QC Description] Violation d'accès à l'adresse 00000000. Lecture de l'adresse 00000000. click bouton droit sur un TQuery , selection de l'option constructeur SQL QC Entry 81109 Note: File delivery request: #279095

Select French or German UI (BDSSETLANG.exe DE) Exec. IDE, create new VCL app, drop TQuery, select "Query builder" from TQuery's popup menu. EXp: Query Builder is launced. ACt: AV.

QC #: 81118 - Status: Closed

QC #: Project Date Reported: Area: 81118 Delphi 1/12/2010 Debugger\Debugger UI Description Steps:[QC Short Description] TStrings visualizer goes into edit mode [QC Description] The TStrings visualizer goes into edit mode by clicking into the first column. The ReadOnly property of the TListView needs to be True. -> see steps and attached image QC Entry 81118

- save the file at the end of the steps as AnotherStringsVisualizerTest.dpr - start Delphi - open AnotherStringsVisualizerTest.dpr - put a breakpoint on "SL.Free" in line 17 - run - invoke the TStrings visualizer - click into the first column to focus it - click again after some seconds expected: nothing happens actual: the first column is in edit mode (see attached image) program AnotherStringsVisualizerTest; {$APPTYPE CONSOLE} uses Classes; var SL: TStringList; begin SL := TStringList.Create; try SL.Add('Just'); SL.Add('some'); SL.Add('text'); finally SL.Free;//put a breakpoint here and invoke the visualizer end; end.

QC #: 81185 - Status: Closed

QC #: Project Date Reported: Area: 81185 Delphi 1/14/2010 IDE\Code Editor Description Steps:[QC Short Description] IDE should use AddFontMemResourceEx to load "Editor Line Endings" font [QC Description] The IDE should use the AddFontMemResourceEx API instead of the AddFontResource/AddFontResourceEx API to load the EDITORFONT resource containing the "Editor Line Endings" font. The "Editor Line Endings" font is used when the "Show line breaks" option is enabled. The advantage of AddFontMemResourceEx is that it doesn't need a temporary file, the font is private (i.e. not visible to other processes) and it is not enumerable (i.e. will not appear in the IDE's font lists). See also: QC46156, QC33312 and QC44455. QC Entry 81185

QC #: 81234 - Status: Closed

QC #: Project Date Reported: Area:81234 Delphi 1/16/2010 IDE\Code Editor\Formatting Description Steps:[QC Short Description] Wrong formatting [QC Description] The code shown in the description will be formatted bad no matter what the options are. Please fix ASAP, formatter broke units of thousands of lines. QC Entry 81234

1. add the following code to an empty method (for example dblclick on a form and add the code below to FormCreate): try except on E: Exception do begin end; else raise ; end; 2. format the code expected: the end closing the block try-except-end should be left aligned with the keywords try/except actual: you get this try except on E: Exception do begin end; else raise ; end; and it's becoming a nightmare when formatting a whole unit.

QC #: 81243 - Status: Closed

QC #: Project Date Reported: Area: 81243 Delphi 1/17/2010 Database\DataSnap

Description Steps:[QC Short Description] CGI based DataSnap server does not work on IIS [QC Description] CGI based DataSnap server does not work on IIS. Both client application and DataExplorer fail to connect to the CGI datasnap server via TSQLConnection. Session Expiration Error message box is shown... My environemnt is Windows 7 and IIS 7.5 QC Entry 81243

My environemnt is Windows 7 and IIS 7.5 1. create CGI based DataSnap server 2. deploy it to IIS 3-1. try to connect to it via DataExplorer or 3-2 create client application, and try to connect to it via TSQLConnection. Of course, DSHTTPLayer unit and other units have beed added in order to load HTTP transport modules. 4. Session Expiration Error message box is shown...

QC #: 81256 - Status: Closed

QC #: Project Date Reported: Area:81256 Delphi 1/18/2010 VCL\System Controls\TTimer Description Steps:[QC Short Description] Changing TTimer.Enabled from thread does not work anymore since Update 4 for Delphi 2010 [QC Description] Added by Sysop <<<<<<< This issue is due to side effect of Internal Tracking Number #201805>>>>>>> Prior to update 4/5 of Delphi 2010, you used to be able the change the Enabled property of a TTimer from different threads. This was possible because the window handle for the timer was eagerly created during the TTimer constructor. Since update 4, changing the Enabled property from a different thread doesn't work anymore. Probably, because the window handled is recreated when you do this. We write software that is highly multi-threaded and we also use different timers on occasion. Some of those timers don't behave correctly anymore now, without warning. This means that current software may behave differently with compiled with the latest Delphi 2010 update. I agree that window handles should not be wasted. But there should be a way do enable/disable timers from different threads. Or at least raise an exception if you try to disable a timer from a different thread than the one that created it. At least that way, we will get notified of any issues we need to change. Granted, enabling/disabling timers from different threads may not be best practice, but it used to work without any problems. QC Entry 81256

1. Create a TTimer, enable it, and wire some OnTimer code to check if the timer fires. 2. From another thread, set the Enabled property of the timer to False. Result: the OnTimer event keeps firing anyway, or worse, the message queue starts misbehaving resulting in an Access Violation.

QC #: 81270 - Status: Closed

QC #: Project Date Reported: Area: 81270 C++Builder 1/18/2010 Linker Description Steps:[QC Short Description] Linker Error: __fastcall Timespan::TTimeSpan::operator

bcc32 -P -WV qc81270.i

System::UnicodeString() [QC Description] Linker Error: __fastcall Timespan::TTimeSpan::operator System::UnicodeString() Sample code: ----- #include <Diagnostics.hpp> TStopwatch sw = TStopwatch::StartNew(); sw.Stop(); TTimeSpan ts = sw.Elapsed; UnicodeString s = ts; // Linker Error ----- Compilation is OK. But, the operator is missing when linking. QC Entry 81270

QC #: 81301 - Status: Closed

QC #: Project Date Reported: Area: 81301 Delphi 1/19/2010 RTL\Delphi\WinAPI Description Steps:[QC Short Description] Bad header translation for IDataInitialize.CreateDBInstance (OleDB.pas) [QC Description] IDataInitialize.CreateDBInstance is declared in OleDB.pas as: function CreateDBInstance(const clsidProvider: TGUID; const pUnkOuter: IUnknown; dwClsCtx: DWORD; pwszReserved: POleStr; riid: TIID; var DataSource: IUnknown): HResult; stdcall; This should be: function CreateDBInstance(const clsidProvider: TGUID; const pUnkOuter: IUnknown; dwClsCtx: DWORD; pwszReserved: POleStr; const riid: TIID; var DataSource: IUnknown): HResult; stdcall; (Note the missing const.) QC Entry 81301

N/A - bad header translation

QC #: 81327 - Status: Closed

QC #: Project Date Reported: Area:81327 Delphi 1/20/2010 IDE\Code Editor\Error Insight Description Steps:[QC Short Description] Unereported error (false negative) [QC Description] If a class/record "TRoot" contains a field which itself contains a field named "SubField" in the body of any method of class TRoot, Error Insight does not report references to "SubField" as errors. The compiler (correctly) fails with the error message : E2003 Undeclared identifier : 'SubField' QC Entry 81327

1. Create a new console application 2. Copy the following code into the *.dpr file Expected : Undeclared identifier 'SubField' at line ln (ln:cr) Actual : No message type TField = class //or record SubField : Integer; end; TRoot = class //or record Field : TField; procedure Method; end; { TRoot } procedure TRoot.Method; begin SubField := 0; end; //When trying to compile, the compiler (correctly) fails with the error message : //E2003 Undeclared identifier : 'SubField'

QC #: 81329 - Status: Closed

QC #: Project Date Reported: Area:81329 Delphi 1/20/2010 Database\DBExpress\TSQLStoredProc

Description Steps:[Oracle] [QC Short Description] Clientdataset looses parameters when connected to a SqlStoredProc [QC Description] Connecting a ClientDataSet to a SqlStoredProc doesn't work as it should. Opening the ClientDataSet causes that the SqlStoredProc looses IN params, so opening a second time or refreshing doesn't work. This worked right in BDE with TStoredProc. QC Entry 81329

TDBXFulcrumBugsSuite.Native.Db.Test.exe connection=oracleconnection -s:TestRaid_274659 -OR- Run this script in Oracle10 to create a package: CREATE OR REPLACE PACKAGE PackBasura AS TYPE r_Basura IS RECORD (CAMPOV VARCHAR2(50), CAMPON NUMBER(5,2), CAMPOD DATE ); TYPE ref_Basura IS REF CURSOR RETURN r_Basura; PROCEDURE ProcBasura(pa_p1 IN VARCHAR2, pr_Basura IN OUT ref_Basura); END PackBasura; / CREATE OR REPLACE PACKAGE BODY PackBasura AS PROCEDURE ProcBasura(pa_p1 IN VARCHAR2, pr_Basura IN OUT ref_Basura) IS vd_fecha DATE; BEGIN SELECT SYSDATE INTO vd_fecha FROM DUAL; OPEN pr_Basura FOR SELECT pa_p1 || '1' CAMPOV, 23.45 CAMPON, vd_fecha CAMPOD FROM DUAL UNION SELECT pa_p1 || '2', 34.56, vd_fecha FROM DUAL UNION SELECT pa_p1 || '3', 45.67, vd_fecha FROM DUAL; END ProcBasura; END PackBasura; Change the attached program to use your schema-user-password. Now run the program and press the button. Expected: both grids should show the data. Actual: both grids show the data. Press the button again. Expected: both grids should show the data. Actual: BDE-connected grid show the data. dbExpress connected grid gives an error about wrong parameters.

QC #: 81331 - Status: Closed

QC #: Project Date Reported: Area: 81331 C++Builder 1/20/2010 IDE\Class Explorer Description Steps:[QC Short Description] The Adding Property Utility Breaks the Code in Header File [QC Description] I am adding properties the a file, and the code is inserted wrong. This is what I get: __property String VersionOriginal = { void __fastcall SetShow(String val); String __fastcall GetShow(); read=GetVersionOriginal, write=SetVersionOriginal}; Instead of: __property String VersionOriginal = {write=SetVersionOriginal, read=GetVersionOriginal}; void __fastcall SetShow(String val); String __fastcall GetShow(); read=GetVersionOriginal, QC Entry 81331

1) Take attached file. 2) Add a property using the class explorer utility Added by Sysop <<<<<<<<<<<<<<< In my case, actual result is not same as yours. But, source code has been corrupted... >>>>>>>>>>>>>>>

QC #: 81333 - Status: Closed

QC #: Project Date Reported: Area: 81333 Delphi 1/20/2010 Database\DataSnap Description Steps:[QC Short Description] DataSnap 2010 filter performance problem [QC Description] There is a serious problem with the DataSnap 2010 filter performance. When using filters, even do-nothing pass-through filters, the performance can drop by a factor 5-100 (yes, that's up to 100 times as slow as the same request without a filter). The performance gets a little better if you increase the buffer size (at client and server) to a maximum of 1000 KB, but when using an ISAPI DLL, the max buffer size that can be used is 48 KB. As example I've used the ZLibCompression filter, but you can also use a do-nothing filter with the same results. I've created a small demo DataSnap application consisting of four applications. 1. DataSnapServer.exe - A DataSnap 2010 VCL Forms server with a main form where you can enable / disable the use of the Compression filter, and set the BufferKBSize (to a choice of 32, 48, 64, 128, 256 or 1000). Communication protocols are both TCP/IP and HTTP. 2. DataSnapISAPIServer.dll - A DataSnap ISAPI Server with no filters 3. DataSnapISAPIServerFilters.dll - A DataSnap ISAPI Server that uses the Compression Filter 4. DataSnapClient.exe - a DataSnap 2010 client application that can connect to the DataSnap VCL Forms server using TCP (port 211) or HTTP (port 8042), or to either of the DataSnap ISAPI servers. You can also set the Data Size (by default 1024 KB, but you can go from a minimum of 1 KB to any size you want), plus you can configure the

Create DataSnap 2010 Server, use any filter and connect a DataSnap 2010 client to it. Compare the response time to a server with the use of a filter. See the attached project for a ready-to-use example of three DataSnap servers and a client.

BufferSize (same choices as the VCL Forms server - for the ISAPI DLLs you should stick to 48 KB as maximum, otherwise you'll get an error from the ISAPI server). Feel free to test the client and the server. When they both reside on the same machine, there is no performance problem. However, as soon as the client is moved to another (similar!!) machine, the performance problem will show itself. When the Compression Filter is enabled at the VCL Forms DataSnap server, or the ISAPI Server with Filters is used, then the response times increases with a factor 5-100. The trouble is that both the client and server machine appear to be doing "nothing". The CPU load remains low, and the application itself doesn't come above 5% CPU usage, so it cannot be a problem with the processing or filter itself. Especially if you consider that using the filteron the same machine (client and server on same machine) shows no performance loss. The network usage is also very low, so it's not "waiting for data" either, although I suspect that the underlying problem is somewhere connected to an Indy client waiting for filter data to come in? (remember that it also fails for an ISAPI DataSnap server). I've spent almost a week trying to figure out where the bottle-neck is, and I just give up and have to report it here. Hope someone can shine a light on this, as this problem renders the use of filters almost impossible unless you stick to very small data packages (but even then the performance hit is noticable, and relatively worse of all). Delphi 2010, Update 4+5 applied. Using Windows XP, 2003 and 7, but the same problem bas been reproduced by others using Delphi 2010 as well. QC Entry 81333

QC #: 81335 - Status: Resolved

QC #: Project Date Reported: Area: 81335 Delphi 1/20/2010 Database\DataSnap Description Steps:[QC Short Description] Add DataSnap 2010 HTTPS / SSL client side support [QC Description] Please extend the communication protocol abilities of DataSnap 2010 clients with HTTPS / SSL support. Right now we only have TCP and (new in 2010) HTTP, but we need secured HTTPS support. Since deployment can be done as DataSnap ISAPI server on IIS, the server-side HTTPS / SSL support is not as important as client side (we can let IIS do what it's good at). But for client side, we need HTTPS support. Please. QC Entry 81335

Only TCP/IP and HTTP are available as communication protocol, not HTTPS

QC #: 81342 - Status: Closed

QC #: Project Date Reported: Area:81342 Delphi 1/20/2010 ActiveX\Type Library Editor Description Steps:[QC Short Description] Type Library editor: Edit controls do not accept paste with Ctrl + V or copy with Ctrl + C.

1- Create an item in the type library. 2- Place the caret in the name's edit in the Attributes page. 3- Press Ctrl + V Nothing. However, if you do it using the popup menu, the copying & pasting work OK.

[QC Description] In the type library, if you try to paste a text in the Edit corresponding to the name of an item, the pasting using Ctrl + V does not work nor do the copying with Ctrl + C. QC Entry 81342

QC #: 81416 - Status: Closed

QC #: Project Date Reported: Area: 81416 Delphi 1/22/2010 Compiler\Delphi\RTTI Description Steps:[QC Short Description] TValue.TryCast doesn't handle nil method pointers properly [QC Description] TRttiField.SetValue calls TValue.Cast, which calls TValue.TryCast. TryCast calls IsEmpty, which returns true under the following circumstances: if (FData.FTypeInfo = nil) or (FData.FHeapData = nil) then Exit(True); case FData.FTypeInfo^.Kind of tkClass: Result := FData.FAsObject = nil; tkInterface: Result := FData.FHeapData = nil; tkMethod: Result := FData.FAsMethod.Code = nil; else Result := False; end; Aside from the redundant check for FData.FHeapData = nil, there's a problem with the code. When the return value gets used, back in TryCast, it checks this line: Result := (ATypeInfo <> nil) and (ATypeInfo^.Kind in [tkInterface, tkClass, tkClassRef]); Therefore, if your TypeInfo kind is tkMethod and the method's Code pointer is nil, this will always fail and raise an exception in TValue.Cast, when it should have succeeded. tkMethod needs to be added to the set in the line above. QC Entry 81416 Added by Sysop <<<<<<<<<<<<<<<<<<<<<<<< The same glitch exists with TValue.FromVariant(Null) and variant fields. >>>>>>>>>>>>>>>>>>>>>>>>

See the attached files for more details. (JJS: See attached file BTS274631.dpr for alternative test. I believe the call to context.GetType(TButton) is problematic in this example.) [QC Steps] Feed a component into this routine and watch it crash and burn: procedure NilAllEventHandlers(myObject: TObject); var context: TRttiContext; rType: TRttiType; field: TRttiField; value: TValue; nilMethod: TMethod; begin nilMethod.Code := nil; nilMethod.Data := nil; context := TRttiContext.Create; rType := context.GetType(TButton); for field in rType.GetFields do begin if field.FieldType.TypeKind = tkMethod then begin TValue.Make(@nilMethod, field.FieldType.Handle, value); field.SetValue(myObject, value); end; end; end; [QC Steps]

QC #: 81435 - Status: Closed

QC #: Project Date Reported: Area: 81435 Delphi 1/22/2010 IDE\Startup/Shutdown Description Steps:[QC Short Description] IDE splash disapears when component not found on startup [QC Description] When starting the IDEthe splash screen shows components being loaded. If a component is not found during loading, the splash screen will disapear and there is no indication that the IDE is continuing loading and it appears as if the process of starting the IDE quit. However, the IDE continues to load (invisibly) and after completing the loading, appears as expected. This can result in developers

Add a bad package registry entry under: HKCU\Software\Embarcadero\BDS\8.0\Known Packages Name: badpackage Value: bogus Start the IDE Note that the splash screen disappears when the "Can't load package" error dialog appears Click Yes EXP: The splash screen is shown again while the IDE continues

relaunching the IDE so there becomes two instances of the IDE. A reason for this component not found error could be a component being uninstalled but it did not properly unregister from the IDE or if the component BPL was moved/deleted. My expectation is that if the error appears and the question of continue to load the problem component next time or remove from the component registry is answered, the splash screen would reappear (or never disapear in the first place) and continue on, showing the loading process until fully done and the IDE appears. QC Entry 81435

loading ACT: The splash screen is never shown again =========== Steps from QC: =========== Install any 3rd party component. Start the IDE to make sure the IDE shows the 3rd party component Shut down the IDE Delete/move the BPL for the 3rd party component Start the IDE. Note the normal splash screen start The splash screen will disapear when it reaches the point of loading the 3rd party component. A dialog appears, then answer YES or NO to reloading the 3rd party component next time the IDE is started. The dialog disapears and the splash screen doesn't reappear. The desktop appears as if nothing is happening and that the IDE is no longer loading. After some time (when the IDE finishes loading all the rest of the packages), the IDE will fully appear. Note: This delay becomes longer and longer if you have more and more 3rd party components, which I do.

QC #: 81450 - Status: Closed

QC #: Project Date Reported: Area:81450 Delphi 1/23/2010 IDE\Code Editor\Help Insight Description Steps:[QC Short Description] HelpInsight can't handle string code points with 2 WideChars [QC Description] HelpInsight has problems displaying a string constant that has a code point that needs 2 characters in UTF16. QC Entry 81450

1. Open the attached project 2. Move the mouse over the "str" constant name Expected: The string is displayed correctly Actual: The whole HelpInsight windows shows a defect UTF16 character and the html style is disabled.

QC #: 81471 - Status: Closed

QC #: Project Date Reported: Area: 81471 C++Builder 1/22/2010 4:22:52 PM VCL\Gestures Description Steps:Tested on Windows XP and 7 Problem linking Gestures.pas Note: Same steps work fine in Fulcrum. Added by Tomohiro Takahashi <<<<<<<<<<<<<<< This issue reproted as QC#81471 >>>>>>>>>>>>>>>

1. File|New|VCL C++ application 2. Drop TGestureManager onto form 3. Project|Options. Packages. Turn off option 'Build with Runtime Packages' 4. Project|Options. C++ Linker. Set Dynamic RTL to 'False' 5. Project|Build Project1.. //exp: Successful //act: [ILINK32 Error] Fatal: Type index 2147479550 is bad in module Gestures.pas

QC #: 81496 - Status: Closed

QC #: Project Date Reported: Area:81496 Delphi 1/25/2010 Database\DBExpress\TSQLStoredProc

Description Steps:[Oracle] [QC Short Description] TStoredProc fails to pass/receive VARCHAR2 parameter variable as In/Out param, using multi-byte characters(Chinese, Japanese etc...) [QC Description] With Oracle10g, TStoredProc fails to pass/receive VARCHAR2 parameter variable as In/Out param. This issue occurs when passing a string variable which contains multi-byte characters. I think this is similar to RAID#273768. Please take a lool at attached project. The definition of sample storedprocedure is as below. ------------------------- CREATE OR REPLACE PROCEDURE Test_BC2010 ( Pi_ErrMsg IN VARCHAR2, Po_ErrMsg1 OUT VARCHAR2, Po_ErrMsg2 OUT NVARCHAR2 ) IS BEGIN Po_ErrMsg1 := Pi_ErrMsg; Po_ErrMsg2 := Pi_ErrMsg; RETURN; EXCEPTION WHEN OTHERS THEN RETURN; END; / ------------------------- QC Entry 81496

TDBXFulcrumBugsSuite.Native.DB.Test.exe connection=oracleconnection -s:TestRaid_274657 -or- 1. start Oracle 10g and create a storedprocedure 2. build attached project and run it 3. the application pass/receive Japanese string as In/Out parameter to the storedprocedure 4. xxx->Value, xxx->AsString, and xxx->AsAnsiString fail.

QC #: 81502 - Status: Closed

QC #: Project Date Reported: Area:81502 Delphi 1/26/2010 VCL\Win 32 Controls\TImageList

Description Steps:[QC Short Description] ColorDepth related issues with cdDeviceDependent [QC Description] While upgrading sources code from Delphi 2006 to 2010 I encounteredseveral issues related to the new ColorDepth property and its default value cdDeviceDependent: - runtime transparent drawing using the TImageList's Draw method icw the properties BkColor and BlendColor set to clNone worked fine when first drawing a black background. This now leads to an image with a black background. This can only be fixed by drawing on either a clWhite background or setting ColorDepth to cd32Bit. - Calling Assign on a TImageList object with ColorDepth set to cdDeviceDependent (i.e. not set, just using the default) leads to a "hanging" application (actually TCustomImageList.WriteData hangs in calling ImageListWriteExProc). Question is why a new default value creates so many issues, while setting the ColorDepth to cd32Bit seems to fix all these issues (on Xp, Vista and Windows 7). QC Entry 81502

Just take .dfm (created in Delphi 2006) with a TImageList instance on it and all the properties set to default. Open the corresponding source file in D2010 and leave everything to their defaults. the bugs mentioned in the full description can be reproduced.

QC #: 81552 - Status: Closed

QC #: Project Date Reported: Area: 81552 Delphi 1/27/2010 Database\DBExpress Description Steps:[IB][Firebird] [QC Short Description] Firebird DBX Driver is very slow accessing Blob Fields [QC Description] Fetching 10,000 records with a Blob Field: - Delphi 2010 DBX Firebird Driver --> 22.4 seconds. - Free Firebird Driver (available from http://sites.google.com/site/dbxfirebird/home) --> 4.5 seconds. The free Driver is almost 5 times faster than Delphi 2010 DBX Firebird driver. QC Entry 81552 Added by Sysop <<<<<<<<<<<<<<< This issue is similar to RAID#274660(QC#81499) >>>>>>>>>>>>>>>

Open the project with Delphi 2010. Build the project and run it. If necessary, change the database path. Click "Insert 10000 records" button. Click "Fetch data with Delphi 2010 DBX4 driver" to test Delphi driver. Click "Fetch data with free driver" to test the free driver.

QC #: 81557 - Status: Closed

QC #: Project Date Reported: Area: 81557 Delphi 1/27/2010 IDE\Dialogs\Resources Description Steps:[QC Short Description] Resource Manager doesn't always appear to delete selected item [QC Description] If you have several resources, lets say four, in the resource manager (shown from Project->Resources), and you select either the first or second item in the list and press the Remove button some other item in the list is removed, not the selected one. However, if you close and open the dialog the item you wanted to delete is now gone, so I guess the problem is the resource list is not refreshing properly after a Remove. QC Entry 81557

QC #: 81595 - Status: Closed

QC #: Project Date Reported: Area: 81595 Delphi 1/28/2010 IDE\Code Editor\ Description Steps:[QC Short Description] Have no options to specify method's parameters formatting [QC Description] Delphi source code formatter reformat method's declaration (parameters) just to be adjusted within margins.

Before: function AddGroup( const aDimensionDefinitionItem: TDimensionDefinitionItem; const aSortOrder: TSortOrder): IGroup; overload; After: function AddGroup(const aDimensionDefinitionItem: TDimensionDefinitionItem; const aSortOrder: TSortOrder): IGroup; overload;

There should be options to control how to format parameters in the method declaration: 1. Keep as is 2. Break after or before each parameter (semicolon) A suggest new line break options: "Line Break after method's parameter" = {Yes|No|As Is} "Line Break after method's parameter" = {Yes|No|As Is} QC Entry 81595

QC #: 81596 - Status: Closed

QC #: Project Date Reported: Area:81596 Delphi 1/28/2010 IDE\Code Editor\Formatting Description Steps:[QC Short Description] Multiline statements should keep existed breaks [QC Description] If statement already occupy few lines there is no way to keep existed breaks. Please add an options to keep existed breaks for multiline statements. QC Entry 81596

Before: Result := (aDimensionDefinitionItem in GetAvailableDimensionItems) and (daColumn in GetDimensionData(aDimensionDefinitionItem).ApplyTo) and (Columns.Count = 0) and not Assigned(FindColumn(aDimensionDefinitionItem)); After: Result := (aDimensionDefinitionItem in GetAvailableDimensionItems) and (daColumn in GetDimensionData(aDimensionDefinitionItem).ApplyTo) and (Columns.Count = 0) and not Assigned (FindColumn(aDimensionDefinitionItem)); [vk] Additional option included in Delphi and C++ - keep user linebreaks

QC #: 81603 - Status: Closed

QC #: Project Date Reported: Area: 81603 Delphi 1/28/2010 SOAP Description Steps:[QC Short Description] Bug in InvRegistry.UnRegisterInvokableClass [QC Description] Calling InvRegistry.UnRegisterInvokableClass doesnt clean FRegIntfs[].DefImpl reference Then calling InvRegistry.GetClassFromIntfInfo gives wrong answers (access violation in my case, since the class the I'm unregistering is in a unloaded DLL) QC Entry 81603

IMyInterface = interface(IInvokable) ['{3BE163F7-FA2F-4FB0-AB03-51414399BAE2}'] end; TMyImplementation1 = class(TInvokableClass, IMyInterface) end; TMyImplementation2 = class(TInvokableClass, IMyInterface) end; .............. InvRegistry.RegisterInterface(TypeInfo(IMyInterface)); InvRegistry.RegisterInvokableClass(TMyImplementation1); InvRegistry.UnRegisterInvokableClass(TMyImplementation1); InvRegistry.RegisterInvokableClass(TMyImplementation2); InvRegistry.GetClassFromIntfInfo(TypeInfo(IMyInterface), ClassRef); ShowMessage(ClassRef.ClassName); // Displays 'TMyImplementation1' instead of 'TMyImplementation2'

QC #: 81605 - Status: Closed

QC #: Project Date Reported: Area:

81605 Delphi 1/28/2010 RTL\Delphi\Other Classes\TStreamReader/TStreamWriter

Description Steps:[QC Short Description] Variant property doesn't preserve its ValueType [QC Description] In RAD Studio 2009 and later, the ValueType of a published Variant property isn't correctly restored when reloading a form. For example, setting it to 'String' results in 'Unknown' after reloading the form; 'Single' is changed to 'Double'; 'Integer' to 'ShortInt'. QC Entry 81605 [SB: See comments]

We've designed a small custom component to illustrate this problem in action. Please install it and try to work with the TestProject. Set the component's Value.ValueType property to different values, reload the form, and see the result.

QC #: 81636 - Status: Closed

QC #: Project Date Reported: Area:81636 C++Builder 1/29/2010 IDE\Project Management\Project Manager

Description Steps:[QC Short Description] Exclude from Linking [QC Description] There is STILL NO option to exclude from linking! My patience is almost exhausted. I'm waiting since more than 5 years now!!! Unbelievable!! QC Entry 81636 Added by Sysop <<<<<<<<<< This issue same as QC#25162/QC#53812. >>>>>>>>>>

Added by Sysop <<<<<<<<<< This issue same as QC#25162/QC#53812. >>>>>>>>>>

QC #: 81643 - Status: Closed

QC #: Project Date Reported: Area:81643 Delphi 1/29/2010 IDE\Code Editor\Error Insight Description Steps:[QC Short Description] "Identifier redeclared" with overloaded functions using the "same" dynamic array [QC Description] Using the "same" dynamic array in an overloaded function leads to an "Identifier redeclared" error for the variables. -> see steps QC Entry 81643

- save the file at the end of the steps - start Delphi - open EIOverloadedFunctionsWithDynArrayTest.dpr expected: no Error Insight errors in the Structure view and the editor actual: Identifier redeclared 'N' at line 18 (18:3) program EIOverloadedFunctionsWithDynArrayTest; {$APPTYPE CONSOLE} // from JclBase.pas revision 3098 type TDynStringArray = array of string; TDynUnicodeStringArray = array of UnicodeString; procedure FinalizeArrayBeforeMove(var List: TDynStringArray); overload; var N: Integer; begin end; procedure FinalizeArrayBeforeMove(var List: TDynUnicodeStringArray); overload; var N: Integer; begin end; begin end.

QC #: 81644 - Status: Closed

QC #: Project Date Reported: Area:81644 Delphi 1/29/2010 IDE\Code Editor\Error Insight

Description Steps:[QC Short Description] "Expected ... but received ..." with abstract or sealed class declaration without an end [QC Description] Empty class declarations with abstract or sealed, but without an end lead to an "Expected ... but received ..." error. -> see steps QC Entry 81644

- save the file at the end of the steps - start Delphi - open EIClassAbstractSealedTest.dpr expected: no Error Insight errors in the Structure view and the editor actual: Expected [ but received ; at line 10 (10:34) program EIClassAbstractSealedTest; {$APPTYPE CONSOLE} type TAbstractClassWithEnd = class abstract end; TSealedClassWithEnd = class sealed end; TAbstractClass = class abstract; TSealedClass = class sealed; begin end.

QC #: 81679 - Status: Closed

QC #: Project Date Reported: Area:81679 C++Builder 1/31/2010 Debugger\Evaluator ToolTips Description Steps:[QC Short Description] AnsiStrings are still not shown on ToolTip [QC Description] When the mouse is moved over an AnsiString variable, it is necessary to do one click before to see the contents. This is very annoying and time consuming. Reported since the Unicode-change, but still not fixed. QC Entry 81679

QC #: 81694 - Status: Closed

QC #: Project Date Reported: Area: 81694 Delphi 2/1/2010 Midas Description Steps:[QC Short Description] Potential memory leak/corruption on midas sources [QC Description] On midas sources there are a lot of calls like (canex.cpp#4875) pCHAR pFldName; (...) pFldName = new CHAR[len + 1]; (...) delete pFldName; Where probably, it should have been "delete [] pFldName;" instead. This would: a) Work every time, even if the compiler stop handling this behind the scenes in the future, b) CodeGuard wouldn't complain anymore with duzens of log entries (per every Locate call) c) a cleaner/correct code to the programmer reviewing the source, that at the moment is left wondering if this will leak or corrupt the memory. QC Entry 81694

[C++Builder Personality] File, New, Other, Console Application. Project, Options, C++ Compiler, Debugging, Enable CodeGuard, True, Ok. #pragma comment(lib, "midas.lib") void RegMidas() { RegisterMidasLib(DllGetClassObject); } #pragma startup RegMidas int _tmain(int argc, _TCHAR* argv[]) { std::auto_ptr<TClientDataSet>cds(new TClientDataSet((TComponent*)NULL)); TField *n = new TStringField(cds.get()); n->FieldName = "Foo"; n->DataSet = cds.get(); cds->CreateDataSet(); cds->Open(); cds->AppendRecord(ARRAYOFCONST((String("FooBar")))); cds->Locate("Foo", String("Bar"), TLocateOptions()); cds->Close(); return 0; } This will fill CodeGuard log with "Resource type mismatch in process" warnings in files#line: canex.cpp#4875 canex.cpp#5188 canex.cpp#5448 curinit.cpp#130 curinit.cpp#141 ds.cpp#239 ds.cpp#258 ds.cpp#264 ds.cpp#271 ds.cpp#289 dscanexp.cpp#45 dscanexp.cpp#49 dsinmem2.cpp#1570 dslog.cpp#42 dslog.cpp#58 dspickle.cpp#310 dspickle.cpp#1167 dsxml.cpp#2379

QC #: 81729 - Status: Closed

QC #: Project Date Reported: Area:

81729 C++Builder 2/2/2010 IDE\Class Explorer Description Steps:[QC Short Description] Error in Class Explorer when using existing methods to implement a property [QC Description] When adding a property there is an option to use existing methods for its implementation. This option gives a confusing/irrelevant error message and generates code that won't compile. QC Entry 81729 Added by Sysop <<<<<<<<<<<<<<<<<<<<<< This also doesn't work if a property is based on an existing field, for example, basing a property 'Value' on field 'FValue' in this class: class TTester { private: int FValue; }; becomes class TTester { private: void __fastcall FValue(int val); int __fastcall FValue(); int FValue; public: __property int Value = {read=FValue, write=FValue}; }; i.e. it erroneously adds in method signatures for 'FValue' >>>>>>>>>>>>>>>>>>>>>>

1. Start with a class defined like this class TTester { private: void SetValue(int); int GetValue(); }; 2. Use Class Explorer to add a property, Name= Value, Type= int, Visibility= public, and select Existing Field/Method = GetValue() for Read and Existing Field/Method= SetValue(int) for Write 3. Press Add 4. See error message 'GetValue() is not a valid identifier. Root filenames of IDE-managed units must be valid identifiers.' Generated code is wrong and won't compile: class TTester { private: void SetValue(int); int GetValue(); public: __property int Value = {read=GetValue(), write=SetValue(int)}; }; Should be class TTester { private: void SetValue(int); int GetValue(); public: __property int Value = {read=GetValue, write=SetValue}; };

QC #: 81795 - Status: Closed

QC #: Project Date Reported: Area: 81795 C++Builder 2/4/2010 IDE\Class Explorer Description Steps:[QC Short Description] Error in Class Explorer when using existing fields to implement a property [QC Description] When adding a property there is an option to use existing fields for its implementation. This option erroneously adds method declarations based on the field's name. QC Entry 81795

1. Start with a class like this class TTester { private: int FValue; }; 2. Use class explorer to add a public property named 'Value', type 'int' and base its read/write implementation on existing field 'FValue.' 3. The code erroneously adds in method declarations for 'FValue' and becomes: class TTester { private: void __fastcall FValue(int val); int __fastcall FValue(); int FValue; public: __property int Value = {read=FValue, write=FValue}; }; 4. Expected: class TTester { private: int FValue; public: __property int Value = {read=FValue, write=FValue}; };

QC #: 81799 - Status: Closed

QC #: Project Date Reported: Area: 81799 C++Builder 2/4/2010 IDE\Code Editor\ Description Steps:[QC Short Description] Code formatting of certain case statements is undesirable [QC Description] If 'Format Source' is used on case statements that are (preprocessor) expressions, the resulting indentation/line breaks do not look good. This is cosmetic and does not affect the compilation.

1. Start with the following source code (NB contrived example, it does not do anything useful) #define XXX 1 int _tmain(int argc, _TCHAR* argv[]) { switch (0) {

QC Entry 81799 case XXX: break; case XXX + 1: break; case (XXX + 2): break; default: break; } return 0; } 2. Press CTRL+D to make the IDE format it 3. Result is: int _tmain(int argc, _TCHAR* argv[]) { switch(0) { case XXX: break; case XXX + 1 : break; case (XXX + 2) : break; default: break; } return 0; } 4. Expected 'case', the expression, and the colon to be on one line. This is OK if the expression is a single token, but not if is an expression. The presence of ( ) changes the formatting but neither is correct [vk] it was already fixed for a long time

QC #: 81804 - Status: Closed

QC #: Project Date Reported: Area: 81804 Delphi 2/4/2010 VCL\Core VCL Classes Description Steps:[QC Short Description] TStrings.ValueFromIndex return empty string [QC Description] Problem with TStrings.ValueFromIndex method. Example: var StringList:TStringList; ... StringList:=TStringList.Create; StringList.Add('name1=value1'); StringList.Add('=value2'); StringList.Add('name3='); ShowMessage(StringList.Names[0]); ShowMessage(StringList.ValueFromIndex[0]); ShowMessage(StringList.Names[1]); ShowMessage(StringList.ValueFromIndex[1]); ShowMessage(StringList.Names[2]); ShowMessage(StringList.ValueFromIndex[2]); StringList.Free; The above code example in Delphi 7 shows the following messages: 1)"name1" 2)"value1" 3)empty string 4)"value2" 5)"name3" 6)empty string

The same code example in Delphi 2010 shows the following messages:1)"name1" 2)"value1" 3)empty string 4)empty string ??? 5)"name3" 6)empty string Why does StringList.ValueFromIndex[1] return empty string? StringList.ValueFromIndex[1] should return "value2". How can it be prevented? The GetValueFromIndex function can be implemented as follows: function TStrings.GetValueFromIndex(Index: Integer): string; var P: Integer; begin if Index >= 0 then begin P := AnsiPos(NameValueSeparator, Get(Index)); if P > 0 then Result := Copy(Get(Index), P + 2, MaxInt) else Result := ''; end else Result := ''; end; QC Entry 81804

QC #: 81933 - Status: Closed

QC #: Project Date Reported: Area: 81933 Delphi 2/8/2010 Compiler\Delphi\Generics Description Steps:[QC Short Description] Cannot override a strict protected method of a generic class declared in a different file [QC Description] The virtual abstract method TClassA<T>.StrictProtectedFunction: T (in Unit 1) cannot be overridden in TClassZ. The compiler says: Method 'StrictProtectedFunction not found in base class. (Original: [DCC Fehler] Project1.dpr(11): E2137 Methode 'StrictProtectedFunction' nicht in Basisklasse gefunden) QC Entry 81933

See attached project (BTS274886.dpr and UnitBTS274886.pas) for details. // program file program BTS274886; {$AppType Console} uses SysUtils, UnitBTS274866; type TClassZ = class(TClassC<String>) strict protected function StrictProtectedFunction: String; override; end; { TClassZ } function TClassZ.StrictProtectedFunction: String; begin Result := ''; end; begin writeLn('PASS'); end. {##FAILIFMSG.English: BTS274886.dpr(12) Error: E2137 Method 'StrictProtectedFunction' not found in base class}

// unit file unit UnitBTS274866; interface type TClassA<T> = class strict protected function StrictProtectedFunction: T; virtual; abstract; end; TClassB<T> = class(TClassA<T>) end; TClassC<T> = class(TClassB<T>) end; implementation end.

QC #: 81995 - Status: Closed

QC #: Project Date Reported: Area:81995 Delphi 2/9/2010 IDE\Code Editor\Error Insight Description Steps:[QC Short Description] Missing error when using non-existing type in a class-reference type [QC Description] I cleaned up some code and wrote something like this TFooClass = class of TCustomFoo; but TCustomFoo didn't exists and Error Insight didn't detect that error. -> see steps QC Entry 81995

- save the file at the end of the steps - start Delphi - open ClassOfEITest.dpr expected: an error saying that TCustomFoo on line 9 does not exist actual: no Error Insight errors in the Structure view and the editor (the compiler reports "[DCC Error] ClassOfEITest.dpr(9): E2003 Undeclared identifier: 'TCustomFoo'") program ClassOfEITest; {$APPTYPE CONSOLE} type TFoo = class(TObject) end; TFooClass = class of TCustomFoo; begin end.

QC #: 82004 - Status: Closed

QC #: Project Date Reported: Area:82004 C++Builder 2/9/2010 Compiler\C++\Interaction with the IDE

Description Steps:[QC Short Description] Treat Warnings as errors doesn't treat warnings as errors QC Entry 82004

[ New Steps ] File | New | C++ Console application. In source (before "return 0;") add: int i; unsigned int j; j = i; Project | Options | C++ Compiler | Warnings | Treat warnings as error = true Project | Make As expected, compilation terminates with errors. Project | Make - second make is successful because the first make produced an .obj; the warnings were reported as errors but the compiler wrote a new .obj anyway. [ Old Steps ] Turn on Treat Warnings as errors in base configuration. (possibly other configurations as well). Press F9 to compile and run and watch the list of warnings be built. after compiling instead of stopping due to the warning/errors it runs.

QC #: 82034 - Status: Closed

QC #: Project Date Reported: Area: 82034 Delphi 2/10/2010 Documentation Description Steps:[QC Short Description] No documentation for the Delphi "object" keyword [QC Description] There is no documentation about the Delphi keyword "object". QC Entry 82034

1) Open Delphi help 2) Select the Delphi filter 3) Enter the search word "object"

QC #: 82084 - Status: Closed

QC #: Project Date Reported: Area: 82084 Delphi 2/12/2010 Documentation Description Steps:[QC Short Description] Delphi documentation about TListView is imcomplete [QC Description] The French Delphi documentation about TListView is imcomplete : - the documentation page "constructeurs ComCtrls.TListView" exists only in C synatx and not in Delphi syntax - the documentation page "membre ComCtrls.TListView" is empty QC Entry 82084

1) Open BDS 2) Open Help system 3) Search for TListView

QC #: 82166 - Status: Closed

QC #: Project Date Reported: Area:82166 Delphi 2/15/2010 RTL\Delphi\DateUtils

Description Steps: [QC Short Description] IncMilliSecond goes negative [QC Description] When I use the IncMilliSecond function to "add" 1500 milliseconds to a TDateTime value of 0 (zero) the result is negative. When I use simple arithmatic to do the same thing the answer is, as expected, positive. The problem is that when I compare the TDateTime value the answer is "incorrect" QC Entry 82166 Added by Sysop <<<<<<<<<<< Please see comments of QC for more information. >>>>>>>>>>> [AMP] The bug also

To show this I created a simple application with a button and a memo field on the main form. I put the following code in the buttons OnClick event handler... //============================================================================== procedure TfrmMain.pbGoClick(Sender: TObject); var Dt : TDateTime; begin Dt := 0; Dt := Dt + 1.5 / 86400; mmOutput.Clear; mmOutput.Lines.Add ('With simple arithmatic...'); mmOutput.Lines.Add (FormatDateTime ('dd/mm/yyyy hh:nn:ss.zzz', Dt)); mmOutput.Lines.Add (FloatToStr (Dt)); Dt := 0; Dt := IncMilliSecond (Dt, 1500); mmOutput.Lines.Add ('With IncMilliSecond function...'); mmOutput.Lines.Add (FormatDateTime ('dd/mm/yyyy hh:nn:ss.zzz', Dt)); mmOutput.Lines.Add (FloatToStr (Dt)); end; //==============================================================================The memo field has this in it... With simple arithmatic... 30/12/1899 00:00:01.500 1.73611111111111E-5 With IncMilliSecond function... 30/12/1899 00:00:01.500 -1.73611111111111E-5 You can see that the last value is negative! The documentation for IncMilliSecond states that the input value is "incremented" by the number of milliseconds. I believe that the result of my code should be positive.

reproduces when using IncMinutes or IncHour. Also, RAID 266110 it's the same bug, just on another version( 12 ).

QC #: 82168 - Status: Resolved

QC #: Project Date Reported: Area: 82168 Delphi 2/16/2010 Documentation Description Steps:[QC Short Description] RecodeDateTime fails when AHour is 24. [QC Description] The documentation states: AHour can range from 0 through 24 (or be RecodeLeaveFieldAsIs). If AHour is 24, AMinute, ASecond, and AMilliSecond must all be 0. The function fails when hour is 24. QC Entry 82168

The following code fails: ADate := RecodeDateTime(Now, RecodeLeaveFieldAsIs, RecodeLeaveFieldAsIs, RecodeLeaveFieldAsIs, 24, 0, 0, 0); When this code is executed, the following error message is displayed: Project Project1.exe raised exception class EConvertError with message '"2010-2-16 24:0:0,0" is not a valid date and time'. This bug is also present in Delphi 2007.

QC #: 82187 - Status: Closed

QC #: Project Date Reported: Area:82187 Delphi 2/16/2010 ActiveX\Type Library Editor Description Steps:[QC Short Description] TypeLibrary editor does not save changes [QC Description] The type library editor does not save changes made to the name of some items in it. See steps. QC Entry 82187

1- Create ActiveX Library 2- Add an Automation object (not sure this is strictly necessary). 3- Add an enumeration. 4- Add a few constants to the enumeration, leave the default names (Const1, Const2, etc.) 5- Save the project 6- Change the name of Const1, say to Const1xxx. Click refresh button. The name of Const1 is NOW changed to Const1xxx. 7- Save project again. 8- Close project. Re-open project. Const1 is not called Const1xxx but the original Const1. (NOTE From Bruneau: Chris correctly identified that this problem is tied to code in the 'Refresh' handler that was no longer flushing the Type Libray model to the .ridl buffer. I've attached an image that shows that the 'Modified' flag is not ON after 'Refresh' - which is a good sign that changes to the typelibrary won't be saved. I've checked in logic to flush the model on 'Refresh'. Let's hope this does the trick).

QC #: 82199 - Status: Closed

QC #: Project Date Reported: Area: 82199 Delphi 2/16/2010 IDE\Code Editor

Description Steps:[QC Short Description] Editing DFM as text causes pascal source loss [QC Description] After editing DFM as text and saving, part of the pas source is lost. Added by Sysop <<<<<<<<< Please see comments for more details. This issue occurs on Russian locale OS(including Virtual machines). >>>>>>>>> QC Entry 82199

Better steps from the QC comments: 1. Open the attached Project1. dproj. 2. Open a form module Unit1. pas (F12) 3. Choose the context menu View as Text. 4. Put and delete the space in the very beginning of the text dfm 5. Click Save all 6. Can close the project 7. The open and see procedure TForm1.Button1Click(Sender: TObject); begin // ??????????? comment. Exit; en DK: I see trunction somewhat different from the above, but code is definitely modified. --original steps-- 1. Create New VCL Application project 2. Place TButton on a form 3. DoubleClick on the button to create OnClick handler 4. Write in the handler code like this procedure TForm1.Button1Click(Sender: TObject); begin // ???????????. comment. Exit; end; note that beginning of the comment contains russian characters. 5. Save Project. You can close it and reopen again. 6. Open DFM as Text (Alt-F12) 7. Add and delete space somewhere in the dfm source. Be sure you are not editing any Caption, because this will not cause the bug. 8. Save edited DFM (File, Save). Close it. 9. Open pascal source (Ctrl-F12) you will see that comment line is cut, and there are nothing else after it. procedure TForm1.Button1Click(Sender: TObject); begin // ???????????. comme Attached archive of the initial project to help if support team will be unable to insert russian characters as a comment.

QC #: 82201 - Status: Closed

QC #: Project Date Reported: Area:82201 Delphi 2/17/2010 VCL\Core VCL Classes\TForm

Description Steps:[QC Short Description] TForm.DoKeyUp not called from controller if docked

Take a form (with KeyPreview set to True) and try out OnKeyDown and OnKeyUp. All works. Then dock the form, now only OnKeyDown works.

[QC Description] TWinControl.DoKeyUp is missing a check to see if the form has a parent (ie: it is docked). This result in that the controller does not send respond to keyup events up to the form if it is docked. TWinControl.DoKeyDown on the other hand does have this check and works good. To Fix it simply compare the very similar TWinControl.DoKeyDown and TWinControl.DoKeyUp and the problem will show itself. QC Entry 82201

QC #: 82217 - Status: Closed

QC #: Project Date Reported: Area:

82217 Delphi 2/17/2010 VCL\Additional Controls\Action Bar Controls\TActionManager

Description Steps:[QC Short Description] TCustomActionControl.DrawDragDropPoint is not virtual [QC Description] The TCustomActionControl.DrawDragDropPoint method should be made virtual. The DrawDragDropPoint method renders the insertion point when an action bar/menu is being customized via drag/drop. All other visual elements of the class can be customized in derived classes through virtual methods. QC Entry 82217

QC #: 82220 - Status: Closed

QC #: Project Date Reported: Area:

82220 Delphi 2/17/2010 VCL\Additional Controls\Action Bar Controls\TMainMenuActionBar

Description Steps:[QC Short Description] Menu designer is not notified when separator is inserted through keyboard [QC Description] The TCustomActionPopupMenu.WMKeyDown method fails to notify the menu designer when a separator is inserted via a VK_SUBTRACT keypress. To fix the problem just call NotifyDesigner() after the new menu item has been created: VK_SUBTRACT: if DesignMode and (Selected <> nil) then begin Item := TActionClientItem(Items.Insert(Selected.Index)); Item.Caption := '-'; Item.Control.Visible := True; Item.Control.Selected := True; NotifyDesigner(Self); // <<<< Add this end;

The code, in the same method, that inserts an empty menu item via the VK_INSERT key correctly notifies the menu designer with a call to NotifyDesigner(). While you're at it, replace with '-' with cLineCaption - that's what it's there for. QC Entry 82220

QC #: 82237 - Status: Closed

QC #: Project Date Reported: Area: 82237 Delphi 2/17/2010 Compiler\Delphi\RTTI Description Steps:[QC Short Description] TRttiProperty.SetValue does not work with TDateTime properties [QC Description] When TRttiProperty.SetValue is called for a TDateTime or TDate property the following exception is raised: "Invalid class typecast". QC Entry 82237

Compile and run the attached application below. See the following runtime error indicating failure. FAIL - Exception (EInvalidCast) program BTS275295; {$APPTYPE CONSOLE} uses RTTI; var Counter: Integer = 0; Expected: Integer = 0; {$M+} type TSomeObject = class private FDate: TDateTime; public property TradeDate: TDateTime read FDate Write FDate; end; procedure RAID275295; var lObject: TSomeObject; lRtti: TRttiContext; lType: TRttiType; lProperty: TRttiProperty; Date: TDateTime; begin Inc(Expected); Date := 0; lObject := TSomeObject.Create; lRtti := TRttiContext.Create; try lType := lRtti.GetType(lObject.ClassInfo); lProperty := lType.GetProperty('TradeDate'); lProperty.SetValue(lObject, TValue.FromVariant(Date)); Inc(Counter); finally lRtti.Free; lObject.Free; end; end; begin try RAID275295; if Counter = Expected then

WriteLn('PASS') else WriteLn('FAIL - Expectation failure (', Counter, '/', Expected, ')'); except on E: TObject do WriteLn('FAIL - Exception (', E.ClassName, ')'); end; end.

QC #: 82251 - Status: Closed

QC #: Project Date Reported: Area:82251 Delphi 2/18/2010 IDE\Code Editor\Help Insight Description Steps:[QC Short Description] Chr() does not return AnsiChar QC Entry 82251

please see screen shot

QC #: 82280 - Status: Closed

QC #: Project Date Reported: Area: 82280 C++Builder 2/18/2010 Debugger\Inspector Description Steps:[QC Short Description] Debug Visualizer for AnsiString Requested [QC Description] A Debug Visualizer for the AnsiString type is requested, so that the Debug Insight displays the string content directly, instead of having to expand the displayed objects tree branch. AnsiString Debug Insight should work in the same way as UnicodeString does. Added by Sysop <<<<<<<<< Sample implementation is attached. >>>>>>>>> QC Entry 82280

Invoke Debug Insight in IDE while debugging, on an AnsiString variable, and then on a UnicodeString variable.

QC #: 82319 - Status: Closed

QC #: Project Date Reported: Area:82319 Delphi 2/19/2010 VCL\Win 32 Controls\TImageList

Description Steps:[QC Short Description] TCustomImageList.GetImageBitmap and GetMaskBitmap incorrectly deletes bitmap object [QC Description] According to the ImageList_GetImageInfo documentation: http://msdn.microsoft.com/en-us/library/bb761554%28VS.85%29.aspx An application should not call DeleteObject to destroy the bitmaps retrieved by ImageList_GetImageInfo. The system destroys the bitmaps when the application calls the ImageList_Destroy function. However, that is exactly what the GetImageBitmap and

GetMaskBitmap methods do: function TCustomImageList.GetImageBitmap: HBITMAP; var Info: TImageInfo; begin if (Count > 0) and ImageList_GetImageInfo(Handle, 0, Info) then begin Result := Info.hbmImage; DeleteObject(Info.hbmMask); end else Result := 0; end; function TCustomImageList.GetMaskBitmap: HBITMAP; var Info: TImageInfo; begin if (Count > 0) and ImageList_GetImageInfo(Handle, 0, Info) then begin Result := Info.hbmMask; DeleteObject(Info.hbmImage); end else Result := 0; end; QC Entry 82319

QC #: 82355 - Status: Closed

QC #: Project Date Reported: Area: 82355 Delphi 2/21/2010 Compiler\Delphi\Generics Description Steps:(See also 275405) [QC Short Description] Generic property setter with constant parameter failed [QC Description] see steps. QC Entry 82355

// [DCC Error] Unit3.pas(24): E2037 Declaration of 'SetName' differs from previous declaration The following unit cannot be compiled. It will work if comment out the following line or remove the const keyword. unit Unit3; interface type TNullable<T> = record private fValue: T; fHasValue: string; // it will be ok if commenting out this line . end; TPerson = class private FName: TNullable<string>; procedure SetName(const Value: TNullable<string>); public property Name: TNullable<string> read fName write SetName; end; implementation { TPerson } procedure TPerson.SetName(const Value: TNullable<string>); begin fName := value; end; end.

QC #: 82368 - Status: Closed

QC #: Project Date Reported: Area:82368 Delphi 2/22/2010 Debugger\Evaluator Description Steps:[QC Short Description] Uneccessary debugger visualizer restriction! [QC Description] Hi! I noticed that it is not possible to define: IOTADebuggerVisualizerValueReplacer and IOTADebuggerVisualizer

Steps by USc: 1. save the attachment 2. start Delphi 3. install StringsValueReplaceVisualizerPackage.dpk 4. make sure that both TStrings visualizers are enabled on the page "Debugger Options | Visualizer" in the environment options (if not o close the IDE o remove the reg visualizer key (D2010 - HKEY_CURRENT_USER\Software\CodeGear\BDS\7.0\Debugging\Visualizers) o restart the IDE) 5. open StringsVisTestProject.dpr 6. put a breakpoint on line 15 ("SL.Add('GROUP BY NAME');"); 7. run (it should now stop on line 15) 8. add a watch for "SL" 9. move the mouse over "SL" on line 15 to show the tooltip expected: the tooltip and the watch item do show the external visualizer glyph and do show value from the replace visualizer ("Count = 2 SELECT * FROM...") (it should look like on the "Both TStrings Visualizers together" "image" on the bottom of TStringsVisualizerFutureBig.png) actual: the tooltip and the watch item do show the external visualizer glyph and "()" (it does look like on the "Default TStrings Visualizers

to apply to the same type. Why not? It would be very usefull. Currently I get various errors when trying to register both for the same type. Thanks! Atmapuri QC Entry 82368

(External Viewer)" "image" on the top left of TStringsVisualizerFutureBig.png) 10. stop the execution of StringsVisTestProject 11. disable the external viewer visualizer for TStrings ("TStrings Visualizer for Delphi") in the environment options "Debugger Options | Visualizer" 12. run again StringsVisTestProject expected: the watch list would show the value from the replace visualizer for "SL" which should be "Count = 2 SELECT * FROM..." actual: --------------------------- Error --------------------------- Item not found. --------------------------- OK Details >> --------------------------- o in case there is no item in the watch list for "SL" you would get that exception when you try to show the tooltip for "SL" o see top entries of the stack trace here at the end of the steps and full stack trace in the attachment (StackTraceItemNotFound.txt) 13. close Delphi and restart Delphi 14. repeat steps 5. till 9. and see that you now see the value from replace visualizer (it should look like on the "TStrings Visualizers (Value Replace)" "image" on the top right of TStringsVisualizerFutureBig.png) 15. stop the execution of StringsVisTestProject 16. try to enable the external viewer visualizer for TStrings ("TStrings Visualizer for Delphi") in the environment options "Debugger Options | Visualizer" expect: no AV when I close the environment options with OK actual: --------------------------- Error --------------------------- Access violation at address 208B2CBC in module 'coreide140.bpl'. Read of address 00000008. --------------------------- OK Details >> --------------------------- (see top entries of the stack trace here at the end of the steps and full stack trace in the attachment [StackTraceAV.txt]) Top stack trace entries for Item not found. with D2010 Update 4 [208B37B1]{coreide140.bpl} DebuggerMgr.TDictionary<System.string,DebuggerMgr.TVisualizerItem>.GetItem (Line 1359, "Generics.Collections.pas" + 3) + $16 [208ACDA2]{coreide140.bpl} DebuggerMgr.TDebuggerMgr.GetReplacerVisualizerForType (Line 1111, "DebuggerMgr.pas" + 13) + $D [2095A2EE]{coreide140.bpl} WatchWin.TWatchWindow.GetVisualizerValue (Line 290, "..\debugger\WatchWin.pas" + 1) + $17 [2095A676]{coreide140.bpl} WatchWin.TWatchWindow.EvaluateWatches (Line 377, "..\debugger\WatchWin.pas" + 60) + $28 Top stack trace entries for Access violation at address 208B2CBC in module 'coreide140.bpl'. Read of address 00000008. with D2010 Update 4 [208B2CBC]{coreide140.bpl} DebuggerMgr.TList<ToolsAPI.IOTADebuggerVisualizerExternalViewer>.Add (Line 649, "Generics.Collections.pas" + 1) + $4 [208B17A3]{coreide140.bpl} DebuggerMgr.TVisualizerList.InternalAdd (Line 2835, "DebuggerMgr.pas" + 58) + $A [208B1AF2]{coreide140.bpl} DebuggerMgr.TVisualizerList.SetEnabled (Line 2902, "DebuggerMgr.pas" + 11) + $9 [209E0AD8]{coreide140.bpl} DebuggerVisualizerOptions.TDebuggerVisualizerOptionsPage.PropertySheetBroadcast (Line 90, "..\debugger\DebuggerVisualizerOptions.pas" + 23) + $35 [20EA0207]{vclide140.bpl} IDEPropSheet.TPropertySheet.DoBroadcast (Line 160, "IDEPropSheet.pas" + 2) + $C [20EA0668]{vclide140.bpl} IDEPropSheet.TPropertySheetControl.Broadcast (Line 336, "IDEPropSheet.pas" + 9) + $9 [20887D4E]{coreide140.bpl} EnvOptions.TEnvironmentOptions.StampIt (Line 1037, "EnvOptions.pas" + 38) + $16 [500EB895]{rtl140.bpl } Rtti.RawInvoke (Line 5250, "Rtti.pas" + 38) + $0 [500EBBFA]{rtl140.bpl } Rtti.Invoke (Line 5433, "Rtti.pas" + 38) + $6 [500E4E65]{rtl140.bpl } Rtti.TRttiInstanceMethodClassic.GetCallingConvention (Line 3825, "Rtti.pas" + 1) + $2 [500E5810]{rtl140.bpl } Rtti.TRttiInstanceMethodEx.DispatchInvoke (Line 4130, "Rtti.pas" + 130) + $17 [500EBE30]{rtl140.bpl } Rtti.TRttiMethod.Invoke (Line 5500, "Rtti.pas" + 1) + $11 [20887B1E]{coreide140.bpl} EnvOptions.TEnvironmentOptions.Edit (Line 987, "EnvOptions.pas" + 3) + $1 [0041B550]{bds.exe } SanctuaryChecker.CheckForProductInfo (Line 1416, "ui\SanctuaryChecker.pas" + 49) + $3 [5007570B]{rtl140.bpl } Classes.TBasicAction.Execute (Line 12513, "Classes.pas" + 3) + $7

QC #: 82385 - Status: Closed

QC #: Project Date Reported: Area: 82385 C++Builder 2/22/2010 RTL\C++\I/O Description Steps:[QC Short Description] _ftelli64 returns positive integer on failure, not -1 [QC Description] _ftelli64 returns a 64 bit integer type, __int64. It is supposed to return -1 (0xFFFFFFFFFFFFFFFF) on failure, but instead returns 0x00000000FFFFFFFF (a 32 bit representation of -1, zero padded). QC Entry 82385

1. Create a new console application. 2. Add the following code. #include <vcl.h> #pragma hdrstop #include <stdio.h> int main() { __int64 pos = _ftelli64(stdout); printf("%lld\n", pos); __int64 minusOne = -1; printf("%lld\n", minusOne); return 0; } 3. Build and run. The _ftelli64 function should return -1 to indicate an error as non-redirected stdout does not support file positioning. So, the program should output: -1 -1 What it actually outputs: 4294967295 -1

QC #: 82391 - Status: Closed

QC #: Project Date Reported: Area: 82391 Delphi 2/22/2010 Debugger\Debugger UI Description Steps:[QC Short Description] Prompt to rebuild projects modified while debugging [QC Description] The type of the following message box should be changed from "Information" to "Confirm": --------------------------- Information --------------------------- Source has been modified. Rebuild? --------------------------- Yes No Cancel Help --------------------------- QC Entry 82391

QC #: 82417 - Status: Closed

QC #: Project Date Reported: Area: 82417 Delphi 2/23/2010 Database\DBExpress Description Steps:[DBX][Driver][Oracle] [QC Short Description] 'FDSCursor.GetField(RecBuf, FieldNo, Buffer, IsBlank)' returns IsBlank as False incorrectly. [QC Description] [DBX][Driver][Oracle] In certain case, 'FDSCursor.GetField(RecBuf, FieldNo, Buffer, IsBlank)' returns IsBlank as False incorrectly. In that case, IsBlank must be returned as True. As a result, application gets EConvertError while DBGrid trying to display NULL value of SQLTimestamp. Steps: 1. make sure that rowsetsize parameter of TSQLConnection is set to 10000. 2. press CREATE TABLE button 3. press Insert button 4. press SELECT button 5. DBGrid shows result set 6. press horizontal scrollbar of DBGrid to see DATE column fields 7. you get EConvertError when trying to see NULL value of SQLTimestamp [DBClient.pas] ---------------------------- function TCustomClientDataSet.GetFieldData(Field: TField; Buffer: Pointer): Boolean; var IsBlank: LongBool; RecBuf: TRecordBuffer; begin ... ... Check(FDSCursor.GetField(RecBuf, FieldNo, Buffer, IsBlank)); // IsBlank has been returned as False incorrectly.

See attached sample project Environment - Server: Oracle 10gR2 - ClientLibrary: InstantClient 10.2.0.4

Result := not IsBlank; ... ... ---------------------------- QC Entry 82417

QC #: 82424 - Status: Closed

QC #: Project Date Reported: Area: 82424 Delphi 2/24/2010 Compiler\Delphi\Generics Description Steps:[QC Description] (BK: I have edited this to reflect the actual failing situation) Records containing managed types but of a register size don't have proper lifetime management for temporaries. [QC Description] see steps QC Entry 82424

TCanary is double-freed in this example. Note that the problem goes away if an explicit temporary is used (Use vs Use1) or the size is increased (FSizeMaker) program prog; {$APPTYPE CONSOLE} uses SysUtils; type TCanary = class(TObject, IInterface) private FName: string; FRefCnt: Integer; public constructor Create(const AName: string); destructor Destroy; override; function _AddRef: Integer; stdcall; function _Release: Integer; stdcall; function QueryInterface(const IID: TGUID; out Obj): HRESULT; stdcall; end; constructor TCanary.Create(const AName: string); begin FName := AName; end; destructor TCanary.Destroy; begin Writeln(FName, ' died'); end; function TCanary._AddRef: Integer; stdcall; begin Inc(FRefCnt); Writeln(FName, ' addref to ', FRefCnt); Result := FRefCnt; end; function TCanary._Release: Integer; stdcall; begin Dec(FRefCnt); Writeln(FName, ' release to ', FRefCnt); Result := FRefCnt; if FRefCnt = 0 then Destroy; end; function TCanary.QueryInterface(const IID: TGUID; out Obj): HRESULT; stdcall; begin if GetInterface(IID, Obj) then Result := S_OK else

Result := E_NOINTERFACE; end; type TRec = record private FArr: IInterface; // FSizeMaker: array[0..10] of Byte; public constructor Create(x: Integer); procedure Frob; end; var FRec: TRec; constructor TRec.Create(x: Integer); begin FArr := TCanary.Create('FArr'); end; procedure TRec.Frob; begin end; function Get: TRec; begin Result := FRec; end; procedure Init; begin FRec := TRec.Create(5); end; procedure Use; var x: TRec; begin x := Get; x.Frob; x.FArr := nil; end; procedure Use1; begin Get.Frob; end; procedure P; begin Init; Use1; Use1; end; begin try P; except on E: Exception do Writeln(E.ClassName, ': ', E.Message); end; end.

QC #: 82433 - Status: Closed

QC #: Project Date Reported: Area: 82433 Delphi 2/24/2010 RTL\Delphi\Other RTL

Description Steps:[QC Short Description] TValue.TryAsType<T> raised an AV because ConvClass2Intf is wrong [QC Description] see steps. QC Entry 82433

open the Rtti.pas, the follow commented line should be function ConvClass2Intf(const ASource: TValue; ATarget: PTypeInfo; out AResult: TValue): Boolean; var iid: TGUID; obj: Pointer; begin iid := GetTypeData(ATarget)^.Guid; if IsEqualGUID(iid, GUID_NULL) then Exit(False); // Future: consider instance -> interface conversion even without GUID Result := AResult.FData.FAsObject.GetInterface(iid, obj); // !!!WRONG, should be Result := ASource.FData.FAsObject.GetInterface(iid, obj); if Result then TValue.MakeWithoutCopy(@obj, ATarget, AResult); end;

QC #: 82437 - Status: Closed

QC #: Project Date Reported: Area:82437 Delphi 2/24/2010 IDE\Dialogs\Project Options Description Steps:[QC Short Description] Single path [...] buttons do not see newly entered path [QC Description] In the project options dialog there are several options that accept a single directory entry: BPI/LIB output, intermediate output, final output, etc. If I enter a valid path into one of these fields, then press the [...] button I expect the directory I entered to be selected, verifying my typing and allowing me to select a nearby directory easily. Unfortunately, the directory selection box does not show the location of the directory I typed in - instead it shows the location of the previous entry. What's worse, when I hit the cancel button, my typed-in entry is removed and replaced by the previous value. This is inconsistent with the operation of the [...] buttons in the Tools | Options dialog, which work correctly. This also eliminates the possibility of checking the accuracy of the typed-in path. QC Entry 82437

File | New | VCL Forms app Project | Options | Delphi Compiler On the DCP output directory line type c:\windows (or another valid directory) Click the [...] button Exp: Directory select dialog will show c:\windows Act: Shows the default project directory Click Cancel Exp: My typed in path will still show on the DCP output line Act: The path I entered is removed

QC #: 82438 - Status: Closed

QC #: Project Date Reported: Area:82438 Delphi 2/24/2010 IDE\Dialogs\Project Options Description Steps:[QC Short Description] Single path [...] buttons do not expand environment variable entries [QC Description] In the project options dialog there are several options that accept a single directory entry: BPI/LIB output, intermediate output, final output, etc. If I enter an environment variable containing a valid path into one of these fields, then press the [...] button I expect the directory I entered to be selected, verifying my typing and allowing me to select a nearby directory easily. QC 82437 shows a problem with the directory selection box immediately recognizing any new entry, but environment variables are not recognized even after being saved as in the workaround for that report. This is inconsistent with the operation of the [...] buttons in the Tools | Options dialog, which work correctly.

File | New | VCL Forms app Project | Options | Delphi Compiler On the DCP output directory line type $(BDS) Click Ok to save - see qc 82437 for why this is necessary Project | Options | Delphi Compiler Click the [...] button Exp: Directory select dialog will show c:\program files\embarcadero\RAD Studio\7.0 Act: Shows the default project directory AFAICT, this makes it impossible to verify that the environment variable is typed correctly and represents an existing path.

This also eliminates the possibility of checking the accuracy of the environment variable path. QC Entry 82438

QC #: 82442 - Status: Resolved

QC #: Project Date Reported: Area:82442 Delphi 2/24/2010 Documentation\Online Help Description Steps:[QC Short Description] Project page item missing in Project Menu [QC Description] According to the Help there should be an item on the Project Menu called Project Page. It should open the project Page option dialog that lets you designate a html-file that will open first when you open the project later on. Added by Sysop <<<<<<<<<<<<<< This documentation issue is about Delphi for .NET which has been already removed on 2009/2010. >>>>>>>>>>>>>> QC Entry 82442

The item is missing on the menu. Added by Sysop <<<<<<<<<<<<<<<<<<< The URL in the help is ms-help://embarcadero.rs2010/rad/Project_Page_Options.html >>>>>>>>>>>>>>>>>>>

QC #: 82551 - Status: Closed

QC #: Project Date Reported: Area: 82551 Delphi 2/28/2010 IDE\Build Tools Description Steps:[QC Short Description] Regression: Syntax check does not respect the active build config [QC Description] The syntax check feature does not respect the active build configuration and it seems that it does use the "Base" configuration instead. This is regression from D2007 that happened already in D2009. -> see steps QC Entry 82551

- start Delphi - create a new console application and paste the code at the end of the steps - compile (it is supposed to compile, because "Debug" is by default the active build config and it defines DEBUG) - Project | Syntax Check SyntaxCheck expected: no error actual: (Debug configuration) [Error] SyntaxCheck.dpr(6): E2029 Declaration expected but '*' found Failed Elapsed time: 00:00:00.0 - put DEBUG into the Conditional defines of the "Base" build config - Project | Syntax Check SyntaxCheck - see there is no error (Debug configuration) Success Elapsed time: 00:00:00.0 program SyntaxCheck; {$APPTYPE CONSOLE} {$IFNDEF DEBUG} * {$ENDIF ~DEBUG} begin end.

QC #: 82558 - Status: Closed

QC #: Project Date Reported: Area: 82558 C++Builder 3/1/2010 Compiler\C++ Description Steps:[QC Short Description] Small project causes out of scope destructors to be called QC Entry 82558

bcc32.exe -Od 275258.cpp 275258.exe exp: run without errors/output act: destroying me?

Abnormal program termination

QC #: 82563 - Status: Closed

QC #: Project Date Reported: Area:82563 Delphi 3/1/2010 VCL\Core VCL Classes\Streaming

Description Steps:[QC Short Description] TStreamWriter - when appending to file, BOM added before each string you append [QC Description] When using TStreamWriter to append text to an already existing file, and encoding is either UTF8 or Unicode, a byte order mark is added before the string you append. QC Entry 82563 Added by Sysop <<<<<<<<<<<<<< This issue exists in Delphi 2009 and 2010. >>>>>>>>>>>>>> [SB: has auto test]

program StreamwriterBOMTest; {$APPTYPE CONSOLE} uses SysUtils, Classes; procedure WriteToLog(Text: String); var StreamWriter: TStreamWriter; begin StreamWriter := TStreamWriter.Create('log.txt', True, TEncoding.UTF8); try StreamWriter.WriteLine(Text); finally StreamWriter.Free; end; end; begin WriteToLog('Line 1'); WriteToLog('Line 2'); WriteToLog('Line 3'); end. By USc: - compile and execute StreamwriterBOMTest - have a look at log.txt expected: BOM + 'Line 1' + Linebreak + 'Line 2' + Linebreak + 'Line 3' + Linebreak actual: BOM + 'Line 1' + Linebreak + BOM + 'Line 2' + Linebreak + BOM + 'Line 3' + Linebreak d Additional notes: - no BOM was written till D2009 Update #3 (QC 66901/RAID 265409) - "WriteBytes(FEncoding.GetPreamble);" in TStreamWriter.Create should only be executed when FStream.Position = 0

QC #: 82591 - Status: Closed

QC #: Project Date Reported: Area: 82591 Delphi 3/1/2010 Compiler\Delphi\Generics Description Steps:[QC Short Description] operator "is" fails to compile when applied to a type parameter of a generic method. [QC Description] see steps Added by Sysop

Compile the attached application below. See the following unexpected compile-time error indicating failure. Error: E2015 Operator not applicable to this operand type program BTS275294;

<<<<<<<<<< I got complie error like this: [DCC Error] Unit9.pas(31): E2015 Operator not applicable to this operand type >>>>>>>>>> QC Entry 82591

{ operator "is" fails to compile when applied to a type parameter of a generic method. } {$APPTYPE CONSOLE} uses Classes; type TForm9 = class private { Private declarations } public { Public declarations } function Check<T : TList>(L : TArray<TList>):boolean; end; var Form9: TForm9; { TForm9 } function TForm9.Check<T>(L: TArray<TList>): boolean; var A : TList; begin Result := false; for A in L do if not(A is T) then exit; //Compiler fail here Result := true; end; begin WriteLn('PASS'); //PASS on compile// end.

QC #: 82598 - Status: Closed

QC #: Project Date Reported: Area:82598 Delphi 3/2/2010 IDE\Refactoring\Extract Method

Description Steps:[QC Short Description] Extract Method did not support generics [QC Description] see steps: QC Entry 82598

uses Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms, Dialogs; type TClass1<T> =class end; TForm9 = class(TForm) procedure FormCreate(Sender: TObject); private { Private declarations } public { Public declarations } C : TClass1<integer>; end; var Form9: TForm9; implementation {$R *.dfm} procedure TForm9.FormCreate(Sender: TObject); begin C := TClass1<integer>.Create; //select this line and do a extract method operation end; end. after extract method will get result like this which can not be complied : unit Unit9; interface uses Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms, Dialogs; type TClass1<T> =class end; TForm9 = class(TForm) procedure FormCreate(Sender: TObject); private procedure ExtractedMethod(TClass1`1: Unit9.TClass1<integer>); //Can not complie here { Private declarations } public { Public declarations } C : TClass1<integer>; end; var Form9: TForm9; implementation {$R *.dfm} procedure TForm9.FormCreate(Sender: TObject); begin ExtractedMethod(TClass1`1); //compile fail here end; procedure TForm9.ExtractedMethod(TClass1`1: Unit9.TClass1<integer>); //strange ` character here begin C := TClass1.Create; end; end.

QC #: 82627 - Status: Closed

QC #: Project Date Reported: Area:

82627 Delphi 3/2/2010 Modeling\Generate Documentation

Description Steps:[QC Short Description] In generated html file, generic paramter is lost [QC Description] In .pas file, Check method is declared with generic paramter. ----------------- TForm1 = class(TForm) Button1: TButton; private public function Check<T: TList>(L: TArray<TList>): Boolean; end; ----------------- But, in generated html file, the generic paramter is lost. ----------------- Check public function Check(L: TArray<TList>): Boolean ----------------- QC Entry 82627

In .pas file, Check method is declared with generic paramter. ----------------- TForm1 = class(TForm) Button1: TButton; private public function Check<T: TList>(L: TArray<TList>): Boolean; end; ----------------- But, in generated html file, the generic paramter is lost. ----------------- Check public function Check(L: TArray<TList>): Boolean ----------------- [vk] rev.32356 - templates support in Delphi methods. Correct navigation for templates. [vk] rev.32372 - templates support in Cpp classifiers [vk] rev.32508. Generics constrains is supported in Delphi only (additional parameter "Generic Parameters") and only in the easy form - such as T: TList), because generic constraints are not implemented in Cpp SCI and for complex form in Delphi SCI.

QC #: 82637 - Status: Closed

QC #: Project Date Reported: Area: 82637 Delphi 3/3/2010 Compiler\Delphi\RTTI Description Steps:[QC Short Description] TypeInfo Table corrupted - GetTypes() forces an AV [QC Description] Hi, We try to use the new RTTI feature from D2010. But if we also use runtime packages multiple strange effect happens. The sample code use a console application and the runtime packages rtl140.bpl and PCDomainContractModel.bpl. If we try to get the type information from our package and access violation occure. Because a can not debug RTL140.bpl (as runtime package) I have stepped through assembler statements. It seems that the TypeTable (a array of PTypeInfo references) is corrupted. With this unstable behaviour the RTTI feature are not usable!!! QC Entry 82637

program RttiTest; {$APPTYPE CONSOLE} { using runtime packages rtl and PCDomainContractModel } uses SysUtils, Rtti, PCDomainContractModelAnalysis; procedure TestRtti(); var types : TArray<TRttiType>; context : TRttiContext; package : TRttiPackage; singleResult : TAnalysisResult; begin singleResult := TAnalysisResult.Create(13); singleResult.Free(); context := TRttiContext.Create(); try for package in context.GetPackages() do begin types := package.GetTypes(); // <--- AV for my package!! *********** end; except on E: Exception do Writeln(E.ClassName, ': ', E.Message); end; context.Free(); end; begin TestRtti(); ReadLn; end. //===== PCDomainContractModel.dpk ======================================== package PCDomainContractModel; {$R *.res} {$ALIGN 8} {$ASSERTIONS ON} {$BOOLEVAL OFF} {$DEBUGINFO ON} {$EXTENDEDSYNTAX ON} {$IMPORTEDDATA ON} {$IOCHECKS ON} {$LOCALSYMBOLS ON} {$LONGSTRINGS ON} {$OPENSTRINGS ON} {$OPTIMIZATION ON} {$OVERFLOWCHECKS OFF} {$RANGECHECKS OFF} {$REFERENCEINFO OFF} {$SAFEDIVIDE OFF} {$STACKFRAMES OFF} {$TYPEDADDRESS OFF} {$VARSTRINGCHECKS ON} {$WRITEABLECONST ON} {$MINENUMSIZE 1} {$IMAGEBASE $20100000} {$IMPLICITBUILD ON} requires rtl; contains PCDomainContractModelAnalysis in 'PCDomainContractModelAnalysis.pas', PCDomainContractModelQuartis in 'PCDomainContractModelQuartis.pas'; end. //===== PCDomainContractModelAnalysis.pas ======================================== unit PCDomainContractModelAnalysis; interface uses Classes, Generics.Defaults, Generics.Collections; type TConvertResult = (crFullyConvertedC, crPartiallyConvertedC, crNotConvertedC); TConvertedProgramInfo = class strict private FWorkpieceNumber: Cardinal; FProgramNumber : Cardinal; FProgramName : String; public constructor Create(p_WorkpieceNumber: Cardinal; p_ProgramNumber: Cardinal; p_ProgramName: String); property

Workpi

QC #: 82639 - Status: Closed

QC #: Project Date Reported: Area: 82639 C++Builder 3/3/2010 RTL\C++\I/O Streams Description Steps:[QC Short Description] Copy constructor not private for ios_base [QC Description] When trying to copy a stream in a trivial example, no errors are issued. according to the c++ standard such code should produce an error as the copy constructor of std::ios_base should contain a private copy constructor. Allowing the above code is both non standard and dangerous It also have been the cause of access violations in our project. Attached code: #include <iostream> std::ostream& createNewStream() { static std::ostream o(0); return o; } int main() { std::ostream os = createNewStream(); return 0; } QC Entry 82639

bcc32 -c qc82639.cpp Exp: (from Comeau online compiler) "ios", line 398: error: "std::ios_base::ios_base(const std::ios_base &)" (declared at line 254) is inaccessible class basic_ios : public ios_base { ^ detected during: implicit generation of "std::basic_ios<_CharT, _Traits>::basic_ios(const std::basic_ios<char, std::char_traits<char>> &) [with _CharT=char, _Traits=std::char_traits<char>]" at line 9 of "ComeauTest.c" instantiation of class "std::basic_ios<_CharT, _Traits> [with _CharT=char, _Traits=std::char_traits<char>]" at line 9 of "ComeauTest.c" implicit generation of "std::basic_ostream<_CharT, _Traits>::basic_ostream(const std::basic_ostream<char, std::char_traits<char>> &) [with _CharT=char, _Traits=std::char_traits<char>]" at line 9 of "ComeauTest.c" instantiation of class "std::basic_ostream<_CharT, _Traits> [with _CharT=char, _Traits=std::char_traits<char>]" at line 9 of "ComeauTest.c" Act: Clean compile - no diagnostics

QC #: 82651 - Status: Closed

QC #: Project Date Reported: Area: 82651 Delphi 3/3/2010 IDE\Project Management Description Steps:[QC Short Description] No message given when changed source is read-only [QC Description] When a source file is read-only on disk but editable and modified in the editor, clicking the Save button does nothing. Neither does it show a message to say which file has been modified. See Steps. QC Entry 82651

1. New VCL Application. 2. Save and close. 3. Using Window Explorer, navigate to the folder where the files were saved and mark all the files (unit, form, project file) Read Only. 4. Reopen the project in Delphi. 5. Right-click the Unit1 tab and untick Read Only. 6. Add a button to the form (any change will do). 7. Click Save. Expected: Nice error message to tell me the file is read-only. Especially useful if it includes the file name, just in case I have several files open in the editor. Actual: Nothing. It doesn't save the file, nor does it complain. You just notice the Save All button remains enabled. And if you attemp to close the project, you will be prompted to save the file. 8. Now, close Unit1 but not the project. 9. Right-click the project in Project Manager and click View Source. 10. Make a change. Anything - I just add a blank line somewhere. 11. Click Save. Expected: As above. Actual: As above. 12. Now close the project source in the editor (keeping the project open in Project Manager). 13. Click Save. Expected: As above - a nice error message. Actual: Hey! That's exactly the message I expected to see!

QC #: 82664 - Status: Closed

QC #: Project Date Reported: Area: 82664 Delphi 3/3/2010 Internet\Indy Description Steps:[QC Short Description] TIdFTP is broken in Delphi2010. Get method corrupts files. [QC Description] I download files from a Norton FTP-Server (ftp://ftp.symantec.com/public/deutsch/virus_signaturen/norton_antivirus/)using TIdFTP component. Get method copies the files but they become corrupted. Files are bigger than original files. I have the same client program compiled with Delphi 7 (Indy9.00.10). It works fine with the exact same data. Example: Filename: 20100222-017-i32.exe Filesize D7: 74.361.480 Bytes Filesize D2010: 74.636.623 Bytes TransferType is ftBinary. If I download the file using Firefox or Internet Explorer it is ok. Same result as Delphi 7. Added by Sysop <<<<<<<<<<<<<< This issue is similar to QC#83161 >>>>>>>>>>>>>> QC Entry 82664

Create new project. Use "TIdFTP" and enter parameters. Call IdFTP1.Get and wait til download is finished. File size is too big.

QC #: 82669 - Status: Closed

QC #: Project Date Reported: Area: 82669 C++Builder 3/4/2010 Compiler\C++ Description Steps:[QC Short Description] F1008 out of memory error [QC Description] I cannot get any of my existing C++Builder projects, imported from CB2007, to compile. Each time I get a F1008 Out of memory error. If I add the compiler flag -CX512, the error message does not appear, but no output (.obj files) are produced. I have stripped down one of tmy offending projects and attach it as a test case. There are two source files included in the project: an RC file and a CPP file. The RC file generates a RES file as expected. The CPP file generates nothing. The oce in the CPP file consists of compile option checks solely - so it should compile! QC Entry 82669

1. Open attached project. 2. Build all 3. Observe F1008 Out of memory error 4. Add -CX512 flag to advanced compiler options 5. Save project and close CB2010 6. Repoen CB2010 and project 7. Build all 8. Observe NO F1008 error but also no output (which should go to same folder as source code) Help!

QC #: 82742 - Status: Closed

QC #: Project Date Reported: Area:82742 C++Builder 3/6/2010 Documentation\Online Help Description Steps:[QC Short Description] broken links QC Entry 82742

Hi, I Found an error in the help file (the very latest updated last week 06.03.2010). Steps: 1. Mark (click on) IBdatabase component on a form as active. 2. Press F1. 3. Click on Class methods 4. and then click on any method which appears on the list. Looks like a broken link. Same for properties. It might be missing help topic but the those topic are available and references are working properly in BCB 6 so I would expect they were ?oved·to new help system. Regards Michal Mucha

QC #: 82757 - Status: Closed

QC #: Project Date Reported: Area:82757 Delphi 3/7/2010 IDE\Code Editor\Formatting Description Steps:[QC Short Description] Please make an option to format the whole project [QC Description] Because doing it manual one by one is really nonsens in this era QC Entry 82757

QC #: 82765 - Status: Closed

QC #: Project Date Reported: Area: 82765 Delphi 3/7/2010 Compiler\Delphi\Generics Description Steps:[QC Short Description] URW1111 when using array of generic type as interface function parameter [QC Description] F2084 Internal Error: URW1111 This occurs when using array of Generic Type as method parameters in an interface definition. QC Entry 82765

Steps by USc: - save the attached files or the files at the end of my steps - dcc32 -B QC82765.dpr expected: it compiles actual: QC82765Unit.pas(17) Fatal: F2084 Internal Error: URW1111 It fails with -B and -M for the DPR and all options (-B, -M, no -B or -M) for the PAS file. That means the other way round it does compile when using "dcc32 QC82765.dpr". //--- QC82765.dpr --- program QC82765; {$APPTYPE CONSOLE} uses QC82765Unit; begin WriteLn('PASS'); // on compile end. //--- QC82765Unit.pas --- unit QC82765Unit; interface type IASTNode<TASTNodeType> = interface end; IASTNodeList<TASTNodeType> = interface procedure AddRange(const Calues: array of IASTNode<TASTNodeType>); end; implementation end. Original steps: The following code (cut down to the bare minimum to reproduce) will result in [DCC Fatal Error] Unit1.pas(19): F2084 Internal Error: URW1111 type IASTNode<TASTNodeType> = interface end; IASTNodeList<TASTNodeType> = interface procedure AddRange(const values : Array of IASTNode<TASTNodeType>); end;

QC #: 82786 - Status: Closed

QC #: Project Date Reported: Area: 82786 Delphi 3/8/2010 RTL\Delphi\WinAPI Description Steps:[QC Short Description] Missing API Constant (TME_NONCLIENT) in Windows.pas

Attempt to compile this function: uses Windows.pas procedure TestFunc ; var theTrackEvent: TTrackMouseEvent ; begin theTrackEvent.dwFlags := TME_LEAVE or TME_NONCLIENT ;

[QC Description] The TME_NONCLIENT constant usable as a flag for the TRACKMOUSEEVENT.dwFlags item is not defined in Windows.pas (although the other 4 TME_XXX constants, and the Delphi record wrapper for the Windows mouse event message, are). It _is_ defined - along with the other 4 constants and Delphi record - in CommCtrl.pas, but as the constant's been around for a long time (introduced in Win98) it seems inconsistent and confusing to define it in the one location and not the other. QC Entry 82786

end ;

QC #: 82798 - Status: Closed

QC #: Project Date Reported: Area:82798 Delphi 3/8/2010 Compiler\Delphi\Language\Overloading

Description Steps:[QC Short Description] Operator overloading: Implicit conversion to PWideChar, PAnsiChar and ShortString does not work [QC Description] The sample project in Steps gets compiled unless you make the type T an alias for PWideChar, PAnsiChar or ShortString. For some strange reason the compiler is unable to perform an implicit conversion in these cases. Explicit conversion works fine in all the cases. Implicit conversion to PWideChar/PAnsiChar fails with E2010 Incompatible types. Implicit conversion to ShortString fails with E2008 Incompatible types. QC Entry 82798

program implic; type T = PWideChar{TObject|char|pointer|string|uint64|integer}; type R = record public class operator Implicit(const self: R): T; end; class operator R.Implicit(const self: R): T; begin result := default(T) end; var a: T; z: R; begin // Explicit conversion: always works a := T( z ); // Implicit conversion: works for all types except for PWideChar/PAnsiChar and ShortString a := z // E2010 Incompatible types: 'R' and 'PWideChar' end.

QC #: 82824 - Status: Closed

QC #: Project Date Reported: Area:82824 Delphi 3/9/2010 IDE\Code Editor\Formatting Description Steps:[QC Short Description] Incorrect formatting [QC Description] the following code is incorrectly formatted by the Delphi formatter. The result is that all lines below it are offset by the current indent. typeTcxCalcEditAccess = class(TcxCalcEdit); TcxCustomCalculatorAccess = class(TcxCustomCalculator); TcxPopupCalculatorAccess = class(TcxPopupCalculator); QC Entry 82824

Added by Sysop <<<<<<<<<<<<<<<<<< The class() lines were originally in my code after the implementation statement, the effect then was to offset every line until the end (ie all procedures) [code before formatting] type TcxCalcEditAccess = class(TcxCalcEdit); TcxCustomCalculatorAccess = class(TcxCustomCalculator); TcxPopupCalculatorAccess = class(TcxPopupCalculator); var fPackSize: TfPackSize; implementation [code after formatting] type TcxCalcEditAccess = class(TcxCalcEdit); TcxCustomCalculatorAccess = class(TcxCustomCalculator); TcxPopupCalculatorAccess = class(TcxPopupCalculator); var fPackSize: TfPackSize; implementation >>>>>>>>>>>>>>>>>>

QC #: 82835 - Status: Closed

QC #: Project Date Reported: Area:82835 C++Builder 3/9/2010 Linker\Interaction with the IDE

Description Steps:[QC Short Description] linker fails to process open DEF file

Create a module definition file and insert into the project. Leaving the file open in the window, build the project. Build will fail in the link stage with "[ILINK32 Error] Fatal: Error processing .DEF file".

[QC Description] If a Module Definition File is opened in the editor window, the IDE linker cannot process it and reports a fatal error "Cannot process file ***.def" QC Entry 82835

QC #: 82838 - Status: Closed

QC #: Project Date Reported: Area: 82838 Delphi 3/9/2010 Compiler\Delphi\Generics Description Steps:[QC Short Description] Mutually-dependent generics cause Out Of Memory in the compiler [QC Description] When the compiler attempts to compile generic class A that contains a member of generic class B, in which B references A, an out of memory error occurs. It appears that the compiler is attempting to resolve the generics' type immediately, before a type to fill in the generic type parameter ("T") has been provided, instead of waiting for actual instantiation, and getting caught in an infinite loop. QC Entry 82838

Two test cases are provided below. Try to compile either one in a simple package or console app using these units. (USc: dcc32 test.pas -> test.pas(15) Fatal: F2046 Out of memory dcc32 hierarchy_tree.pas -> hierarchy_tree.pas(63) Fatal: F2046 Out of memory) Case 1: unit test; interface type TFoo<T> = class; TBar<T> = class FFooOfBar: TFoo<TBar<T>>; // this reference causes the endless loop // FBarOfFoo: TBar<TFoo<T>>; // same problem here end; TFoo<T> = class (TBar<T>); implementation end. Case 2: unit hierarchy_tree; interface uses SysUtils, generics.collections; type THierarchyTreeList<T: class> = class; THierarchyTreeNode<T: class> = class private type TEnumerator = class(TEnumerator<T>) private FTopNode: THierarchyTreeNode<T>; FIndex: integer; FNext: TEnumerator; FTopRead: boolean; protected function DoGetCurrent: T; override; function DoMoveNext: Boolean; override; public constructor Create(value: THierarchyTreeNode<T>); function GetCurrent: T; function MoveNext: boolean; property Current: T read GetCurrent; end; TNodeList = THierarchyTreeList<THierarchyTreeNode<T>>; private FData: T; FRight: TNodeList; FList: TNodeList; function GetParent: THierarchyTreeNode<T>; function GetLevel: integer; public constructor Create(value: T); destructor Destroy; override; procedure Add(node: THierarchyTreeNode<T>); overload; procedure Add(value: T); overload; function GetEnumerator: TEnumerator; property List: TNodeList read FList; property Right: TNodeList read FRight; property Parent: THierarchyTreeNode<T> read GetParent; property Level: integer read GetLevel; property Data: T read FData write FData; end; THierarchyTreeList<T: class> = class(TObjectList<THierarchyTreeNode<T>>) private FParent: THierarchyTreeNode<T>; FLevel: integer; procedure SetParent(Value: THierarchyTreeNode<T>); public constructor Create(parent: THierarchyTreeNode<T>); function Add(value: THierarchyTreeNode<T>): integer; property Parent: THierarchyTreeNode<T> read FParent write SetParent; property Level: integer read FLevel; end; implementation { No implementation provided. Compiler will break before reaching this point anyway. } end.

QC #: 82854 - Status: Closed

QC #: Project Date Reported: Area:82854 Delphi 3/10/2010 Compiler\Delphi\RTTI\Custom attributes

Description Steps:[QC Short Description] Using typinfo with Custom-Attributes in EXE-Project causes [DCC Error] E2008 Incompatible types [QC Description] UsesBusinessAspectAttribute = class(TCustomAttribute) (...)

1. Unzip the attached ZIP-FIle 2. Open the Projekt-Group StructeringBusinessLayer.groupproj 3. Build all --> The Compiler-Error apears 4. Comment out the Line [UsesBusinessAspect(typeinfo(ICm3DatabaseBusinessAspect))] in the Unit1.pas. 5. Build all --> It all Compiles successfully although UsesBusinessAspect-Attribute is used in Unit ViewModel.Contract.Conversion.pas the same way.

public constructor Create(const p_Type : TRttiType); overload; virtual; property BusinessAspectInterfaceId : TGuid read GetBusinessAspectInterfaceId; property BusinessAspectInterfaceName : string read GetBusinessAspectInterfaceName; end; Using this Attribute in a Exe-Projekt like this [UsesBusinessAspect(typeinfo(ICm3DatabaseBusinessAspect))] IBlaViewViewModel = interface(IViewModel) ['{30B46340-19ED-4279-8FCE-C06A1F549BA1}'] end; Causes [DCC Error] E2008 Incompatible types. Please have a look to the appended example at unit ViewModel.Contract.Conversion.pas. There the code works very well with the UsesBusinessAspectAttribute-Class. You can test this by commenting out the code [UsesBusinessAspect(typeinfo(ICm3DatabaseBusinessAspect))] IBlaViewViewModel = interface(IViewModel) ['{30B46340-19ED-4279-8FCE-C06A1F549BA1}'] end; in unit Unit1.pas!! I tried also to get a TRttiType by calling rttiContext.GetType, but this causes a exception if I expect a PTypeInfo in the constructor of UsesBusinessAspectAttribute. QC Entry 82854

QC #: 82862 - Status: Closed

QC #: Project Date Reported: Area:82862 Delphi 3/10/2010 VCL\Additional Controls\TBitBtn

Description Steps:[QC Short Description] TBitBtn.NumGlyph behaviour: it seems a bug... [QC Description] In Delphi 2010 I found a strange behavior in setting the property NumGlyph of a TBitBtn: I put a TImagleList 16 x 48 with a 3 state bitmap 16 x 48 (normal, disabled and focused) and I link it to an ActionManager (I can see all bitmaps correctly). Then I link the Action to a TBitBtn and I see 3 bitmaps, so I set the property NumGlyph to the button and at Design Time I can see only 1 bitmap (correctly). If I run the program I see 3 bitmaps erroneously! With Delphi 2007 all is fine. It seem a bug because when you set a non standard value to a property in D2010 you?l see it in bold, setting the property NumGlyph to the value 3 does not change font style.. Besides all works fine if I set the property at runtime. QC Entry 82862

Start new project Add a Image list Set the property width to 48 Add a 16x48 bitmap into the image list Put an action manager or a action list in the form Link the action manager to the image list Create a new action and connect to the only one image (that has 3 states) Put a TBitbutton and link it to the action created ...You'll see 3 images Set the property NumGlyph of the button to 3 ...You'll see only 1 image (correct) Run the program: you'll see 3 bitmaps! (error) See attachement as a test project. Thanks, Thomas. Note: With the test project, I see 3 images both at runtime and design time.

QC #: 82907 - Status: Closed

QC #: Project Date Reported: Area:82907 Delphi 3/11/2010 AddOn\Interbase components Description Steps:[QC Short Description] D2010 - IBQuery Unsupported Feature [QC Description] When running a parameterized TIBQuery against a table with a field defined as an integer, an "Unsupported Feature" exception is thrown.QC Entry 82907

Setup a parameterized query with one of the parameters referencing an integer field: ibQry.SQL.Text := 'select * from Table where TranType=:TranType'; ...now set the parameter with .Value and Open it: ibQry.ParamByName('TranType').Value := 3; ibQry.Open(); The "Unsupported Feature" exception is thrown. A sample Delphi 2010 project and Interbase 7.5 DB is attached.

QC #: 82929 - Status: Closed

QC #: Project Date Reported: Area:82929 Delphi 3/12/2010 IDE\Refactoring\Change Parameters

Description Steps:[QC Short Description] Refactoring doesn't work [QC Description] Unable to refactor aArgument in sample code. unit Unit1; interface procedure Test(const aArgument: String); implementation procedure Test(const aArgument: String); begin if aArgument = '' then Exit; end; end. QC Entry 82929

CTRL + SHIFT + E on any aArgument - result changing only aAgrument inside procedure but doesn't change aArgument in procedure params.

QC #: 82940 - Status: Closed

QC #: Project Date Reported: Area:82940 Delphi 3/12/2010 VCL\Win 32 Controls\TListView

Description Steps:[QC Short Description] ListView.subitems.objects are reset to nil when viewstyle is changed [QC Description] Listview.viewstyle has change behavior in delphi 2009 and up. When viewstyle is changed all Items.SubItems.Objects is cleared (NIL). I have trace it down to the Recreatewnd call in TCustomListview.SetViewStyle that wasn't in delphi 2007 source. Added by Sysop <<<<<<<<<<< This issue might be related to QC#75180. >>>>>>>>>>> QC Entry 82940

unit mainform; interface uses Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms, Dialogs, StdCtrls, ComCtrls, ShellLink; type TForm10 = class(TForm) ListView1: TListView; Button1: TButton; Button2: TButton; Edit1: TEdit; Edit2: TEdit; StatusBar1: TStatusBar; Button3: TButton; procedure FormCreate(Sender: TObject); procedure Button2Click(Sender: TObject); procedure Button1Click(Sender: TObject); procedure ListView1SelectItem(Sender: TObject; Item: TListItem; Selected: Boolean); private { Private declarations } dummydata : Integer; public { Public declarations } end; var Form10: TForm10; implementation {$R *.dfm} procedure TForm10.Button1Click(Sender: TObject); VAR aItem : TListItem; begin aitem := ListView1.Items.Add; aitem.Caption := Edit1.Text; inc(dummyData); aitem.Data := Pointer(dummydata); aitem.SubItems.AddObject(Edit2.text, Pointer(dummydata)); aitem.SubItems.AddObject(intToStr(Dummydata),Pointer(dummydata)); end; procedure TForm10.Button2Click(Sender: TObject); begin Case Listview1.ViewStyle of vsIcon : Listview1.ViewStyle := vsList; vsList :

Listview1.ViewStyle := vsReport; vsReport: Listview1.ViewStyle := vsIcon; else Listview1.ViewStyle := vsIcon; end; end; procedure TForm10.FormCreate(Sender: TObject); VAR aCol : TListColumn; begin acol := Listview1.Columns.Add; acol.Caption := 'Name'; acol := Listview1.Columns.Add; acol.Caption := 'Type'; acol := Listview1.Columns.Add; acol.Caption := 'DummyData'; Dummydata := 0; end; procedure TForm10.ListView1SelectItem(Sender: TObject; Item: TListItem; Selected: Boolean); VAR s : String; begin s := ''; if Item <> NIL then BEGIN if Item.SubItems.Objects[0] <> NIL then S := S +'SubObj[0] is '+IntToStr(Integer(Item.SubItems.Objects[0])) ELSE S := S+ 'SubObj[0] is Nil'; if Item.SubItems.Objects[1] <> NIL then S := S +' - SubObj[1] is '+IntToStr(Integer(Item.SubItems.Objects[1])) ELSE S := S+ ' - SubObj[1] is Nil'; if Item.data <> NIL then S := S +' - Item.Data is '+IntToStr(Integer(Item.Data)) ELSE S := S+ ' - Item.Data is Nil'; END; StatusBar1.SimpleText := s; end; end.

QC #: 82954 - Status: Closed

QC #: Project Date Reported: Area: 82954 C++Builder 3/12/2010 Compiler\C++ Description Steps:[REGRESSION] [QC Short Description] compile error on legal codes [QC Description] these lines compile fine on any c++ compiler (even c++ builder 2009):struct toto { int i; } ; new (struct toto[5]); in bcb 2010 he shows E2293 ) expected new struct toto[5]; doesn't compile also. QC Entry 82954

bcc32 275495.cpp res: Embarcadero C++ 6.30 for Win32 Copyright (c) 1993-2010 Embarcadero Technologies, Inc. Preliminary version built Feb 2 2010 16:10:53 275495.cpp: Error E2293 275495.cpp 4: ) expected in function main() *** 1 errors in Compile *** exp: clean compile (compiles cleanly with como)

QC #: 83038 - Status: Closed

QC #: Project Date Reported: Area: 83038 Delphi 3/15/2010 RTL\Delphi\WinAPI Description Steps:[QC Short Description] Wrong function declarations in ShlObj.pas [QC Description] Several function declarations in ShlObj.pas are incorrect because object parameters are declared as var parameters when they shouldn't be. It causes an instant crash when trying to use them. For example, function SHDoDragDrop(hwnd: HWND; var pdata: IDataObject; var pdsrc: IDropSource; dwEffect: DWORD; var pdwEffect: DWORD): HResult; stdcall; should be function SHDoDragDrop(hwnd: HWND; pdata: IDataObject; pdsrc: IDropSource; dwEffect: DWORD; var pdwEffect: DWORD): HResult; stdcall;

Write an app that calls SHDoDragDrop or SHCreateDataObject.

Notice the removal of the var declarations from the object parameters. This is just one example. There are others in ShlObj.pas, probably most of the new ones declared as delayed that have object parameters. I tried SHCreateDataObject and it crashed too. QC Entry 83038

QC #: 83072 - Status: Closed

QC #: Project Date Reported: Area: 83072 Delphi 3/16/2010 Midas\TClientDataSet Description Steps:[QC Short Description] TClientDataSet Key Violation [QC Description] Added by Sysop <<<<<<<<<<<<<<<<<<< In attached project, 'PacketRecords' property of TClientDataSet is changed from -1(default) to 50. If I reset the property to -1(default), this issue does not occur. >>>>>>>>>>>>>>>>>>> Database = MySQL ApplicationServer : TSQLConnection, TSQLQuery & TDataSetProvider Client : TSQLConnection, TDSProviderConnection, TClientDataSet with packet records = 50 or some other value > 0 Very simple SQL : select * from POSTAL_CODES where NONACTIVECODE <= :NONACTIVECODE ParamByName('NONACTIVECODE').AsString := '0'; Client : After scrolling true dataset via a grid --> Key Violation when SQL is changed to (without parameters) select * from POSTAL_CODES where NONACTIVECODE <= '0' --> No problems --> Also no problems when packet records is set to -1 QC Entry 83072

TDBXFulcrumBugsSuite.Native.DB.Test.exe connection=mysqlconnection -s:TestRaid_275743

QC #: 83076 - Status: Closed

QC #: Project Date Reported: Area: 83076 Delphi 3/16/2010 Midas\TClientDataSet Description Steps:[QC Short Description] Incorrect resultset ParamByName [QC Description] Added by Sysop <<<<<<<<<<<<<<<<<<< In attached project, 'PacketRecords' property of TClientDataSet is changed from -1(default) to 50. If I reset the property to -1(default), this issue does not occur. >>>>>>>>>>>>>>>>>>> Database = MySQL

TDBXFulcrumBugsSuite.Native.DB.Test.exe connection=mysqlconnection -s:TestRaid_275742 -OR- save and open 275742.zip run follow instructions on form

ApplicationServer : TSQLConnection, TSQLQuery & TDataSetProvider Client : TSQLConnection, TDSProviderConnection, TClientDataSet with packet records = 50 or some other value > 0 a simple SQL-statement triggered by a TClientDataSet.DataRequest select A.* from REGIONS_DETAIL A where A.REGIONCODE = :REGIONCODE ParamByName('REGIONCODE').AsString:=RegionCode; using ParamByName, only first call executes correct all subsequent calls return same resultset as first call unregarded the value of the parameter without using ParamByName -> no problems, OK where A.REGIONCODE = QuotedStr(RegionCode); see attached zip-file for a sample project included is also an SQL-script to create the MySQL-table REGIONS_DETAIL QC Entry 83076

QC #: 83100 - Status: Closed

QC #: Project Date Reported: Area:83100 Delphi 3/17/2010 Documentation\Online Help Description Steps:[QC Short Description] Missing/inaccurate documentation for IBQuery.RecordCount property [QC Description] The property TIBQuery.RecordCount isn't documented and redirects to the TDataSet.RecordCount docs. In TIBQuery, reading RecordCount returns the number of records fetched from the database so far, which may not be what you are expecting. It would be nice if the behaviour was clarified in the docs. See this discussion for further information: https://forums.embarcadero.com/thread.jspa?threadID=34457&tstart=0QC Entry 83100

QC #: 83128 - Status: Closed

QC #: Project Date Reported: Area:83128 Delphi 3/18/2010 IDE\Packages\Installing Components

Description Steps:[QC Short Description] create and install new package throws a access violation under some circumstances [QC Description] Creating a new package and compile/install ends up in a beautiful "Access violation at address 22204C71 in module 'dotnetcoreide140.bpl'. Read of address 00000000". The created dproj file contains suspicious < {%s}>true</ {%s}> entry. Removing this line doesn't help. QC Entry 83128

- Create new package (File->New->Package) - in the BASE Build configuration, change [Delphi Compiler->Compiling->Debugging->Symbol reference info] to "Definitions Only" - try to Compile, Build or Install the package You can also change this option in the Default Base Build configuration to have some fun. It is _possible_ that some other options are also affected.

QC #: 83129 - Status: Closed

QC #: Project Date Reported: Area:83129 Delphi 3/18/2010 IDE\Project Management

Description Steps: [QC Short Description] Always asks "Save changes to project <MyProjectName>?"... [QC Description] If open any project with langauges added (through IDE menu Project->Languages->Add...) and then perform "Close All" immediately, the message "Save changes to project <MyProjectName>?" appears. I'm sure I do not change anything! And now image if there are many such projects in my project group with which I work daily. Right, this message appears as many as I have projects in my project group! Is it possible to overcome this annoying feature? QC Entry 83129

ITEW32Project.AddFile is called on opening the translation project, and seems to mark the project(s) modified. Here is a stack trace: coreide.DocModul.TDocModule.SetIsModified(True) coreide.DocModul.TDocModule.Modified coreide.ProjectModule.TBaseProject.Modified iteidew32.ITEW32Personality.TITEW32Project.AddFile('D:\documents\RAD Studio\Projects\bugs\276717\NLD\Unit1.dfm','W32Form') iteide.ITEBaseResDLLProject.TITEBaseResDLLProject.LoadFileList iteide.ITEBaseResDLLProject.TITEBaseResDLLProject.Create(???,???,'','ResourceDLL',Pointer($7EDEAA5C)as IXMLDocument) iteidew32.ITEW32Personality.TITEW32ProjectCreationTrait.OpenProject('D:\documents\RAD Studio\Projects\bugs\276717\NLD\Project1_NLD.bdsproj','','ResourceDLL',Pointer($7EDEAA5C) as IXMLDocument) coreide.ProjectFileUtils.LoadProjectFile('D:\documents\RAD Studio\Projects\bugs\276717\NLD\Project1_NLD.bdsproj','',nil,False) coreide.ProjectModule.TModuleHandler.FileOpen(-1,'D:\documents\RAD Studio\Projects\bugs\276717\NLD\Project1_NLD.bdsproj',False) coreide.DocModul.TFileOpenHandler.FileOpen(-1,'D:\documents\RAD Studio\Projects\bugs\276717\NLD\Project1_NLD.bdsproj',False,$7F2A8260) coreide.DocModul.TFilterList.OpenFile('D:\documents\RAD Studio\Projects\bugs\276717\NLD\Project1_NLD.bdsproj',False,$7F2A8260,-1) coreide.DocModul.CallDefaultOpenProc('D:\documents\RAD Studio\Projects\bugs\276717\NLD\Project1_NLD.bdsproj',False,$7F2A8260) coreide.ProjectGroup.TProjectGroup.MSBInitializeProjectGroup coreide.ProjectGroup.TProjectGroup.Create('D:\documents\RAD Studio\Projects\bugs\276717\ProjectGroup1.groupproj','',Pointer($7EDE9DFC) as IXMLDocument,True,Pointer($7F0F3B6C) as IMSProjectFile) coreide.ProjectGroup.LoadMSBProjectGroup('D:\documents\RAD Studio\Projects\bugs\276717\ProjectGroup1.groupproj') coreide.ProjectGroup.TMSBuildProjectGroupFileOpenHandler.FileOpen(-1,'D:\documents\RAD Studio\Projects\bugs\276717\ProjectGroup1.groupproj',True,nil) coreide.DocModul.TFilterList.OpenFile('D:\documents\RAD Studio\Projects\bugs\276717\ProjectGroup1.group

QC #: 83130 - Status: Closed

QC #: Project Date Reported: Area: 83130 Delphi 3/18/2010 Compiler\Delphi\Generics Description Steps:[QC Short Description] Using a Alias with Generic-Types causes compiler-Error [DCC Error] : E2037 Declaration of ...' differs from previous declaration [QC Description] If you are Using a Alias of a Generic-Type like TSomeSpecialListEntry = TPair<integer, string>; and use this Type as a Parameter in a procedure like procedure DoSomething(const p_Entry : TSomeSpecialListEntry); the compiler fails with a compiler-Error [DCC Error] : E2037 Declaration of ...' differs from previous declaration. QC Entry 83130

Compile the attached application below. See the following compile-time error representing failure. program BTS275581; {$APPTYPE CONSOLE} uses Generics.Collections; type TSomeSpecialListEntry = TPair<integer, string>; TSomeSpecialList = TDictionary<integer, string>; TSomeClass = class public procedure DoSomething(const p_Entry : TSomeSpecialListEntry); end;

procedure TSomeClass.DoSomething(const p_Entry: TSomeSpecialListEntry); begin end; begin WriteLn('PASS'); // PASS on compile // end.

QC #: 83161 - Status: Closed

QC #: Project Date Reported: Area: 83161 Delphi 3/19/2010 Internet\Indy Description Steps:[QC Short Description] TdFTP Tranfertype = ftbinary donot work [QC Description] A zipFile on a FTPServer. TdFTP.Tranfertype := ftBinary. !before connect! TdFTP.get(zipFile) :The File is corrumped Tdftp Version 10.5.5. The same code, the same file with Delphi2005 TdFTP Version 10.0.20 works well. Added by Sysop <<<<<<<<<<<<<<< Please see comments of QC for more detail. >>>>>>>>>>>>>>> QC Entry 83161

QC #: 83233 - Status: Closed

QC #: Project Date Reported: Area: 83233 Delphi 3/22/2010 RTL\Delphi\Other RTL Description Steps:[QC Short Description] TStopWatch record allows writing to IsHighResolution var [QC Description] In TStopWatch Record located in the unit Dignostics the field IsHighResolution is exposed in a way that it allows for reading and writing of the variable instead of being a read-only property. Changing the property while using the timer will produce erroneous results. This erroneous result is mainly because TickFrequency is assigned a value depending on the OSs ability to use high resolution timers. A better implementation would have been something like "property IsHighResolution: Int64 read GetIsHighResolution;". The proposed implementation would help avoid the timer report erroneous measurements by not allowing one to make improper changes to the IsHighResolution flag. QC Entry 83233

var stw: TStopWatch; begin stw := TStopwatch.Create; stw.IsHighResolution := False; stw.Start; //Do some work stw.Stop; // Use stw results end

QC #: 83256 - Status: Closed

QC #: Project Date Reported: Area: 83256 Delphi 3/23/2010 Compiler\Delphi\Generics Description Steps:[QC Short Description] Using Rtti on Generic-Parameter or Generic-Types results in wrong QualifiedName [QC Description] If you have a class like this defined in Unit1.pas TSomeClass = class public procedure SomeProcedure(const p_SomeParameter : TList<string>);end; and using Rtti line this rttiContext := TRttiContext.Create();; rttiType := rttiContext.GetType(TSomeClass); WriteLn(rttiType.QualifiedName); for rttiMethod in rttiType.GetMethods('SomeProcedure') do WriteLn(' ' + rttiMethod.Name); for rttiParameter in rttiMethod.GetParameters() do begin WriteLn(' Name: ' + rttiParameter.Name); WriteLn(' Type: ' + rttiParameter.ParamType.QualifiedName); WriteLn(' Base-Type: ' + rttiParameter.ParamType.BaseType.QualifiedName); end; you will have wrong QualifiedName outputs. QC Entry 83256

1. Unzip appended Zip-File 2. Compile Project-Group 3. Run Program --> You will see The Type of Parameter p_SomeParameter will have QualifiedName= Unit1.TList<System.String>. Even the baseclass of TList<> has a wrong QualifiedName=Unit1.TEnumerable<System.String>. In both cases Generics.Collections is expected. Is there any Workaround available?

QC #: 83348 - Status: Closed

QC #: Project Date Reported: Area:83348 Delphi 3/25/2010 Compiler\Delphi\RTTI\Custom attributes

Description Steps:[QC Short Description] Using TClass in a TCustomAttribute triggers a Internal Error: TI2288 [QC Description] QC Entry 83348

Create a new unit and enter the MyFieldName and ener the folowing code after the type definition. It will fail compiling with the cursor after the after TContactTest MyFieldName = class(TCustomAttribute) public constructor Create(AField: string; AConstraint: TClass); end; TContactTest = class private [MyFieldName('NAME', nil)] FName: string; public property Name: string read FName write FName; end; ^^^^ [DCC Fatal Error] Unit7.pas(69): F2084 Internal Error: TI2288

QC #: 83354 - Status: Closed

QC #: Project Date Reported: Area:

83354 Delphi 3/26/2010 Compiler\Delphi\Code Generation/Optimization

Description Steps:[QC Short Description] Open arrays in constructor - optimized code crashes [QC Description] See steps to reproduce. If you'll enable the optimization - the following code will crash in destructor:

Compile and run the attached application below. See a failure dialog at start-up indicating failure. (JJS: Also see the original attachment Project1 using VCL) {$O+}

type TMyClass = class constructor Create(ABuf: array of byte); end; constructor TMyClass.Create(ABuf: array of byte); begin end; procedure TForm1.FormCreate(Sender: TObject); var LMyObj: TMyClass; begin LMyObj := TMyClass.Create([]); LMyObj.Free; // <- crash here end; QC Entry 83354

program BTS275726; {$APPTYPE CONSOLE} type TMyClass = class constructor Create(ABuf: array of byte); end; constructor TMyClass.Create(ABuf: array of byte); begin end; procedure DoTest; var LMyObj: TMyClass; begin LMyObj := TMyClass.Create([]); LMyObj.Free; end; begin try DoTest; WriteLn('PASS'); except on E: TObject do WriteLn('FAIL - Exception (', E.ClassName, ')'); end; end.

QC #: 83355 - Status: Closed

QC #: Project Date Reported: Area:83355 C++Builder 3/26/2010 Compiler\Delphi\Header Generation

Description Steps:[QC Short Description] Generating wrong HPP for safecall functions [QC Description] If You are using safecall calling convention for read property function, the generated HPP file takes the original function name in place of the 'safecalled' one: False: __property System::WordBool Distinct[int Index] = {read=Get_Distinct, write=Set_Distinct}; Good: __property System::WordBool Distinct[int Index] = {read=_scw_Get_Distinct, write=Set_Distinct}; If You are including the generated HPP in a C++ unit, You get an error message from the compiler. The error is definitle in the HPP file. This problem is new: in 2009 does work correct. QC Entry 83355

Make delphi vcl package and add the attached pascal unit. In the generated unit1.hpp's public section is the error visible: inline System::WordBool _scw_Get_Distinct(int Index) { System::WordBool __r; HRESULT __hr = Get_Distinct(Index, __r); System::CheckSafecallResult(__hr); return __r; } __property System::WordBool Distinct[int Index] = {read=Get_Distinct, write=Set_Distinct}; The correct would be (in D2009 is yet correct): inline System::WordBool _scw_Get_Distinct(int Index) { System::WordBool __r; HRESULT __hr = Get_Distinct(Index, __r); System::CheckSafecallResult(__hr); return __r; } __property System::WordBool Distinct[int Index] = {read=_scw_Get_Distinct, write=Set_Distinct};

QC #: 83394 - Status: Closed

QC #: Project Date Reported: Area: 83394 Delphi 3/27/2010 Debugger\FPU

Description Steps:[QC Short Description] AV when copying value in FPU view [QC Description] When debugging an application in FPU view, and trying to copy a selected FPU, MMX or XMM register to the clipboard (Ctrl+C), this results in an Access Violation. QC Entry 83394

1) Debug any program stopped at a break-point and open FPU view. 2) Make sure FPU View is docked. 3) Click on an FPU or XMM register and press Ctrl+C. Expected: Value in register is copied to clipboard (this is the behaviour in CPU View) Actual: Access Violation

QC #: 83466 - Status: Closed

QC #: Project Date Reported: Area: 83466 Delphi 3/30/2010 RTL\Delphi\WinAPI Description Steps:[QC Short Description] HDROP is incorrectly declared in ShellAPI.pas [QC Description] HDROP is declared in ShellAPI.pas as: type HDROP = Longint; This is a signed integer. It is used in calls to DragQueryFile, DragQueryFinish and DragQueryPoint. The problem is that it is in fact a Windows handle and as such should be declared as an unsigned integer because this is the convention that Delphi has adopted (e.g. declaration of THandle). Now, most of the time this doesn't matter but it will if the HDROP value has its high order bit set. This typically happens in a 32 bit app running as LARGEADDRESSAWARE. And in order to make the problem manifest it is commonly neeeded to run with top-down memory allocation. When the high order bit is set there is a range error when calling any of the DragQueryXXXX functions because the value passed in as the HDROP parameter is typically the result of a call to IDataObject.GetData and is typed as HGlobal. I can work around this problem by using an explicit cast which bypassess type coercion but it really ought to be fixed in future releases. The fix is trivial: type HDROP = THandle; QC Entry 83466

As described above.

QC #: 83491 - Status: Closed

QC #: Project Date Reported: Area: 83491 Delphi 3/31/2010 Database\DBExpress Description Steps:[QC Short Description] Release dbexpress driver for Oracle 11g fails on Windows 7 QC Entry 83491

When closing your windows application that was using a dll which connect to a Oracle 11g by using dbexpress and dbxora.dll, realeasing the driverhandle causes an access violation. Problem is located in the function TDBXDynalinkDriver.Destroy, line "FMethodTable.FDBXBase_Close(FDriverHandle);"

[Workaround] -------------------------- destructor TDBXDynalinkDriver.Destroy; begin if FMethodTable <> nil then begin // todo -cwst : update 84 1L // try except added to resolve Access violoation on windows 7 in dbxora.dll for oracle try FMethodTable.FDBXBase_Close(FDriverHandle); except // do nothing end; end; FDriverHandle := nil; FreeAndNil(FMethodTable); inherited Destroy; end; --------------------------

QC #: 83534 - Status: Closed

QC #: Project Date Reported: Area: 83534 Delphi 4/1/2010 RTL\Delphi\WinAPI Description Steps:[QC Short Description] Incorrect definition IRelatedItem interface [QC Description] ShlObj.pas lines 7102-7106 IRelatedItem = interface(IUnknown) [SID_IRelatedItem] function GetItemIDList(out ppidl: ItemIDList): HRESULT; stdcall; function GetItem(out ppsi: IShellItem): HRESULT; stdcall; end; definition of GetItemIDList method is incorrect it should be function GetItemIDList(out ppidl: PItemIDList): HResult; stdcall; source: http://msdn.microsoft.com/en-us/library/bb761332%28v=VS.85%29.aspx QC Entry 83534

compare line 7104 in ShlObj.pas and definition in Windows SDK headers

QC #: 83560 - Status: Closed

QC #: Project Date Reported: Area: 83560 Delphi 4/2/2010 Compiler\Delphi\Generics Description Steps:[QC Short Description] F2084 Internal Error: URW1111 when using public nested generic class type in another unit [QC Description] Using a nested generic class type in a class in another unit leads to F2084 Internal Error: URW1111 error. -> see steps

- save the attached files from the subdir simplified or the files at the end of the steps - dcc32 -B QC83560.dpr expected: it compiles actual: QC83560Unit1.pas(18) Fatal: F2084 Internal Error: URW1111 It fails with -B and -M for the DPR and all options (-B, -M, no -B or -M) for the QC83560Unit1 PAS file. That means the other way round it does compile when using "dcc32 QC83560.dpr". //--- QC83560.dpr --- program QC83560; uses QC83560Unit1 in 'QC83560Unit1.pas', QC83560Unit2 in 'QC83560Unit2.pas'; begin WriteLn('PASS'); // on compile end. //--- QC83560Unit1.pas --- unit QC83560Unit1; interface

(USc: QC report has been completely reworked by me. The original report did only consist of a short description, an attachment and a workaround.) QC Entry 83560

uses QC83560Unit2; type TForm9 = class(TObject) private FRecs: TMyClass1.TMyRecords1; end; implementation end. //--- QC83560Unit2.pas --- unit QC83560Unit2; interface type TList<T> = class(TObject); TMyClass1 = class public type TMyRecords1 = TList<TObject>;// does work with "...= class(TList<TObject>);" end; implementation end.

QC #: 83563 - Status: Closed

QC #: Project Date Reported: Area: 83563 Delphi 4/2/2010 SOAP Description Steps:[QC Short Description] OPToSOAPDomConv.TSOAPDomConv mandatory fixes [QC Description] 1. TSOAPDomConv.InitObjectFromSOAP line#4469: if (L > 0) and ((PInteger(PChar(ArrayPtr)-8)^) > L) then Dec(PInteger(PByte(ArrayPtr)-8)^); must be fixed as: if (L > 0) and ((PInteger(PByte(ArrayPtr)-8)^) > L) then Dec(PInteger(PByte(ArrayPtr)-8)^); 2. TSOAPDomConv.FindPrefixForURI function TSOAPDomConv.FindPrefixForURI(RootNode, Node: IXMLNode; const URI: InvString; DeclIfNone: Boolean = False): InvString; var DeclNode: IXMLNode; begin DeclNode := Node.FindNamespaceDecl(URI); // incorrectly was RootNode! if DeclNode <> nil then Result := ExtractLocalName(DeclNode.NodeName); // this returns 'xmlns' if there was no prefix if (Result = '') and DeclIfNone then Result := AddNamespaceDecl(RootNode, URI); if Result = SXMLNS then Result := ''; end; QC Entry 83563

I'm working with Crystal Report Server. First I've imported wsdl and then tried to connect to the server. Nothing worked without fixes described above.

QC #: 83578 - Status: Closed

QC #: Project Date Reported: Area:83578 Delphi 4/4/2010 VCL\Core VCL Classes\TList Description Steps:[QC Short Description] TStringlist.Move destroys attached object if OwnsObject is true [QC Description] If the OwnsObjects property of a TStringlist is set to true TStringlist.Move will destroy the object attached to the moved item, leaving it with an invalid object reference. TStrings.Move executes the move by saving string and object for the item to move, then deleting the item and insterting it at the new position. However, TStringlist.Delete will destroy the object when OwnsObjects is true, so the saved reference becomes invalid.

Steps by USc: - save the attached file StringlistMoveBugAuto.dpr (it's a more automated regression testing friendly version of the original test case) - compile and execute StringlistMoveBugAuto expected: PASS actual: FAIL #1 FAIL - Exception Error ClassName=EInvalidPointer Message=Invalid pointer operation Original steps: Create a new console project and fill it in as: program StringlistMoveBug; {$APPTYPE CONSOLE} uses Classes, SysUtils; type TTestClass = class public constructor Create; destructor Destroy; override; end; constructor TTestClass.Create; begin inherited; WriteLn('TTestclass constructor called'); end; destructor TTestClass.Destroy; begin WriteLn('TTestClass destructor called.'); inherited; end; var Temp: TStringlist; begin try WriteLn('Creating

The sample project given in steps shows that the attached objects destructor is called when a Move is executed. QC Entry 83578

stringlist with OwnsObject = true...'); Temp:= TStringlist.Create; try Temp.OwnsObjects := true; WriteLn('Adding two objects...'); Temp.AddObject('Object 1', TTestclass.Create); Temp.AddObject('Object 2', TTestclass.Create); WriteLn('Moving objects 1 to position 0'); Temp.Move(1, 0); WriteLn('List will be destroyed now.'); finally Temp.Free; end; {finally} except on E: Exception do Writeln(E.ClassName, ': ', E.Message); end; Write('Hit Enter to close'); ReadLn; end. { Output observed: Creating stringlist with OwnsObject = true... Adding two objects... TTestclass constructor called TTestclass constructor called Moving objects 1 to position 0 TTestClass destructor called. List will be destroyed now. TTestClass destructor called. EInvalidPointer: Invalid pointer operation Hit Enter to close }

QC #: 83584 - Status: Closed

QC #: Project Date Reported: Area:83584 Delphi 4/4/2010 Compiler\Delphi\Anonymous Methods

Description Steps:[QC Short Description] URW1111 from a single line [QC Description] An anonymous function with an open array parameter of strings (and possibly other reference counted types) causes a compiler error when created and called at once. Whilst an extreme corner case - it did pop up when I was attempting to make a test case for report 82459 (not realising it had already been reported). QC Entry 83584

The following line: (procedure(A: array of string) begin end)(['test']); produces a URW1111 at the bottom the offending unit, yet appears to be syntactically valid. Notably, an array of Integer works fine. Steps by USc: - save the attached files or the files at the end of my steps - dcc32 -B QC83584.dpr expected: it compiles actual: QC83584Unit.pas(14) Fatal: F2084 Internal Error: URW1111 It fails with -B and -M for the DPR and all options (-B, -M, no -B or -M) for the PAS file. That means the other way round it does compile when using "dcc32 QC83584.dpr". //--- QC83584.dpr --- program QC83584; {$APPTYPE CONSOLE} uses QC83584Unit in 'QC83584Unit.pas'; begin WriteLn('PASS'); // on compile end. //--- QC83584Unit.pas --- unit QC83584Unit; interface implementation procedure TestOneliner; begin (procedure(A: array of string) begin end)(['test']); end; end.

QC #: 83601 - Status: Closed

QC #: Project Date Reported: Area: 83601 Delphi 4/5/2010 IDE\Code Editor\ Description Steps:[QC Short Description] Loading and saving of code formatting sets [QC Description] It would be nice if Delphi would allow me to save and load different code formattings sets. I can already foresee competitions on websites for the best code formatting sets. This would help the Delphi community to get the commonly most acclaimed code formatting sets.QC Entry 83601

It was already fixed in November in jira request RAD-3730. "Implement saving/restoring formatter options to/from file"

QC #: 83610 - Status: Closed

QC #: Project Date Reported: Area: 83610 Delphi 4/6/2010 Midas\TClientDataSet Description Steps:[QC Short Description] Unable to use TLargeint in Aggregate Field [QC Description] Unable to use a LargeInt in an Aggregate field

TDBXFulcrumBugsSuite.Native.DB.Test.exe connection=ibconnection -s:TestRaid_275839 -OR-

Get error type mismatch Will happen even in Delphi 7 QC Entry 83610 sum, min, max, avg have a problem.

procedure TForm1.Button1Click(Sender: TObject); var CDS: TClientDataSet; TA : TAggregateField; begin CDS := TClientDataSet.Create(nil); with CDS do begin AggregatesActive := True; FieldDefs.Add('Name', ftString, 40); FieldDefs.Add('id', ftInteger); /// FieldDefs.Add('PTime',ftLargeint); FieldDefs.Add('PTime',ftInteger); IndexDefs.Add('ClientDataSet1Index1', 'Name', []); IndexName := 'ClientDataSet1Index1'; end; TA := TAggregateField.Create(CDS); TA.FieldName := 'SumPTime'; TA.Expression := 'SUM(PTime)'; TA.IndexName := 'ClientDataSet1Index1'; TA.DataSet := CDS; CDS.CreateDataSet; end;

QC #: 83751 - Status: Closed

QC #: Project Date Reported: Area:83751 C++Builder 4/11/2010 Compiler\C++\Front End\Initialization

Description Steps:[QC Short Description] Value-initialization: arrays should have each element value-initialized [QC Description] Thanks for fixing issue 51854, "Value-initialization: POD struct should be zero-initialized", http://qc.embarcadero.com/wc/qcmain.aspx?d=51854 I can confirm that I'm no longer able reproduce the bug, using the latest version of your compiler (Embarcadero C++ 6.21, 2010). However, your compiler appears to have a similar problem with regard to built-in arrays. The C++ Standard (2003) says that to value-initialize an array means that each element is value-initialized ([dcl.init]). However, when I try to value-initialize an array, the compiler gives me a warning instead: "W8039 Constructor initializer list ignored". And when I do so for an array of integers, they remain uninitialized. (Or at least, they remain non-zero.) When I run the program presented in "Steps to Reproduce", it halts at the first assert, saying "Assertion failed: wrapper.data[0] == 0" Please fix it! QC Entry 83751

bcc32 275893.cpp 275893.exe echo %ERRORLEVEL% exp: 0 act: Assertion failed: wrapper.data[0] == 0, file 275893.cpp, line 11 Abnormal program termination returns 3

QC #: 83814 - Status: Closed

QC #: Project Date Reported: Area:83814 Delphi 4/13/2010 IDE\Code Editor\Help Insight Description Steps:[QC Short Description] Create a simple application and add module without form. unit

My comment does not appear in the Help Insight [QC Description] There is a module without form. It describes a class and record in the section Type. If you re not add the word type, then the Help Insigh not work. QC Entry 83814

UnitError; interface uses Windows; type TR = Record A: integer; B: Double; end; //type // If you delete or comment out this line, then the text does not appear in Help Insight ///<summary> /// Comment for TSomeClassType /// Text Text Text ///</summary> TSomeClassType = class(TObject) end; implementation end.

QC #: 83851 - Status: Closed

QC #: Project Date Reported: Area: 83851 C++Builder 4/14/2010 Compiler\C++\Back End

Description Steps:[QC Short Description] Value-initialized temporary triggers internal backend error C1798 [QC Description] In some cases, the creation of a temporary object causes a compiler crash: Embarcadero C++ 6.21 for Win32 [...] Internal backend error C1798 compiling c.cpp(12) *** 1 errors in Compile *** The temporary object should have been value-initialized, as it was created by doing T(). I encountered the crash when I tried to compile a test which verifies the implementation of value-initialization for an large number of types. The test is to be included with Boost version 1.44.0, but a preliminary version is already at https://svn.boost.org/svn/boost/trunk/libs/config/test/boost_no_com_value_init.ipp Attached code: class user_defined_destructor_holder { public: int i; ~user_defined_destructor_holder() {} }; int main() { return user_defined_destructor_holder().i; } QC Entry 83851

bcc32 -c qc83851

QC #: 83889 - Status: Closed

QC #: Project Date Reported: Area:83889 Delphi 4/15/2010 IDE\Code Editor\Help Insight Description Steps:[QC Short Description] Incorrect editor behavior when tooltip pops up while entering national characters [QC Description] Incorrect cursor moving/garbage data appear/hang/exception/crash when tooltip pops up (or should popup) because mouse cursor is over any class/method/var name, while entering national characters (cyrillic). Exception report is attached (has appeared once). QC Entry 83889

Begin to enter some national characters (but not inside a comment - a text must not be completed, and there shold be incorrect syntax at that moment). Then move mouse cursor anywhere where a tooltip should pop up. Now text caret moves a little (usually to the left). Now enter one more character - a dozen of garbare characters appers at cursor position, and then IDE can raise exception crash or hang. Steps by Iulian Chitan: 1. Open the attached project. 2. Open qARMImpl1 unit 3. Go to TqARM.qStart method, and on the first line after begin type there some national chars 4. Move the mouse over some lines below (to get the help insight to

pop up), but leave the caret at the curent position. 5. Enter one more national character Exp: the character is introduced Act: some bogus entries appears. (see attached screenshot)

QC #: 83925 - Status: Closed

QC #: Project Date Reported: Area:83925 Delphi 4/16/2010 VCL\Core VCL Classes\TFrame

Description Steps:[QC Short Description] AV when destroying a frame which contains focus [QC Description] When a TFrame descendant is destroyed, it refers to its scrollbar, which has already been destroyed: Forms.pas procedure TScrollingWinControl.ScrollInView(AControl: TControl);... if AControl = nil then Exit; Rect := AControl.ClientRect; Dec(Rect.Left, HorzScrollBar.Margin); //HorzScrollBar = nil ... The problem seems to be peculiar to RAD Studio 2010, as Delphi 7 works flawlessly in this situation. QC Entry 83925

Run the attached sample. 1) Click the button on the left. 2) Focus the editor on the frame. 3) Click the button again -> AV

QC #: 83954 - Status: Closed

QC #: Project Date Reported: Area: 83954 Delphi 4/17/2010 Database\DataSnap\Server Description Steps:[QC Short Description] Trying to access TDataSetProvider when Exported = False results in Access Violation [QC Description] If you try to access a TDataSetProvider that does not exist, an exception is raised with the message @SProviderNotExported. However, if you try to access a TDataSetProvider that does exist, yet Exported is set to False, then nil is returned, resulting in an Access Violation in the server. To be consistent, the exception should be raised rather than returning nil. QC Entry 83954

DataSnapRDM.native.db.test.exe connection=dstcp_win32 -s:TestRaid_276051 -OR- Create a basic DataSnap server (either DCOM or DBX). Add a database connection, a data set, and a TDataSetProvider for the data set. Set the TDataSetProvider's Exported property to False. Build the server. Register the server. Run the server. Create a basic DataSnap client. Add a TDCOMConnection (for DCOM) or a TSQLConnection (for DBX). Configure the connection. Add a TDSProviderConnection if using DBX DataSnap. Configure the TDSPProviderConnection. Add a TClientDataSet. Set the RemoteServer and ProviderName properties. Now open the client data set. The server will throw an Access Violation. Added by Sysop <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< In fact the only thing wrong, is that the Exit statement should be replaced by a Break statement:

Result := nil; for i := 0 to FProviders.Count - 1 do if AnsiCompareStr(TCustomProvider(FProviders[i]).Name, ProviderName) = 0 then begin Result := TCustomProvider(FProviders[i]); if not Result.Exported then Result := nil; Exit; <<-- Change this in a Break, allowing the exception to be raised at the end. end; if not Assigned(Result) then raise Exception.CreateResFmt(@SProviderNotExported, [ProviderName]); >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>

QC #: 84002 - Status: Closed

QC #: Project Date Reported: Area:84002 Delphi 4/20/2010 VCL\Win 32 Controls\TToolBar

Description Steps:[QC Short Description] ToolButton caption disappears in TToolbar [QC Description] In a form with a TToolbar with 10 TToolButtons, captions of TToolbuttons disappear after modifications (> 300 modifications) of caption. Added by Sysop <<<<<<<<<<<<< This issue occurs with Delphi 2009, 2010. Please see comments of QC for more information. >>>>>>>>>>>>> QC Entry 84002

- Create a form, - Put a TToolbar with 10 TToolButtons - Put a TButton and copy this procedure : procedure TForm3.Button1Click(Sender: TObject); Var i,j : integer; begin for I := 0 to 400 do begin With Toolbar do begin for j := 0 to 9 do begin Buttons[j].Caption:='test AAA'; end; Application.ProcessMessages; sleep(30); for j := 0 to 9 do begin Buttons[j].Caption:='B test CCC'; end; Application.ProcessMessages; sleep(30); end; end; showmessage(Toolbar.Buttons[0].Caption); end; - Run - Click on Button1 => when i > 300, captions disappear (but ToolBar.Buttons[0].Caption = 'B test CCC' )

QC #: 84105 - Status: Closed

QC #: Project Date Reported: Area:84105 Delphi 4/23/2010 RTL\Delphi\WinAPI Description Steps:[QC Short Description] Wrong type declaration in _OUTLINETEXTMETRICW [QC Description] The record _OUTLINETEXTMETRICW defined in the windows unit contains 4 pointers at the end pointing to strings: _OUTLINETEXTMETRICW = record otmSize: UINT; [...] otmpFamilyName: PAnsiChar; otmpFaceName: PAnsiChar; otmpStyleName: PAnsiChar; otmpFullName: PAnsiChar; end; These are relative pointers to the start of the record and not typical PChar pointers, so the use might be irritating. BUT at least they

A tool utilising this command can be found in the PascalType open source project (see http://pascaltype.svn.sourceforge.net/viewvc/pascaltype/Examples/GDI%20call%20comparison/).

are unicode strings and thus they should better read PWideChar rather than PAnsiChar (for this _OUTLINETEXTMETRICW record). Please change the PAnsiChar to PWideChar or change them to Pointer. This would make it more clear that they are not to be used as typical PWideChars. QC Entry 84105

QC #: 84129 - Status: Closed

QC #: Project Date Reported: Area: 84129 Delphi 4/25/2010 Database\DBExpress Description Steps:[QC Short Description] SortFieldNames property of TCustomSQLDataSet is ignored [QC Description] Due to bug in 'SqlExpr.pas', SortFieldNames property of TCustomSQLDataSet is ignored. begin/end are missing. Please see steps. QC Entry 84129

TDBXFulcrumBugsSuite.Native.DB.Test.exe connection=ibconnection -s:TestRaid_276141 -OR- Due to bug in 'SqlExpr.pas', SortFieldNames property of TCustomSQLDataSet is ignored. begin/end are missing. So, we need to modify GetQueryFromType method as below -------------------------------------- function TCustomSQLDataSet.GetQueryFromType: UnicodeString; var STableName : String; begin case CommandType of ctTable: begin if FSortFieldNames > '' then begin ... ... end else begin // begin is added if FNativeCommand = '' then ... ... Result := SSelectStarFrom + STableName end; // end; is added end; -------------------------------------- instead of -------------------------------------- function TCustomSQLDataSet.GetQueryFromType: UnicodeString; var STableName : String; begin case CommandType of ctTable: begin if FSortFieldNames > '' then begin ... ... end else if FNativeCommand = '' then ... ... Result := SSelectStarFrom + STableName end; --------------------------------------

QC #: 84173 - Status: Closed

QC #: Project Date Reported: Area:84173 Delphi 4/27/2010 IDE\Code Editor\Formatting Description Steps:[QC Short Description] Unwanted space inserted after '=' [QC Description] With "Set spacing around binary operators" set to "None" or "As is" an unwanted space is inserted after the "=" in recod and class declarations. QC Entry 84173

Before formatting: type TA=Integer; TB=(ttNone); TC=record end; TD=class end; After formatting: type TA=Integer; // OK. TB=(ttNone); // OK. TC= record // Wrong - contains unwanted space after "=". end; TD= class // Wrong - contains unwanted space after "=". end; ML: Note: problem is disappeared if set 'Resolve space conflicts' option from default 'Space' value to 'AsIs' or 'No space'.

QC #: 84241 - Status: Closed

QC #: Project Date Reported: Area:84241 Delphi 4/30/2010 IDE\Multi-Monitor Support Description Steps:[QC Short Description] View List displayed at an illegal position when the multi monitor is used. [QC Description] View List displayed at an illegal position when the multi monitor is used. QC Entry 84241

1.Code editor is stepped over to Monitor #1 and #2. 2.Press "Select View" button. EXP: The list is displayed under the button. ACT: The list is displayed Primary monitor. (To X position of monitor #2) Please see Attachments.

QC #: 84245 - Status: Closed

QC #: Project Date Reported: Area: 84245 C++Builder 4/30/2010 Linker\ILINK32\Packages Description Steps:[QC Short Description] ILINK32 cannot find Generics.Collections [QC Description]

1. Create a package 2. Add a Delphi unit which uses "Generics.Collections" 3. Create an application 4. (Try to) link against the package

Given a C++ package which contains a Delphi unit that uses Generics.Collections, ILINK32 cannot link against the generated package import library. The resulting error message is [ILINK32 Error] Fatal: Unable to open file 'GENERICS.COLLECTIONS' Attached is a project group with a package and an application which shows that behaviour. QC Entry 84245 [FT] [top10]

QC #: 84269 - Status: Closed

QC #: Project Date Reported: Area:84269 Delphi 5/1/2010 VCL\Win 32 Controls\TTreeView

Description Steps:[QC Short Description] TTreeView.SaveToStream memory leak [QC Description] variable NodeStr: TStringBuilder is created in procedure TTreeStrings.SaveTreeToStream but it is not released QC Entry 84269

QC #: 84290 - Status: Closed

QC #: Project Date Reported: Area: 84290 C++Builder 5/3/2010 IDE\Background compile Description Steps:[QC Short Description] "Build all projects" doesn't work in project group with resource projects when using Background compilation QC Entry 84290

- Start C++Builder 2010 - Enable background compilation (Tools / Options / Environment Options / Compiling / Background Compilation) - File > Close All to be sure to start from a clean slate - File > New > VCL Forms Application - C++ Builder - File > Save All (save e.g. in C:\foo with all the default names) - Run > Run (so far, everything works) - Project > Build All Projects (works: build output appears at the bottom of the screen, executable is written to Debug subfolder) - File > New > Other; choose Resource DLL Wizard - Next - Change Base Language to $00000809 (English UK); Next - Add 3 languages: German (Germany), French (France), Dutch (Netherlands); Next - Next - No need to add extra files; Next - Next - Finish - "The DRC file is not found. Recompile project to generate?" -> Yes - OK - In the project manager, the project group now includes the original project + the 3 resource projects (so that looks good) - File > Save All; save project group with default name - Make sure Project1.exe is the active project in the project group - Project > Build All Projects. Expected: All projects, i.e. exe and resource dlls, are built. What actually happens: nothing. Output window is empty. No new files are written.

QC #: 84493 - Status: Closed

QC #: Project Date Reported: Area:84493 Delphi 5/10/2010 IDE\Code Editor\Formatting Description Steps:[QC Short Description] This declaration: var ProcA: function: integer; stdcall; ProcB: function:

Bad formatting of method variables [QC Description] Adding a calling convention to a declaration causes mis-formatting. QC Entry 84493

integer; stdcall; GetErrorStr : function: PChar; stdcall; is formatted like this var ProcA: function: integer; stdcall; ProcB : function: integer; stdcall; GetErrorStr : function: PChar; stdcall;

QC #: 84507 - Status: Closed

QC #: Project Date Reported: Area:84507 Delphi 5/10/2010 IDE\Code Editor\Formatting Description Steps:[QC Short Description] Ability to Completely Disable automatic code formatting [QC Description] Please introduce the ability to disable Control-D code formatter in the Delphi IDE. Despite the claim that it makes code easier to read, the automatic code formatter can make thousands of lines of neatly formatted code unreadable in an instant. Control-D key is dangerously close to the often used Control-F, Control-X and Control-C keys, and gets pressed accidentally. If the inadvertent keystroke is not picked up immediately, the users preference for code formatting is wrecked. Additionally, the user defined options are not correctly followed by the formatter - see Steps to Reproduce. QC Entry 84507

The users preferences are not followed. Tools > Options > Formatter > Delphi > Spaces > Set Spacing for colons : "As Is" changes this clear layout: FirstInTime : TDateTime; {first time stamp of recorded data for this detection} RecAtTime : TDateTime; {last available bus update for this detector} ValidUntilTime : TDateTime; {last available bus update for this detector} InDetectionTime : TDateTime; {difference between InTime and RecAtTime - how long the vehicle has been inside the detector} TimeEnteredStop : TDateTime; Into this: FirstInTime : TDateTime; {first time stamp of recorded data for this detection} RecAtTime : TDateTime; {last available bus update for this detector} ValidUntilTime : TDateTime; {last available bus update for this detector} InDetectionTime : TDateTime; {difference between InTime and RecAtTime - how long the vehicle has been inside the detector} TimeEnteredStop : TDateTime; That's certainly not "As Is" It's also in my view, far less readable. Please make the feature option definable by the user, and / or provide an 'Are you really sure you want this?' confirmation dialog.

QC #: 84514 - Status: Closed

QC #: Project Date Reported: Area:84514 Delphi 5/10/2010 IDE\Dialogs\Environment Options

Description Steps:[QC Short Description] Path for translation repository (.tmx) is not stored [QC Description] Path for translation repository (.tmx) is not stored. With regedit.exe, we can confirm that registory data is not saved property... Intead, ETM(etm.exe) stored the information correctly. QC Entry 84514

1) start IDE on Windows 7 2) Tool | Options 3) change path(.tmx) for translation repository 4) press [OK] and close option dialog 5) reconfirm Tool | Options setting 6) path is not persisted.

QC #: 84520 - Status: Closed

QC #: Project Date Reported: Area: 84520 Delphi 5/11/2010 Debugger Description Steps:[QC Short Description] Debugger visualizers are very slow! [QC Description] Hi! In order to make use of debugger visualizers, the plugin has to depend upon a function:

Steps by USc: - save the attachment - install DebuggerEvaluationSpeedTestPackage.dpk - open DebuggerEvaluationSpeedTestApp.dpr - put a breakpoint into it and run it (the test needs an active IOTAProcess + IOTAThread and also EncodeDateTime linked into the app) - Help | Debugger Evaluation Speed Test - press the "Test" button and wait till the test is finished (may take up to 30 seconds) and have a look at the result expected: the evaluation with ProcessDebugEvents is at least as fast as with

IOTADebuggerServices.ProcessDebugEvents when evaluating deffered expressions. This approach results in very slow debug step times when using value replacement visualizer and when there are many locals declared in the functions. They will make use of the debugger value replacement plug-in automatically to populate the "locals" debugger window. A part from the fact the function is between 6-10x slower than the approach using Application.ProcessMessages, it effectively prevents widespread use of debugger visualizer features because it can easily bring the debugging process to its knees in terms of stepping speed. The function would have to be speeded up about 50-100x times to allow for widespread adoption of the new debugger features. (or a completely new approach to debugger expression evaluation should be made available). Thanks! Atmapuri QC Entry 84520

ProcessMessages (>= 33 evaluations per second on an 2.1 GHz Core2) actually it should be also faster than the current speed with ProcessMessages to avoid slowing down stepping too much actual: ProcessDebugEvents is 6.6 times slower than ProcessMessages (5 evaluations per second on an 2.1 GHz Core2)

QC #: 84541 - Status: Closed

QC #: Project Date Reported: Area: 84541 Delphi 5/11/2010 International Description Steps:[QC Short Description] TClientDataset.Locate fails on Boolean fields [QC Description] Like the title says, TClientDataset.Locate fails on Boolean fields when the french localization resources are loaded. (Probably others too) Here's a summary of what works and what won't... procedure TForm1.Button1Click(Sender: TObject); begin cds.Locate('F1;F2;F3',VarArrayOf([1, 'ED', 'Faux']),[]); //Succeed end; procedure TForm1.Button2Click(Sender: TObject); begin cds.Locate('F1;F2;F3',VarArrayOf([1, 'ED', 'False']),[]); //Fails end; procedure TForm1.Button3Click(Sender: TObject); begin cds.Locate('F1;F2;F3',VarArrayOf([1, 'ED', False]),[]); //Fails end; procedure TForm1.Button4Click(Sender: TObject); begin cds.Locate('F1;F2;F3',VarArrayOf([1, 'ED', 0]),[]); //Succeed end; This is probably a duplicate of QC29760... But didn't mention localization resources. EDIT 2010-05-13 Ok, here's the call stack... Kernel32.RaiseException DatabaseError

Run the attached project with the French localization resources (*.fr files)

DatabaseErrorFmt TDataset.FieldByName TFilterExpr.GetFieldByName TFilterExpr.NewNode TExprParser.ParseExpr7 TExprParser.ParseExpr6 [...] TExprParser.ParseExpr2 TExprParser.ParseExpr TExprParser.SetExprParams TExprParser.Create TCustomClientDataset.LocateRecord [...] I noted that in TExprParser.ParseExpr7, the TokenSymbolIs(FStrTrue/FStrFalse) both return FALSE. Those 2 fields are initialized with constant from DBConsts and both seems to be localized. Which means that TExprParser expect boolean strings to be "Vrai/Faux" with the french resource. In TCustomClientDataset.LocateRecord, the boolean values contained in the KeyValues parameter are converted like this: ValStr := VarToStr(Value); which maps ultimately to _VarToUStr. and then to BoolToWStrViaOS. I tested the BoolToWStrViaOS, and it returns "True/False" even if the language of my OS is french and the *.fr resource are loaded. So the problem I encountered is: The TCustomClientDataset.LocateRecord function use the "True/False" string to format the filter expression, but the TExprParser only consider "Vrai/Faux" to be valid boolean strings. Note : GetThreadLocale, GetUserDefaultLCID and GetSystemDefaultLCID all return the same value ($0C0C) QC Entry 84541

QC #: 84542 - Status: Closed

QC #: Project Date Reported: Area: 84542 Delphi 5/11/2010 Compiler\Delphi Description Steps:[QC Short Description] Regression: F2084 Internal Error: I12607 [QC Description] MoveChars leads to F2084 Internal Error: I12607 in some situations since D2009 Update 3. (it works in D2009 RTM and Update 1) -> see steps QC Entry 84542

Steps by USc: - save the following code as QC84542Simplified.dpr - dcc32 QC84542Simplified.dpr expected: it compiles actual: D2010 U#4: QC84542Simplified.dpr(13) Fatal: F2084 Internal Error: I12607 D2009 U#3: QC84542Simplified.dpr(13) Fatal: F2084 Internal Error: I12229 D2009 U#1: it compiles program QC84542Simplified; {$APPTYPE CONSOLE} var Source: string; Dest: array [0..119] of Char; begin Source := '0123456789qwertzuiop'; //System.MoveChars(Source[2], Dest, SizeOf(Dest)); // works fine System.MoveChars(Source[1], Dest, SizeOf(Dest)); // internal Error I12607 WriteLn('PASS'); // on compile end. Original Steps: program Project1; type TRecStruc = record A: array[1..3] of Char; B: array[4..6] of Char; C: array[7..10] of Char; Alpha: array[11..120] of Char; end; var sx: string; rStruc: TRecStruc; begin sx := '0123456789qwertzuiop'; // System.MoveChars(sx[2], rStruc.Alpha, SizeOf(rStruc.Alpha)); // works fine System.MoveChars(sx[1], rStruc.Alpha, SizeOf(rStruc.Alpha)); // internal Error I12607 end.

QC #: 84552 - Status: Closed

QC #: Project Date Reported: Area:

84552 Delphi 5/12/2010 Database\DataSnap Description Steps:[QC Short Description] negative datetime fails in datasnap call [QC Description] Datasnap send a datetime as unixtimestamp to the server. In the function GetTimeStamp in DBXStreamPlatform.pas isnot correct interpretation of the unix timestamp when it is a negative value. QC Entry 84552

DataSnapAccess.native.db.test.exe connection=ibconnection server=dstcp_win32 -s:TestComponentParameter_TDateTimeNeg Create a datasnap client/server application. Implements at the server app: functie EchoString(aTS: TDateTime):String begin Result := DateTimeToStr(aTS); end; Call the servermethode from the client using datasnap. When local time zone = +1 then 0 and all negative time values went wrong. (only -1,0416667 goes correct, because time-part will become zero)

QC #: 84657 - Status: Closed

QC #: Project Date Reported: Area:

84657 Delphi 5/16/2010 Compiler\Delphi\Anonymous Methods

Description Steps:[QC Short Description] E2003 Undeclared identifier: '$0$Body' with overloaded parameterized methods creating anon methods [QC Description] A class with overloaded parameterized methods that create anonymous methods lead to the error E2003 Undeclared identifier: '$0$Body'. -> see steps This has been reported in embarcadero.public.delphi.language.delphi.win32 in the thread "E2003 Undeclared identifier: '$0$Body'". https://forums.embarcadero.com/thread.jspa?messageID=239679&tstart=0#239679QC Entry 84657

- save the attachment or the following files - dcc32 AnonMethodOverloadedClassFuncTest.dpr expected: it compiles actual: AnonMethodOverloadedClassFuncTest.dpr(10) Error: E2003 Undeclared identifier: '$0$Body' On Fulcrum: Internal error G5059 Additional notes: - the actual types for the parameterized methods does not matter - the static directive is not relevant for the issue - the TFunc definitions have only been added to avoid a SysUtils dependency - the issue does not occur when the stuff from the unit is part of the DPR source //--- AnonMethodOverloadedClassFuncTest.dpr --- program AnonMethodOverloadedClassFuncTest; {$APPTYPE CONSOLE} uses uEStaticTeste; begin TEStatic.Func<Integer, Integer, string>()(2, 4); TEStatic.Func<Integer, Boolean>()(2); WriteLn('PASS'); // on compile end. //--- uEStaticTeste.pas --- unit uEStaticTeste; interface //SysUtils.pas type TFunc<T,TResult> = reference to function (Arg1: T): TResult; TFunc<T1,T2,TResult> = reference to function (Arg1: T1; Arg2: T2): TResult; type

TEStatic = class public class function Func<T1, TResult>: TFunc<T1, TResult>; overload; static; class function Func<T1, T2, TResult>: TFunc<T1, T2, TResult>; overload; static; end; implementation class function TEStatic.Func<T1, TResult>: TFunc<T1, TResult>; begin Result := function(prTeste: T1): TResult begin end; end; class function TEStatic.Func<T1, T2, TResult>: TFunc<T1, T2, TResult>; begin Result := function(arg1: T1; arg2: T2): TResult begin end; end; end.

QC #: 84688 - Status: Closed

QC #: Project Date Reported: Area: 84688 Delphi 5/17/2010 Compiler\Delphi\Generics Description Steps:[QC Short Description] inherited protected methods are not visible [QC Description] The following code is not compiling, see steps. QC Entry 84688

program Project7; {$APPTYPE CONSOLE} uses SysUtils; type TMyClass1 = class(TInterfacedObject) end; TMyClass2<T> = class(TInterfacedObject) end; TMyClass3<TItem : TMyClass2<integer>, constructor; T> = class procedure Error; end; procedure TMyClass3<TItem, T>.Error; var wItem : TItem; begin wItem:= TItem.Create; wItem._AddRef; // <-- Error here: E2362 Cannot access protected symbol TInterfacedObject._AddRef end; var wO1 : TMyClass1; wO2 : TMyClass2<integer>; begin try wO1:= TMyClass1.Create; wO1._AddRef; // <-- No problem here wO2:= TMyClass2<integer>.Create; wO2._AddRef; // <-- No problem here except on E: Exception do Writeln(E.ClassName, ': ', E.Message); end; end.

QC #: 84763 - Status: Closed

QC #: Project Date Reported: Area:84763 Delphi 5/19/2010 VCL\Standard Controls\TLabel

Description Steps:[QC Short Description] TLabel component is incorrectly painted on Windows 7 [QC Description] see attached image. procedure TForm1.Button2Click(Sender: TObject); var ABitmap: TBitmap; begin ABitmap := TBitmap.Create; ABitmap.SetSize(Panel1.Width, Panel1.Height);

1) Run the attached sample. 2) Click the button -> The label, residing on the left panel, is painted wrong on the right PaintBox.

ABitmap.PixelFormat := pf32bit; Panel1.PaintTo(ABitmap.Canvas, 0,0); PaintBox1.Canvas.Draw(0, 0, ABitmap); ABitmap.free; end; QC Entry 84763 I cannot reproduce this problem with the attached project on Windows 7. The attached project has a 0 bytes unit. I recreated the unit by hand.

QC #: 84797 - Status: Closed

QC #: Project Date Reported: Area: 84797 Delphi 5/20/2010 SOAP Description Steps:[QC Short Description] Fatal memory address calculation error/misspell [QC Description] see unit OPToSOAPDomConv.pas TSOAPDomConv.InitObjectFromSOAP line#4469: if (L > 0) and ((PInteger(PChar(ArrayPtr)-8)^) > L) then Dec(PInteger(PByte(ArrayPtr)-8)^); must be fixed as: if (L > 0) and ((PInteger(PByte(ArrayPtr)-8)^) > L) then Dec(PInteger(PByte(ArrayPtr)-8)^); QC Entry 84797

QC #: 84813 - Status: Closed

QC #: Project Date Reported: Area: 84813 Delphi 5/21/2010 Midas\TClientDataSet Description Steps:[QC Short Description] Filtering with shortint- or byte-fields give "Type mismatch" QC Entry 84813

TDBXFulcrumBugsSuite.Native.DB.Test.exe connection=ibconnection -s:TestRaid_276795 -OR- The following code gives exception "Type mismatch in expression" on each filter: var cds: TClientDataset; begin cds := TClientDataset.Create(nil); try cds.FieldDefs.Add('nrShort', ftShortint); cds.FieldDefs.Add('nrByte', ftByte); cds.CreateDataSet; cds.Filtered := True; try cds.Filter := 'nrShort=2'; except end; try cds.Filter := 'nrByte=2'; except end; finally

cds.Free; end; end;

QC #: 84821 - Status: Resolved

QC #: Project Date Reported: Area: 84821 Delphi 5/21/2010 SOAP Description Steps:[QC Short Description] TSOAPDomConv.FindPrefixForURI implemented incorrectly [QC Description] unit OPToSOAPDomConv Current implementation: function TSOAPDomConv.FindPrefixForURI(RootNode, Node: IXMLNode; const URI: InvString; DeclIfNone: Boolean = False): InvString; var DeclNode: IXMLNode; begin DeclNode := RootNode.FindNamespaceDecl(URI); if DeclNode <> nil then Result := ExtractLocalName(DeclNode.NodeName); if (Result = '') and DeclIfNone then Result := AddNamespaceDecl(RootNode, URI); end; Must be replaced by: function TSOAPDomConv.FindPrefixForURI(RootNode, Node: IXMLNode; const URI: InvString; DeclIfNone: Boolean = False): InvString; var DeclNode: IXMLNode; begin DeclNode := Node.FindNamespaceDecl(URI); if DeclNode = nil then DeclNode := RootNode.FindNamespaceDecl(URI); if DeclNode <> nil then Result := ExtractLocalName(DeclNode.NodeName); // VX this returns 'xmlns' if there was no prefix if (Result = '') and DeclIfNone then Result := AddNamespaceDecl(RootNode, URI); if Result = SXMLNS then Result := ''; end; QC Entry 84821

Generate wsdl and try to connect Crystal Report Server. Nothing is working without this fix.

QC #: 84913 - Status: Closed

QC #: Project Date Reported: Area: 84913 Delphi 5/26/2010 Database\DataSnap\Server Description Steps:[QC Short Description] IAppServer not exposed when Invocation Lifecycle is used [QC Description] D2009 exposed IAppServer methods when the server class's Lifecycle was set to Invocation. D2010 does not. Whether the class needs to expose IAppServer methods is determined

DataSnapDM.Native.Db.Test.exe connection=mssqlconnection server=dstcp_win32 -s:TestRaid_278935 -OR- Create a new DataSnap server in D2010. On the TDSServerClass component, set LifeCycle to Invocation. On the TDSServerModule, drop a data set and a TDataSetProvider component. Setup the data set

and this value is saved to "IsAdapted". If IsAdapted is True, then the server class is wrapped with TDSProviderDataModuleAdapter, which exposes the IAppServer methods. D2009 determined IsAdapted using this logic: D2009: DSServer.pas: function TDSServerClass.GetDSClass: TDSClass; Line 563: IsAdapted := PersistentClass.InheritsFrom(TProviderDataModule); D2010 adds a check to determine if Lifecycle is set to Invocation: D2010: DSServer.pas: function TDSServerClass.GetDSClass: TDSClass; Line 571: IsAdapted := PersistentClass.InheritsFrom(TProviderDataModule) and (LifeCycle <> TDSLifeCycle.Invocation); I've researched this and I can't find any reason that IAppServer methods will not work with Invocation Lifecycle. An instance created is not freed immediately after the AS_GetRecords call is completed. However, this because DataSnap has code that determines the instance is not ready to be freed yet. When the next server call is made, it is determined that the previous instance still exists, so that instance is freed and another instance is created. The net result is that each server call results in a new instance of the server class and that a single connection only has one instance of the server class at any given time. There are two side effects that may be undesirable: 1. The server class instance is not freed when the programmer expects.2. Once a connection makes a server call, there is always a service class allocated, even though it will be freed with the next server call. However, the solution to these two side effects is not to disable the IAppServer methods when Invocation Lifecycle is used. Please restore the ability to use IAppServer (and thus TDataSetProvider) when Invocation Lifecycle is used. Thread discussions on this issue: https://forums.embarcadero.com/thread.jspa?threadID=27205 https://forums.embarcadero.com/thread.jspa?messageID=243795 QC Entry 84913

to retrieve data from a database and connect the data set provider to the data set. Create a new DataSet client in D2010. On the main form: Drop a TSQLConnection. Set the Driver property to DataSnap. Drop a TDSProviderConnection. Set the SQLConnection property. Enter the ServerClassName of the server class. Drop a TClientDataSet. Set the RemoteServer property to the name of the TDSProviderConnection. Set the ProviderName property to the name of the TDataSetProvider on the server module. Add a button with an OnClick event that calls the Open method of the TClientDataSet. Run the server. Run the client. Click the button to open the data set. Expected: No error. Actual: Error about AS_GetRecords method not found.

QC #: 84930 - Status: Closed

QC #: Project Date Reported: Area: 84930 Delphi 5/27/2010 Debugger Description Steps:[QC Short Description] Generics + Nested Classes = AV or Debugger Fault Notification [QC Description] When you use Generic class with nested class and breakpoints; IDE will be stop with an AV. QC Entry 84930

For Example: program Project5; {$APPTYPE CONSOLE} uses SysUtils, Generics.Defaults, Generics.Collections; type TPerson<T> = class

private fName : String; type TPersonDetail = class end; private fSurName : String; end; begin try WriteLn('Test');//Please use breakpoint here! ReadLn; except on E: Exception do Writeln(E.ClassName, ': ', E.Message); end; end. The following came from the "workarounds" tab of the QC report: Scenarios -------------- 1) It's OK without Generics with breakpoints!! TPerson = class private fName : String; type TPersonDetail = class end; private fSurName : String; end; --------------------------------------------- 2) It's OK with Generics without breakpoints.!! (You cant use any breakpoint at your code. If you use breakpoint you will get an exception.) TPerson<T> = class private fName : String; type TPersonDetail = class end; private fSurName : String; end; ----------------------------------------------- 3) It's OK with Generics and breakpoints.!! (Removed TPersonDetail dummy class) TPerson<T> = class private fName : String; fSurName : String; end;

QC #: 84996 - Status: Closed

QC #: Project Date Reported: Area:84996 Delphi 5/29/2010 IDE\Code Editor\Help Insight Description Steps:[QC Short Description] Help Insight won't work if there are more than one REGIONs in the code.

1. Open the attached project 2. Open the Unit1.pas Move the mouse to TSample4 class. Help Insight should show its summary but it doesn't.

[QC Description] see steps QC Entry 84996

QC #: 85133 - Status: Closed

QC #: Project Date Reported: Area:85133 Delphi 6/4/2010 VCL\Win 32 Controls\TListView

Description Steps:[QC Short Description] TListView doesn't react properly when receiving WM_THEMECHANGED/WM_SYSCOLORCHANGE messages [QC Description] When enabling/disabling visual styles, TListView failes to properly change the height of the column header (if present) and the dimension of the scrollbars ---------- When changing the text or window background system color scheme, TListView failes to adopt the changes. QC Entry 85133

1) Create a new VCL Forms Application 2) Place a TListView on the form 3) Change ViewStyle to vsReport 4) Add a TListColumn to the ListView 5) Add enough items to the ListView to cause at least one scrollbar to be shown 6) Run the application 7) Enable/disable visual styles 8) TListView failes to properly change the height of the column header and the dimension of the scrollbars ---------- 1) Create a new VCL Forms Application 2) Place a TListView on the form 3) Change ViewStyle to vsReport 4) Add a TListColumn to the ListView 5) Add enough items to the ListView to cause at least one scrollbar to be shown 6) Run the application 7) Change the text and window background system color scheme 8) TListView failes to adopt the changes

QC #: 85158 - Status: Closed

QC #: Project Date Reported: Area:85158 Delphi 6/4/2010 IDE\Code Editor\Help Insight Description Steps:[QC Short Description] Help Insight fails when custom attributes are applied. [QC Description] see steps QC Entry 85158

1. Create a VCL Application project 2. Declare a custom attribute in the main unit. SomeAttribute = class(TCustomAttribute) end; 3. Apply the attribute to the TForm1 and then add comments /// <summary> /// Hello /// </summary> [SomeAttribute] TForm1 = class(TForm) end; As you will see, Help Insight won't show any documentation

QC #: 85248 - Status: Closed

QC #: Project Date Reported: Area:85248 Delphi 6/8/2010 Compiler\Delphi\Anonymous Methods

Description Steps:[QC Short Description] Creating a method reference for a routine with a specific header causes Internal Error T2671 [QC Description] An attempt to compile the sample program (in Steps) results in ICE. Removing the formal parameter of open array type or changing the function into a procedure helps. QC Entry 85248

--8<-------8<-------8<--- type T = reference to function(const s: array of char): boolean; function foo(const s: array of char): boolean; begin end; var z: T; begin z := foo // F2084 Internal Error: T2671 end. --8<-------8<-------8<---

QC #: 85256 - Status: Closed

QC #: Project Date Reported: Area: 85256 Delphi 6/8/2010 IDE\Search\Replace Description Steps:[QC Short Description] Default keybinding does not support the CUA shortcut for Replace (Ctrl+H) [QC Description] The Windows CUA shortcut for search and replace is Ctrl+H. The default keybinding maps this to Ctrl+R and Ctrl+Q+A but not Ctrl+H.QC Entry 85256

Press Ctrl+H in the code editor to invoke a replace operation.

QC #: 85259 - Status: Closed

QC #: Project Date Reported: Area: 85259 Delphi 6/8/2010 Compiler\Delphi\RTTI Description Steps:[QC Short Description] Unable to use nil as a parameter value when invoking method via RTTI [QC Description] This is repost of the issue 81043 as requested by Tomohiro Takahashi. When invoking a method via RTTI it is impossible to use nil as a value for a parameter of interface type - instead of nil some garbage is sent tothe method which causes AV type ITest = interface(IInterface) ['{59368832-D46D-423E-95DC-808221C1320F}'] function GetName: string; end; TForm1 = class(TForm) Button1: TButton; procedure BtnSetNILTest(Sender: TObject); public procedure SetTest(const aTest: ITest); end; procedure TForm1.SetTest(const aTest: ITest); begin ShowMessage('SetTest('+IntToHex(Integer(aTest), 8)+')'); if(aTest = nil)then ShowMessage('nil') else ShowMessage(aTest.GetName); end; procedure TForm1.BtnSetNILTest(Sender: TObject); var Val: TValue; Typ: TRttiType; Cnx: TRttiContext; Setter: TRttiMethod; Params: TArray<TRttiParameter>; tmp : IInterface; TypI: PTypeInfo; begin Cnx := TRttiContext.Create; Typ := Cnx.GetType(Self.ClassInfo); Setter := Typ.GetMethod('SetTest'); Params := Setter.GetParameters; TypI := Params[Low(Params)].ParamType.Handle; // tmp := nil;

Compile and run the attached application below. See the following output indicating failure. program BTS277190; {$APPTYPE CONSOLE} uses SysUtils, TypInfo, RTTI; type ITest = interface(IInterface) ['{59368832-D46D-423E-95DC-808221C1320F}'] function GetName: string; end; {$METHODINFO ON} TForm1 = class procedure DoTest; public procedure SetTest(const aTest: ITest); end; {$METHODINFO OFF} procedure TForm1.SetTest(const aTest: ITest); begin WriteLn('SetTest('+IntToHex(Integer(aTest), 8)+')'); if aTest = nil then WriteLn('nil') else WriteLn(aTest.GetName); end; procedure TForm1.DoTest; var Val: TValue; Typ: TRttiType; Cnx: TRttiContext; Setter: TRttiMethod; Params: TArray<TRttiParameter>; tmp : IInterface; TypI: PTypeInfo; begin Cnx := TRttiContext.Create; Typ := Cnx.GetType(Self.ClassInfo); Setter := Typ.GetMethod('SetTest'); Params := Setter.GetParameters;

// none of the following lines create correct parameter //Val := TValue.Empty; //Val := TValue.From(tmp); //Val := TValue.From<ITest>(tmp); //Val := TValue.FromVariant(tmp); Val := Default(ITest); // Setter.Invoke(Self, [Val]); Cnx.Free; end; In the original report Nick Hoddges suggest that this is test case error as one is supposed to use the Default function Val := Default(ITest); Setter.Invoke(Self, [Val]); but this still sends some garbage address to the method invoked, not nil. QC Entry 85259

TypI := Params[Low(Params)].ParamType.Handle; // tmp := nil; // none of the following lines create correct parameter //Val := TValue.Empty; //Val := TValue.From(tmp); //Val := TValue.From<ITest>(tmp); //Val := TValue.FromVariant(tmp); Val := Default(ITest); // Setter.Invoke(Self, [Val]); Cnx.Free; end; var Form1: TForm1; begin try with TForm1.Create do begin DoTest; Free; end; WriteLn('PASS'); except on E: TObject do WriteLn('FAIL - Exception=', E.ClassName); end; end.

QC #: 85289 - Status: Closed

QC #: Project Date Reported: Area: 85289 Delphi 6/9/2010 IDE\Message View Description Steps:[QC Short Description] Enter in seach pane should act like double clicking the selected line [QC Description] After a search for something in a whole project the results of the search are displayed in the seach pane in a grouped form. I may double click on individual lines and if the line is a search result (not a unit name) the IDE will jump to that line. Now I'd like to have the same for pressing enter so this get's keyboard friendly as well. QC Entry 85289

QC #: 85387 - Status: Closed

QC #: Project Date Reported: Area:85387 C++Builder 6/12/2010 Compiler\C++\Front End\Templates

Description Steps:[QC Short Description] Friend function template in namespace triggers error E2401 [QC Description] A friend function template declaration in a namespace is not accepted, even when the friend declaration itself is in a non-template class. This error is given: Error E2401: Invalid template argument list

bcc32 277312.cpp exp: clean compile act: Error E2401 277312.cpp 8: Invalid template argument list Error E2247 277312.cpp 17: 'ClassX::PrivateInt' is not accessible in

Note: This issue is quite similar to Report #77274, "Friend function template in namespace not accepted", reported by Fraser Ross: http://qc.embarcadero.com/wc/qcmain.aspx?d=77274 However, #77274 deals with a friend declaration in a class template, and it reports a different error message. This particular bug has caused many Boost Regression compile errors, triggered by merely doing #include <boost/exception/exception.hpp>. See also Boost ticket #4068, "Borland also needs private/public workaround in boost::exception", https://svn.boost.org/trac/boost/ticket/4068 QC Entry 85387

function in t Func<int>(int) *** 2 errors in Compile ***

QC #: 85406 - Status: Closed

QC #: Project Date Reported: Area:85406 Delphi 6/13/2010 Internet\Controls\TXMLDocument

Description Steps:[QC Short Description] Memory leak in ADOM XML implementation [QC Description] There is a memory leak in the ADOM XML implementation. If you use this XML implementation for handling XML then every time you parse a document you will leak some memory, which for a server is bad news. QC Entry 85406

Run the following code and set ReportMemoryLeaksOnShutdown to True. procedure TForm1.Button1Click(Sender: TObject); var lDocument: TXmlDocument; begin lDocument := TXmlDocument.Create(nil); try lDocument.DomVendor := GetDomVendor('ADOM XML v4'); lDocument.Xml.Text := '<a></a>'; lDocument.Active := True; lDocument.Active := False; lDocument.DomVendor := nil; finally lDocument.Free; end; end;

QC #: 85415 - Status: Closed

QC #: Project Date Reported: Area:85415 Delphi 6/13/2010 IDE\Code Editor\Formatting Description Steps:[QC Short Description] Delphi code formater failed to format code for '.End' methods [QC Description] if I use in my code variant for working with MS Word and write something like this (simplified): procedure TForm1.FormCreate(Sender: TObject); var msWord: Variant; begin msWord := CreateOleObject('Word.Application'); msWord.Selection.Start := 1; msWord.Selection.End:= 2; end; and then press Ctrl + D for auto format that code would not be formated correctly. QC Entry 85415

1) Just create empty Delphi VCL Application 2) Double click on Main Form 3) Paste this code: procedure TForm1.FormCreate(Sender: TObject); var msWord: Variant; begin msWord := CreateOleObject('Word.Application'); msWord.Selection.Start := 1; msWord.Selection.End:= 2; end; 4) Press Ctrl+D 5) You will get: procedure TForm1.FormCreate(Sender: TObject); var msWord: Variant; begin msWord := CreateOleObject('Word.Application'); msWord.Selection.Start := 1; msWord.Selection. End := 2; end;

QC #: 85416 - Status: Closed

QC #: Project Date Reported: Area:85416 Delphi 6/13/2010 IDE\Code Editor\Formatting

Description Steps:[QC Short Description] Auto Formater incorrectly format complex generics [QC Description] formater insert unnecessary spaces for complex generics BEFORE formating: procedure TForm1.FormCreate(Sender: TObject); var correct: TDictionary<string, string>; wrong: TDictionary<string, TList<string>>; begin end; AFTER formating: procedure TForm1.FormCreate(Sender: TObject); var correct: TDictionary<string, string>; wrong: TDictionary < string, TList < string >> ; begin end; QC Entry 85416

see description

QC #: 85483 - Status: Closed

QC #: Project Date Reported: Area:

85483 Delphi 6/16/2010 Database\Data Aware Controls\TDBComboBox

Description Steps:[QC Short Description] itemindex doesn't change the field value [QC Description] if you change the itemindex of a tdbcombobox the text of the dbcombox is updated, but the field value isn't. (Example dbcombox1.field.asstring ='one'. After calling dbcombox1.itemindex := 3 the text is changed to 'three', but the field value isn't) QC Entry 85483

//see comments Create a from with a dbgrid and a dbcombobox with the same datasource/dataset. dbcombobox is link to one field which is visible in the dbgrid. Fill in the items property of the dbcombox with zero one two three four five Place a button which call dbcombox1.itemindex := 3 I would except that the fieldvalue is set to 'three', but is doesn't. Only if you select a item for the list by using the mouse or keyboard will change the field value

QC #: 85501 - Status: Closed

QC #: Project Date Reported: Area:85501 Delphi 6/16/2010 VCL\Standard Controls\TComboBox

Description Steps:[QC Short Description] Changing color of themed controls causes repaint problem. [QC Description] If you change the color of a TComboBox, activate the TComboBox

Run or compile attached project to see the problem.

and then change the color again, other themed controls on the form do not get painted correctly. Added by Sysop <<<<<<<<<<< This issue occurs on XP and is similar to QC#83902, QC#75749. >>>>>>>>>>> QC Entry 85501 SB: It's a regression.

QC #: 85528 - Status: Closed

QC #: Project Date Reported: Area:85528 C++Builder 6/17/2010 RTL\C++\Locale/International API

Description Steps:[QC Short Description] std::wcin, std::fgetws problem [QC Description] These two programs doesn't work correctly for wide string (Unicode). ---- #include <string> #include <iostream> #include <locale> int main() { char locale[] = "japanese"; std::locale::global(std::locale(locale)); std::wcin.imbue(std::locale(locale)); std::wcout.imbue(std::locale(locale)); std::wstring str; std::wcout << L"????????????" << std::endl; std::wcin >> str; std::wcout << str << std::endl; return 0; } ----- #include <cwchar> #include <locale> int main() { char locale[] = "japanese"; setlocale(LC_ALL, locale); wchar_t inbuf[16]; std::fputws(L"????????????\n", stdout); std::fgetws(inbuf, sizeof inbuf, stdin); std::fputws(inbuf, stdout); return 0; } QC Entry 85528

Compile and run each program. Input wide character string for the prompt of each program. Each program displays not correct string. If each program has correctly work, same string would echo back.

QC #: 85556 - Status: Closed

QC #: Project Date Reported: Area:

85556 Delphi 6/18/2010 VCL\Graphics Description Steps:[QC Short Description] Indexed, transparent PNG decoded incorrectly [QC Description] The attached delete_indexed.png appears correctly in Explorer and in the TImage.Picture browse dialog preview, but is offset and wrapped when loaded by TPngImage. delete_RGB.png is the original file and appears correctly. QC Entry 85556

1) Create a new VCL form. 2) Drop a TImage on the form. 3) Click the [...] button next to Image1's Picture property in the Object Inspector. 4) Click the "Load" button in the new dialog. 5) Select "delete_indexed.png". Notice that it is shown in the preview correctly as a square with an x in the center. 6) Press the "Open" button. Notice that the image is now shown wrapped, and the x looks squished.

QC #: 85571 - Status: Closed

QC #: Project Date Reported: Area: 85571 C++Builder 6/19/2010 VCL\Emulation Classes Description Steps:[QC Short Description] No implementation available for three Variant/Automation related methods [QC Description] The "IInterface*" overloads of the following methods are declared but not defined: // sysvari.h class Variant { ... __fastcall Variant(IUnknown* src); __fastcall Variant(IInterface* src); // <-- __fastcall Variant(IDispatch* src); ... Variant& __fastcall operator =(IUnknown* src); Variant& __fastcall operator =(IInterface* src); // <-- Variant& __fastcall operator =(IDispatch* src); ... }; class AutoCmd { ... AutoCmd& operator <<(IDispatch* arg); AutoCmd& operator <<(IUnknown* arg); AutoCmd& operator <<(IInterface* arg); // <-- ... }; To fix it, do one of the follwing: - remove the overloads for IInterface* altogether. They are not required because IInterface* inherits from IUnknown anyway. - add the required overloads to $(BDS)\source\Win32\vcl\variant.cpp:// ----- __fastcall Variant::Variant(IUnknown* src) { SetType(varUnknown, true); if (src) src->AddRef(); VUnknown = src; } + __fastcall Variant::Variant(IInterface* src) + { + SetType(varUnknown, true); + if (src) + src->AddRef(); + VUnknown = src; + }

- Try to build the following code (bcc32 -WCV qc85571.cpp): // ----- #include <vcl.h> int main (void) { IInterface *intf; Procedure ac (""); ac << intf; System::Variant v = intf; v = intf; } // ----- Exp.: clean compile Act.: Error: Unresolved external 'System::AutoCmd::operator <<(System::IInterface *)' referenced from [...]\QC85571.OBJ Error: Unresolved external '__fastcall System::Variant::Variant(System::IInterfa ce *)' referenced from [...]\QC85571.OBJ Error: Unresolved external '__fastcall System::Variant::operator =(System::IInte rface *)' referenced from [...]\QC85571.OBJ

... Variant& __fastcall Variant::operator =(IUnknown* rhs) { if (rhs) rhs->AddRef(); SetType(varUnknown, false); VUnknown = rhs; return *this; } + Variant& __fastcall Variant::operator =(IInterface* rhs) + { + if (rhs) + rhs->AddRef(); + SetType(varUnknown, false); + VUnknown = rhs; + return *this; + } ... AutoCmd& AutoCmd::operator <<(IUnknown* arg) { AddElement(); Parms.PutElement(arg, Parms.ArrayHighBound()); ParmTypes.PutElement(varUnknown, ParmTypes.ArrayHighBound()); return *this; } + AutoCmd& AutoCmd::operator <<(IUnknown* arg) + { + AddElement(); + Parms.PutElement(arg, Parms.ArrayHighBound()); + ParmTypes.PutElement(varUnknown, ParmTypes.ArrayHighBound()); + return *this; + } // ----- QC Entry 85571

QC #: 85637 - Status: Closed

QC #: Project Date Reported: Area: 85637 C++Builder 6/22/2010 Compiler\C++ Description Steps:[QC Short Description] Internal backend error C1197 compiling ServerCommands.i [QC Description] Compiling ServerCommands.cpp causes Internal backend error C1197.Attached is the preprocessed .i file as per David Dean's instructions here - http://blogs.embarcadero.com/ddean/2009/02/13/34818 QC Entry 85637

bcc32.exe -w- -c ServerCommands.cpp exp: clean compile act: Internal backend error C1286 compiling servercommands.cpp(872) *** 1 errors in Compile ***

QC #: 85658 - Status: Closed

QC #: Project Date Reported: Area:85658 Delphi 6/23/2010 Compiler\Delphi\Execution Description Steps:[QC Short Description] Fatal: F2084 Internal Error: C5802

Compile the attached application and its associated unit.

[QC Description] The problem raises when compiling the function SetCanMinDeltaOptionRead. The problem disappears if you substitute the instruction ( UB_TMinDeltaGearOption(FlagCode) in UB_DecodeCanMinDeltaGear(EncodedMinDelta).MinDeltaGearOptions ) with the equivalent instruction ( UB_DecodeCanMinDeltaGear(EncodedMinDelta).MinDeltaGearOptions >= [UB_TMinDeltaGearOption(FlagCode)] ) The bug raises with the message "Internal error: C4591" in Delphi 7 (SP1), Build No 8.1 and "F2084 Internal Error: C5195" in RAD2009 (SP2) QC Entry 85658

See the following compile-time error indicating failure. Fatal: F2084 Internal Error: C5802 Note the following source in the file uBTS277581.pas and the workaround noted in the comments. procedure SetCanMinDeltaOptionRead( const CanConfigStruct : UBM_TCanConfigStruct; Parameter : UB_TCanParameter; FlagCode : Integer ); var EncodedMinDelta : UB_TMinDeltaCanParameter; begin EncodedMinDelta := CanConfigStruct.MinDeltaValues.MapParameters[Parameter]; begin if UB_CanParameterHasEncodedMinDelta(Parameter) then case Parameter of UB_CAN_GEAR : if ( UB_TMinDeltaGearOption(FlagCode) in UB_DecodeCanMinDeltaGear(EncodedMinDelta).MinDeltaGearOptions ) //The compiler gets the message //"Internal error: C4591" in Delphi 7 (SP1) //or //"F2084 Internal Error: C5195" in RAD2009 (SP2). //Substituting with the following instruction, the bug disappears: //( UB_DecodeCanMinDeltaGear(EncodedMinDelta).MinDeltaGearOptions // >= [UB_TMinDeltaGearOption(FlagCode)] ) then exit; end; end; end;

QC #: 85671 - Status: Closed

QC #: Project Date Reported: Area: 85671 Delphi 6/24/2010 RTL Description Steps:[QC Short Description] CommCtrl.InitCommonControlsEx fails when comctl32.dll has not been loaded into the application. [QC Description] CommCtrl.InitCommonControlsEx uses GetModuleHandle internally. GetModuleHandle, however, will fail to return the requested handle if the module has not been loaded into the application before it's called: Thus this won't work: program Project1; uses Windows, CommCtrl, XPMan; var Ctl: tagINITCOMMONCONTROLSEX;

Create a new console application Replace the entire code section with this: Program Project1; uses Windows, CommCtrl, XPMan; var Ctl: tagINITCOMMONCONTROLSEX; begin Ctl.dwSize := SizeOf(tagINITCOMMONCONTROLSEX); Ctl.dwICC := ICC_STANDARD_CLASSES; InitCommonControlsEx(Ctl); MessageBoxW(0, 'Text', 'Caption', 0); end. Notice that the message box is not shown.

begin Ctl.dwSize := SizeOf(tagINITCOMMONCONTROLSEX); Ctl.dwICC := ICC_STANDARD_CLASSES; InitCommonControlsEx(Ctl); MessageBoxW(0, 'Text', 'Caption', 0); end. because comctl32.dll simply hasn't been loaded: This do work: program Project1; uses Windows, CommCtrl, XPMan; var Ctl: tagINITCOMMONCONTROLSEX; begin Ctl.dwSize := SizeOf(tagINITCOMMONCONTROLSEX); Ctl.dwICC := ICC_STANDARD_CLASSES; ImageList_GetImageCount(0); InitCommonControlsEx(Ctl); MessageBoxW(0, 'Text', 'Caption', 0); end. because ImageList_GetImageCount makes sure that comctl32.dll is loaded before the call to GetModuleHandle. The result is that controls with visual styles failes to be painted. QC Entry 85671

QC #: 85745 - Status: Closed

QC #: Project Date Reported: Area: 85745 C++Builder 6/27/2010 Compiler\C++ Description Steps:[QC Short Description] Compiler' Bug with express optimization [QC Description] //--------------------------------------------------------------------------- #pragma hdrstop #include <tchar.h> //--------------------------------------------------------------------------- #include <iostream.h> #pragma argsused char c = 0x80; int _tmain(int argc, _TCHAR* argv[]) { if (c != 1 && (unsigned char)c != 0x80) { cout << "Compiler wrong!\n"; } return 0; } //--------------------------------------------------------------------------- Added by Sysop <<<<<<<<<<<<<<<<<<<< This issue is due to bug of optimization of C++ compiler.

---- simplified source code and new steps --- compile the source below as: bcc32 -Oc 277648.cpp && 277648 && echo "hi" exp: hi (i.e. zero status returned) act: (non-zero status retutrned) char c = 0x80; int main() { if (c != 1 && (unsigned char)c != 0x80) // Note: works without the first test return 1; return 0; } ---- old steps using attached file --- bcc32 -Oc 277648.cpp 277648.exe exp: no output act: Compiler wrong!

So, we need to disable optimization as below. 1. [Project] | [Options...] 2. [C++ Compiler] | [Optimizations] 3. set [Disable all optimizations.] to False 4. rebuild the project and run it. >>>>>>>>>>>>>>>>>>>> QC Entry 85745

QC #: 85763 - Status: Closed

QC #: Project Date Reported: Area: 85763 Delphi 6/28/2010 Debugger Description Steps:[QC Short Description] Debugger should evaluate sets of enumerated types to a fully-expanded list by default [QC Description] I have a type that's a set of a certain enumerated type. When viewed in the debugger, it collapses contiguous subranges into "start..end" style. That makes sense if you have a numeric set. It's pretty helpful in that case. But when your elements are name and not numbers, it becomes confusing quickly, since you can't easily look at it and determine whether a given element is in the set or not. When displaying sets based on enums, the debugger should always evaluate to a comma-separated list, and not collapse subranges. Apparently the functionality for this exists in Evaluate/Modify if you add ",e" at the end. This view style should be the default for all sets of enumerated types, not only in Evaluate/Modify but also in tooltips, in the Local Variables view, in Inspect windows and in watches. (And anywhere else I may have neglected to mention.) QC Entry 85763

Open attached project Set a breakpoint on line 40 of Unit22.pas Run to hit the breakpoint Look at "ASet" in the Locals view, Watch View, Eval/Modify dialog, Eval Tooltips and Debug Inspector Look at "AFoo.FSet" in the Locals view, Watch View, Eval/Modify dialog, Eval Tooltips and Debug Inspector EXP: The value is shown as: [meZero,meTwo,meThree,meFour,meSix,meSeven,meEight,meTen]ACT: The value is shown as: [meZero, meTwo..meFour, meSix..meEight, meTen]

QC #: 85764 - Status: Closed

QC #: Project Date Reported: Area: 85764 Delphi 6/28/2010 Debugger Description Steps:[QC Short Description] Invoking Evaluate/Modify should always copy text from the code view, if applicable, even if the window is currently visible [QC Description] When I position the cursor on a piece of code and hit Ctrl-F7, it brings up Evaluate/Modify with the current expression filled in. If I highlight code and hit Ctrl-F7, it fills in the entire highlighted section. That's good. But if I then click into or highlight some other code and hit Ctrl-F7 again, without closing Evaluate/Modify, it focuses the Evaluate/Modify window but it doesn't replace the current expression with the new one I selected. That's annoying and ought to be fixed. QC Entry 85764

QC #: 85765 - Status: Closed

QC #: Project Date Reported: Area: 85765 Delphi 6/28/2010 Debugger Description Steps:[QC Short Description] Evaluate/Modify can only copy 80 characters from the code view [QC Description] Evaluate/Modify seems to only be able to copy up to 80 characters if I highlight a selection, and then truncates it if what I highlighted was longer than 80 characters, leaving me with an error message and the task of manually copy/pasting the rest of it into the Expression box. The Expression box is perfectly capable of holding more than 80 characters, and the evaluator is capable of evaluating more than 80 characters, so why the limit on how much it will automatically copy? This is annoying, and ought to be fixed. QC Entry 85765

QC #: 85783 - Status: Closed

QC #: Project Date Reported: Area: 85783 Delphi 6/29/2010 RTL\Delphi\Other RTL Description Steps:[QC Short Description] TValue and WordBool - endless recursion [QC Description] When using a WordBool with TValue there ist a endless recursion on evaluating the result. QC Entry 85783

Compile and run the attached application below. See that #1 and #2 appear on the console but then the app never finishes on its own. program BTS277705; {$APPTYPE CONSOLE} uses RTTI; var Value: TValue; BoolValue: WordBool; begin WriteLn('#1'); Value := TValue.From<WordBool>(True); WriteLn('#2'); BoolValue := Value.AsBoolean; WriteLn('PASS'); end. The recursion happens in RTTI.ConvEnum2Enum.GetEnumBaseType. It seems that the BaseType for WordBool is WordBool. You can change this by add a conditional abort.

QC #: 85788 - Status: Closed

QC #: Project Date Reported: Area: 85788 Delphi 6/29/2010 IDE\Code Completion Description Steps:[QC Short Description] Steps by USc: - save the following file as Turbu.dpr - start Delphi -

Code Completion causes the IDE to lock up in an infinite loop [QC Description] At certain times, pressing CTRL-SPACE to manually invoke Code Completion throws the IDE into an infinite loop, consuming all available CPU resources on one core and allocating memory continually until an out of memory condition is eventually reached, which can take several minutes. I've finally found a consistently reproducible test case for this one. QC Entry 85788

open Turbu.dpr - compile - remove the 0 in the EnsureImage call on line 22 - press CTRL-SPACE with the cursor between the parenthesis on line 22 expected: Code Completion window gets shown actual: 100% CPU utilization on one core and increasing amount of used memory until the following message is shown (there are no details in ExceptDiag dialog) --------------------------- Error --------------------------- Out of memory. --------------------------- OK Details >> --------------------------- program Turbu; {$APPTYPE CONSOLE} type //turbu_container.pas TRpgObjectList<T> = class(TObject) public function mapF<U>: TRpgObjectList<U>; end; //SDL_ImageManager.pas procedure EnsureImage(spritesize: Integer); begin end; function TRpgObjectList<T>.mapF<U>: TRpgObjectList<U>; begin end; begin EnsureImage(0); end. ------- Original steps: Check out the TURBU codebase from SVN at https://turbu.googlecode.com/svn/trunk to revision 92. Open \turbu\turbu.groupproj and build turbu.exe, which will build the dependencies automatically. (Note: This project requires the JVCL.) Open turbu_map_sprites.pas in map_default.bpl. Go to line 864, which reads: FEngine.Images.EnsureImage('mapsprite\' + filename + '.png', filename, SPRITE_SIZE); Delete the last argument in the function call, then press CTRL-SPACE with the cursor between "filename," and the close parenthesis. Open Task Manager and watch BDS.EXE's self-immolation.

QC #: 85828 - Status: Closed

QC #: Project Date Reported: Area: 85828 C++Builder 6/30/2010 RTL\C++ Description Steps:[QC Short Description] GetFiberData() is missing from dynamically linked RTL [QC Description] Inline implementation of void GetFiberData(void) was removed from original Microsoft winnt.h header (line 3588). Implementation was supposed to be moved to the DLL instead, but it's not found in cw32mti.lib. This causes every program that contains GetFiberData() calls to fail when compiling with dynamic RTL. QC Entry 85828

Create any project type (except static lib), specify dynamic RTL in link options, add GetFiberData() call in any place in code. Linker complains: Unresolved external '_GetFiberData'

QC #: 85844 - Status: Closed

QC #: Project Date Reported: Area:85844 Delphi 7/1/2010 VCL\Docking Description Steps: [QC Short Description] DockManager.LoadFromStream causes app to hang [QC Description] When a stream previously generated with DockManager.SaveToStream contains values that LoadFromStream is not anticipating, DockManager.LoadFromStream gets stuck in an infinite 'while' loop, and the entire application hangs.

You may need Controls.pas in front of you to follow along... {code} // read dock zone tree (line 14397 in Controls.pas) while True do begin with Stream do begin Read(Level, SizeOf(Level)); if Level = TreeStreamEndFlag then Break; .... ReadComponentName(CompName); //Line 14414 .... end; .... LastLevel := Level; LastZone := Zone; end; //Line 14460 {code} Example of a 53 byte stream that causes a hang: {code} 0000080000010000000017D0200000000000001EB00000000000000010000000017D020000080000007067635351554F51FFFFFFFF {code} Example segment from the above stream: {code} "...00080000007067635351554F51FFFFFFFF" {code} Using the above Stream segment as an example, while reading the Stream, the 'while True...' loop calls ReadComponentName. This immediately reads an integer $0800 (2048) from the Stream and then attempts to read 2048 bytes from the Stream. However the Stream is only 53 bytes long, so it just reads to the end of the Stream. Note that ReadComponentName has just read past the TreeStreamEndFlag markers in the Stream (-1 / FFFF), so from this point onwards a TreeStreamEndFlag can never be found. Control returns to the 'while True...' loop, which doesn't know the Stream has ended. It continues trying to read from the Stream (receiving zero bytes each time) looking for a TreeStreamEndFlag which will now never occur. No check is made to see if the Stream has ended, so the 'while True...' loop continues looping forever and the app hangs. Something obviously went wrong while reading the Stream: The Stream originally generated by DockManager.SaveToStream is likely corrupt/inappropriate in some way; but the immediate problem seems to

This also occurs when a stream passed to DockManager.LoadFromStream ends unexpectedly (truncated stream). Explanation: The '// read dock zone tree... while True...' loop (Controls.pas line 14397) contains no error checking, and never tests to see if the stream has ended. When a stream ends prematurely, either because it is a truncated stream, or because ReadComponentName has attempted to read beyond the end of the stream, the only exit condition (if Level = TreeStreamEndFlag then Break;) can never be met, and the routine then loops forever trying to read bytes from a stream that has already ended. QC Entry 85844

be that LoadFromStream has no error checking or end of Stream checks. This means that any Stream containing unexpected values or that is truncated will cause the entire app to hang, instead of throwing an exception for the app to handle.

QC #: 85877 - Status: Closed

QC #: Project Date Reported: Area: 85877 Delphi 7/1/2010 Compiler\Delphi\Generics Description Steps:[QC Short Description] [DCC Fatal Error] F2084 Internal Error: L1737 [QC Description] [DCC Fatal Error] F2084 Internal Error: L1737 when compiling this unit: unit U_SAIL_Hash; {** Hash Library Modification by Tim Kelly to support generics (2010) Original Author: Ciaran McCreesh <[email protected]> Copyright: Copyright (c) 2002 Ciaran McCreesh Date: 20020621 Purpose: A collection of hash components for Delphi. These are similar to arrays, but the index is a string. A hashing algorithm is used to provide extremely fast searching. Generic Moan: This would be a lot easier if Delphi had template classes. Changelog: FIXED BUG 2005-06-22: TMK (was freeing even when didn't own items before v2.6 (20020621) * Framework for dynamic bucket sizes. No actual resizing yet. * Changed TStringHash, TIntegerHash and TObjecTHash slightly, and fixed potential bugs in them. * General performance improvements * Changed how iterators work. In particular, multiple iterators are nowpossible. Thanks to Daniel Trinter for code and Emanuel for

- save the attachment or create a package and add the following unit - dcc32 QC85877.dpk expected: it compiles actual: D2010 U#4: F2084 Internal Error: L1737 Fulcrum build 3831: Fatal: F2084 Internal Error: L2025 The error goes away when defining a type for "array of THashRecord". unit U_SAIL_Hash; interface type THashRecord = record end; THash<T> = class protected FKeys: array of array of THashRecord; public procedure Delete; end; TIntegerHash = THash<Integer>; //Comment these three lines and it compiles. TStringHash = THash<string>; TDoubleHash = THash<Double>; implementation procedure THash<T>.Delete;

suggestions. + Previous method (goes with Next) + AllowCompact property v2.5 (20020606) * Empty hash keys explicitly forbidden. Thanks to Marco Vink for thenotice. + Clear method v2.4 (20020603) * Fixed Compact bug. Thanks to Daniel Trinter for the notice. Basically I was assuming something about the size of one of the internal arrayswhich wasn't always true. v2.3 (20020601) + ItemCount property + Compact method * Hash auto-compacts itself if overly inefficient * ItemIndexes are now recycled v2.2 (20020529) * Fixed iterator bug. Not all items were called under some circumstances. Thanks to Tom Walker for the notice. v2.1 (20020528, internal release only) + TObjecTHash v2.0 (20020526) * Complete rewrite + THash + TStringHash + TIntegerHash License: This library is Copyright (c) 2002 Ciaran McCreesh. Permission is granted to anyone to use this software for any purpose onany computer system, and to redistribute it freely, subject to the following restrictions: 1. This software is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 2. The origin of this software must not be misrepresented. 3. Altered versions must be plainly marked as such, and must not be misrepresented as being the original software. Documentation: Please see: * http://www.opensourcepan.co.uk/libraries/hashes/ * http://www.undu.com/articles/020604.html Other notes: This unit provides three hashes, TIntegerHash, TStringHash and TObjecTHash. If you want a more precise kind (eg TComponenTHash), it's easiest to descend from THash and copy the TObjecTHash code. Note that TObjecTHash is slightly different from TIntegerHash and TStringHashbecause it has to free items -- it cannot just overwrite them. Internal data representation: Each hash object has an array (potentially dynamically sized, but thisisn't used yet) of 'buckets' (dynamic arrays). Each bucket is mapped to a series of hash values (we take the high order bits of the value calculated), so that every possible hash value refers to exactly one bucket. This reduces the amount of searching that has to be done to find an item, so it's much faster than linear or B-Tree storage.

begin SetLength(FKeys[0], 0); end; end.

Each bucket contains a series of integers. These are indexes into an items array, which for type reasons is maintained by the descendant classes. These are recycled when the hash detects that it is becoming inefficient. } interface uses SysUtils, Contnrs, Variants, Classes; const {** This constant controls the initial size of the hash. } c_HashInitialItemShift = 7; {** How inefficient do we have to be before we automatically Compact? } c_HashCompactR = 2; { This many spaces per item. } c_HashCompactM = 100; { Never for less than this number of spaces. } type {** General exception classes. } EHashError = class(Exception); EHashErrorClass = class of EHashError; {** Exception for when an item is not found. } EHashFindError = class(EHashError); {** Exception for invalid Next op. } EHashIterateError = class(EHashError); {** Exception for invalid keys. } EHashInvalidKeyError = class(EHashError); {** Record, should really be private but OP won't let us... } THashRecord = record Hash: Cardinal; ItemIndex: integer; Key: string; end; {** Iterator Record. This should also be private. This makes me almost like the way Java does things. Almost. Maybe. } THashIterator = record ck, cx: integer; end; {** Base Hash class. Don't use this directly. } THash<T> = class private function HashThis(const s: string): cardinal; protected {** The keys. } f_Keys: array of array of THashRecord; f_Items: array of T; {** Current bucket shift. } f_CurrentItemShift: integer; {** These are calculated from f_CurrentItemShift. } f_CurrentItemCount: integer; f_CurrentItemMask: integer; f_CurrentItemMaxIdx: integer; {** Spare items. } f_SpareItems: array of integer; {** Whether Next is allowed. }

f_NextAllowed: boolean; {** Current key. } f_CurrentKey: string; {** Can we compact? } f_AllowCompact: boolean; {** Our current iterator. } f_CurrentIterator: THashIterator; {** Update the masks. } procedure FUpdateMasks; {** Update the buckets. } procedure FUpdateBuckets; {** Find a key's location. } function FFindKey(const Key: string; var k, x: integer): boolean; {** Add a new key, or change an existing one. Don't call this directly. } procedure FSetOrAddKey(const Key: string; ItemIndex: integer); {** Abstract method, delete value with a given index. Override this. }procedure FDeleteIndex(i: integer); virtual; {** Get an item or raise an exception. } function FGetItem(const Key: string): T; {** Set or add an item. } procedure FSetItem(const Key: string; Value: T); {** Get the number of items. } function FGetItemCount: integer; {** Allocate an item index. } function FAllocItemIndex: integer; {** Abstract method, move an item with index OldIndex to NewIndex.Override this. } procedure FMoveIndex(oldIndex, newIndex: integer); virtual; {** Abstract method, trim the indexes down to count items. Overridethis. } procedure FTrimIndexes(count: integer); virtual; {** Abstract method, clear all items. Override this. } procedure FClearItems; virtual; {** Tell us where to start our compact count from. Override this. } function FIndexMax: integer; virtual; {** Compact, but only if we're inefficient. } procedure FAutoCompact; public {** Our own constructor. } constructor Create; {** Does a key exist? } function Exists(const Key: string): boolean; {** Rename a key. } procedure Rename(const Key, NewName: string); {** Delete a key. } procedure Delete(const Key: string); {** Reset iterator. } procedure Restart; {** Next key. } function Next: boolean;

{** Previous key. } function Previous: boolean; {** Current key. } function CurrentKey: string; {** The number of items. } property ItemCount: integer read FGetItemCount; {** Compact the hash. } procedure Compact; {** Clear the hash. } procedure Clear; {** Allow compacting? } property AllowCompact: boolean read f_AllowCompact write f_AllowCompact; {** Items property. } property Items[const Key: string]: T read FGetItem write FSetItem; default; {** Current iterator. } property CurrentIterator: THashIterator read f_CurrentIterator write f_CurrentIterator; {** Create a new iterator. } function NewIterator: THashIterator; end; TTObject = TObject; {** Hash of objects. } TOwnedObjectHash<T : class> = class(THash<T>) protected procedure FClearItems; override; procedure FDeleteIndex(i: integer); override; public destructor Destroy; override; end; TIntegerHash = THash<integer>; //Comment these three lines and it compiles. TStringHash = THash<string>; TDoubleHash = THash<double>; implementation { THash } function THash<T>.HashThis(const s: string): cardinal; var h, g, i: cardinal; begin if (s = '') then raise EHashInvalidKeyError.Create('Key cannot be an empty string');h := $12345670; for i := 1 to Length(s) do begin h := (h shl 4) xor ord(s[i]); g := h and $F0000000; if (g > 0) then h := h or (g shr 24) or g; end; result := h; end; constructor THash<T>.Create; begin

inherited Create; self.f_CurrentIterator.ck := -1; self.f_CurrentIterator.cx := 0; self.f_CurrentItemShift := c_HashInitialItemShift; self.FUpdateMasks; self.FUpdateBuckets; self.f_AllowCompact := true; end; procedure THash<T>.Delete(const Key: string); var k, x, i: integer; begin { Hash has been modified, so disallow Next. } self.f_NextAllowed := false; if (self.FFindKey(Key, k, x)) then begin { Delete the Index entry. } i := self.f_Keys[k][x].ItemIndex; self.FDeleteIndex(i); { Add the index to the Spares list. } SetLength(self.f_SpareItems, Length(self.f_SpareItems) + 1); self.f_SpareItems[High(self.f_SpareItems)] := i; { Overwrite key with the last in the list. } self.f_Keys[k][x] := self.f_Keys[k][High(self.f_Keys[k])]; { Delete the last in the list. } SetLength(self.f_Keys[k], Length(self.f_Keys[k]) - 1); end else raise EHashFindError.CreateFmt('Key "%s" not found', [Key]); self.FAutoCompact; end; function THash<T>.Exists(const Key: string): boolean; var dummy1, dummy2: integer; begin result := FFindKey(Key, dummy1, dummy2); end; procedure THash<T>.FSetItem(const Key: string; Value: T); var k, x, i: integer; begin if (self.FFindKey(Key, k, x)) then self.f_Items[self.f_Keys[k][x].ItemIndex] := Value else begin { New index entry, or recycle an old one. } i := self.FAllocItemIndex; if (i > High(self.f_Items)) then SetLength(self.f_Items, i + 1); self.f_Items[i] := Value; { Add it to the hash. } SetLength(self.f_Keys[k], Length(self.f_Keys[k]) + 1); self.f_Keys[k][High(self.f_Keys[k])].Key := Key; self.f_Keys[k][High(self.f_Keys[k])].ItemIndex := i; self.f_Keys[k][High(self.f_Keys[k])].Hash := HashThis(Key); { Hash has been modified, so disallow Next. } self.f_NextAllowed := false; end; end; procedure THash<T>.FSetOrAddKey(const Key: string; ItemIndex: integer); var k, x, i: integer; begin { Exists already? } if (self.FFindKey(Key, k, x)) then begin { Yep. Delete the old stuff and set the new value. } i := self.f_Keys[k][x].ItemIndex;

self.FDeleteIndex(i); self.f_Keys[k][x].ItemIndex := ItemIndex; { Add the index to the spares list. } SetLength(self.f_SpareItems, Length(self.f_SpareItems) + 1); self.f_SpareItems[High(self.f_SpareItems)] := i; end else begin { No, create a new one. } SetLength(self.f_Keys[k], Length(self.f_Keys[k]) + 1); self.f_Keys[k][High(self.f_Keys[k])].Key := Key; self.f_Keys[k][High(self.f_Keys[k])].ItemIndex := ItemIndex; self.f_Keys[k][High(self.f_Keys[k])].Hash := HashThis(Key); end; end; procedure THash<T>.FTrimIndexes(count: integer); begin SetLength(self.f_Items, count); end; function THash<T>.FFindKey(const Key: string; var k, x: integer): boolean; var i: integer; h: cardinal; begin { Which bucket? } h := HashThis(Key); k := h and f_CurrentItemMask; result := false; { Look for it. } for i := 0 to High(self.f_Keys[k]) do if (self.f_Keys[k][i].Hash = h) or true then if (self.f_Keys[k][i].Key = Key) then begin { Found it! } result := true; x := i; break; end; end; procedure THash<T>.Rename(const Key, NewName: string); var k, x, i: integer; begin { Hash has been modified, so disallow Next. } self.f_NextAllowed := false; if (self.FFindKey(Key, k, x)) then begin { Remember the ItemIndex. } i := self.f_Keys[k][x].ItemIndex; { Overwrite key with the last in the list. } self.f_Keys[k][x] := self.f_Keys[k][High(self.f_Keys[k])]; { Delete the last in the list. } SetLength(self.f_Keys[k], Length(self.f_Keys[k]) - 1); { Create the new item. } self.FSetOrAddKey(NewName, i); end else raise EHashFindError.CreateFmt('Key "%s" not found', [Key]); self.FAutoCompact; end; function THash<T>.CurrentKey: string; begin if (not (self.f_NextAllowed)) then raise EHashIterateError.Create('Cannot find CurrentKey as the hash has ' + 'been modified since Restart was called') else if (self.f_CurrentKey = '') then raise EHashIterateError.Create('Cannot find CurrentKey as Next has

not yet ' + 'been called after Restart') else result := self.f_CurrentKey; end; function THash<T>.Next: boolean; begin if (not (self.f_NextAllowed)) then raise EHashIterateError.Create('Cannot get Next as the hash has ' + 'been modified since Restart was called'); result := false; if (self.f_CurrentIterator.ck = -1) then begin self.f_CurrentIterator.ck := 0; self.f_CurrentIterator.cx := 0; end; while ((not result) and (self.f_CurrentIterator.ck <= f_CurrentItemMaxIdx)) do begin if (self.f_CurrentIterator.cx < Length(self.f_Keys[self.f_CurrentIterator.ck])) then begin result := true; self.f_CurrentKey := self.f_Keys[self.f_CurrentIterator.ck][self.f_CurrentIterator.cx].Key; inc(self.f_CurrentIterator.cx); end else begin inc(self.f_CurrentIterator.ck); self.f_CurrentIterator.cx := 0; end; end; end; procedure THash<T>.Restart; begin self.f_CurrentIterator.ck := -1; self.f_CurrentIterator.cx := 0; self.f_NextAllowed := true; end; function THash<T>.FGetItem(const Key: string): T; var k, x: integer; begin if (self.FFindKey(Key, k, x)) then result := self.f_Items[self.f_Keys[k][x].ItemIndex] else raise EHashFindError.CreateFmt('Key "%s" not found', [Key]); end; function THash<T>.FGetItemCount: integer; var i: integer; begin { Calculate our item count. } result := 0; for i := 0 to f_CurrentItemMaxIdx do inc(result, Length(self.f_Keys[i])); end; function THash<T>.FIndexMax: integer; begin result := High(self.f_Items); end; procedure THash<T>.FMoveIndex(oldIndex, newIndex: integer); begin self.f_Items[newIndex] := self.f_Items[oldIndex]; end; function THash<T>.FAllocItemIndex: integer;

begin if (Length(self.f_SpareItems) > 0) then begin { Use the top SpareItem. } result := self.f_SpareItems[High(self.f_SpareItems)]; SetLength(self.f_SpareItems, Length(self.f_SpareItems) - 1); end else begin result := self.FIndexMax + 1; end; end; procedure THash<T>.Compact; var aSpaces: array of boolean; aMapping: array of integer; i, j: integer; begin { Find out where the gaps are. We could do this by sorting, but that's atleast O(n log n), and sometimes O(n^2), so we'll go for the O(n) method, even though it involves multiple passes. Note that this is a lot faster than it looks. Disabling this saves about 3% in my benchmarks, but uses a lot more memory. } if (self.AllowCompact) then begin SetLength(aSpaces, self.FIndexMax + 1); SetLength(aMapping, self.FIndexMax + 1); for i := 0 to High(aSpaces) do aSpaces[i] := false; for i := 0 to High(aMapping) do aMapping[i] := i; for i := 0 to High(self.f_SpareItems) do aSpaces[self.f_SpareItems[i]] := true; { Starting at the low indexes, fill empty ones from the high indexes. }i := 0; j := self.FIndexMax; while (i < j) do begin if (aSpaces[i]) then begin while ((i < j) and (aSpaces[j])) do dec(j); if (i < j) then begin aSpaces[i] := false; aSpaces[j] := true; self.FMoveIndex(j, i); aMapping[j] := i end; end else inc(i); end; j := self.FIndexMax; while ((aSpaces[j]) and (j >= 0)) do //tmk (j>=0) added... sometimes j was -1 and caused range check error. begin dec(j); end; { Trim the items array down to size. } self.FTrimIndexes(j + 1); { Clear the spaces. } SetLength(self.f_SpareItems, 0); { Update our buckets. } for i := 0 to f_CurrentItemMaxIdx do for j := 0 to High(self.f_Keys[i]) do

self.f_Keys[i][j].ItemIndex := aMapping[self.f_Keys[i][j].ItemIndex];end; end; procedure THash<T>.FAutoCompact; begin if (self.AllowCompact) then if (Length(self.f_SpareItems) >= c_HashCompactM) then if (self.FIndexMax * c_HashCompactR > Length(self.f_SpareItems)) then self.Compact; end; procedure THash<T>.FClearItems; begin SetLength(self.f_Items, 0); end; procedure THash<T>.FDeleteIndex(i: integer); begin self.f_Items[i] := Default(T); end; procedure THash<T>.Clear; var i: integer; begin self.FClearItems; SetLength(self.f_SpareItems, 0); for i := 0 to f_CurrentItemMaxIdx do SetLength(self.f_Keys[i], 0); end; procedure THash<T>.FUpdateMasks; begin f_CurrentItemMask := (1 shl f_CurrentItemShift) - 1; f_CurrentItemMaxIdx := (1 shl f_CurrentItemShift) - 1; f_CurrentItemCount := (1 shl f_CurrentItemShift); end; procedure THash<T>.FUpdateBuckets; begin { This is just a temporary thing. } SetLength(self.f_Keys, self.f_CurrentItemCount); end; function THash<T>.NewIterator: THashIterator; begin result.ck := -1; result.cx := 0; end; function THash<T>.Previous: boolean; begin if (not (self.f_NextAllowed)) then raise EHashIterateError.Create('Cannot get Next as the hash has ' + 'been modified since Restart was called'); result := false; if (self.f_CurrentIterator.ck >= 0) then begin while ((not result) and (self.f_CurrentIterator.ck >= 0)) do begin dec(self.f_CurrentIterator.cx); if (self.f_CurrentIterator.cx >= 0) then begin result := true; self.f_CurrentKey := self.f_Keys[self.f_CurrentIterator.ck][self.f_CurrentIterator.cx].Key; end else begin dec(self.f_CurrentIterator.ck); if (self.f_CurrentIterator.ck >= 0) then self.f_CurrentIterator.cx :=

Length(self.f_Keys[self.f_CurrentIterator.ck]); end; end; end; end; { TObjecTHash } procedure TOwnedObjectHash<T>.FDeleteIndex(i: integer); begin self.f_Items[i].Free; inherited; end; procedure TOwnedObjectHash<T>.FClearItems; var i: integer; begin for i := 0 to High(self.f_Items) do if (Assigned(self.f_Items[i])) then self.f_Items[i].Free; inherited; end; destructor TOwnedObjectHash<T>.Destroy; var i: integer; begin for i := 0 to High(self.f_Items) do if (Assigned(self.f_Items[i])) then self.f_Items[i].Free; inherited; end; end. QC Entry 85877

QC #: 85893 - Status: Closed

QC #: Project Date Reported: Area:85893 Delphi 7/2/2010 VCL\Registry / INI Objects Description Steps: [QC Short Description] TCustomIniFile.InternalReadSections does not return exactly matching section name [QC Description] Since D2010 TIniFile and TMemIniFile defer to TCustomIniFile.InternalReadSections to do their ReadSections work. ReadSections and thus InternalReadSections takes a "Section: string" parameter which can be used to limit the section names added to the "Strings: TStrings" parameter. When the Section parameter exactly matches a section in the ini file, the InternalReadSections method does not add it to the Strings. The cause is the line if (SectionLen = 0) or ((SLen > SectionLen) and SameText(Section, Copy(S, 1, SectionLen))) then

Use code below. It is a stripped down version of an existing ini file behaviour test unit which detected the bug when switching from D2009 to D2010. ==== unit IniReadSectionsBehaviourTester; interface uses // CodeGear Windows, SysUtils, Classes, IniFiles, TestFramework; type TMyIniClass = class of TCustomIniFile; type TIniReadSectionsBehaviourTester = class(TTestCase) private protected function TestFileName: string; procedure ReadSectionsAndCheckThem(const aIniClass: TMyIniClass; aSection: string; aExpectedValues: array of string); procedure ReadSectionValuesAndCheckThem(const aIniClass: TMyIniClass); protected procedure SetUp; override; procedure TearDown; override; public constructor Create(MethodName: string); override; destructor Destroy; override; published procedure IniFile_ReadSectionsZonderSectionParameter; procedure IniFile_ReadSectionsMetSectionParameter_LegeWaarde; procedure IniFile_ReadSectionsMetSectionParameter_ExacteWaarde; procedure IniFile_ReadSectionsMetSectionParameter_GedeeltelijkeWaarde; procedure IniFile_ReadSectionsMetSectionParameter_NietBestaandeWaarde; procedure MemIniFile_ReadSectionsZonderSectionParameter; procedure MemIniFile_ReadSectionsMetSectionParameter_LegeWaarde; procedure MemIniFile_ReadSectionsMetSectionParameter_ExacteWaarde; procedure MemIniFile_ReadSectionsMetSectionParameter_GedeeltelijkeWaarde; procedure MemIniFile_ReadSectionsMetSectionParameter_NietBestaandeWaarde; procedure IniFile_ReadSectionValuesAndCheckThem; procedure MemIniFile_ReadSectionValuesAndCheckThem; end; implementation const CRLF = #13#10; NO_SECTION = 'NONE'; READSECTIONS_TEST_FILENAME = 'ReadSectionsTest.ini'; CONTENTS_FOR_INI = '[Section1]' + CRLF + 'Section1Key1=Section1Value1' + CRLF + '' + CRLF + '[EmptySection]' + CRLF + '' + CRLF + '[EmptySectionAlleenComment]' + CRLF + ';EmptySectionKeyComment=EmptySectionValueComment' + CRLF + '' + CRLF + '[Section3]' + CRLF + 'Section3Key1=Section3Value1' + CRLF + 'Section3Key2=Section3Value2' + CRLF + ';Section3KeyComment1=Section3ValueComment1' + CRLF + 'Section3Key3=Section3Value3;WithComment' + CRLF + 'Section3Key4=Section3Value4' + CRLF +

The check on (SLen > SectionLen) should read (SLen >= SectionLen) QC Entry 85893

'//Section3KeyComment2=Section3ValueComment2' + CRLF + 'Section3Key5=Section3Value5//WithComment' + CRLF + '' + CRLF + ' ;[Section3Commented]' + CRLF + 'Section3CommentedKey1=Section3CommentedValue1' + CRLF + 'Section3CommentedKey2=Section3CommentedValue2' + CRLF + '' + CRLF + '[Section4]' + CRLF + 'Section4Key1=Section4Value1' + CRLF + ';Section4KeyComment1=Section4ValueComment1' + CRLF + 'Section4Key2=Section4Value2' + CRLF + 'Section4Key3=Section4Value3' + CRLF + '//Section4KeyComment2=Section4ValueComment2' + CRLF + 'Section4Key4=Section4Value4' + CRLF + 'Section4Key5=Section4Value5' + CRLF + '' + CRLF + '//[Section4Commented]' + CRLF + 'Section4CommentedKey1=Section4CommentedValue1' + CRLF + 'Section4CommentedKey2=Section4CommentedValue2' + CRLF ; SECTIONS_IN_TEST: array[0..4] of string = ( 'Section1', 'EmptySection', 'EmptySectionAlleenComment', 'Section3', 'Section4' ); EXACT_SECTION_NAME = 'Section3'; PARTIAL_SECTION_NAME = 'Section'; NON_EXISTENT_SECTION_NAME = 'Galapagos'; SECTIONS_IN_PARTIAL_TEST: array[0..2] of string = ( 'Section1', 'Section3', 'Section4' ); KEYS_IN_SECTION_3: array[0..6] of string = ( 'Section3Key1', 'Section3Key2', 'Section3Key3', 'Section3Key4', 'Section3Key5', 'Section3CommentedKey1', 'Section3CommentedKey2' ); { TIniReadSectionsBehaviourTester } constructor TIniReadSectionsBehaviourTester.Create(MethodName: string); var Stream: TFileStream; Bytes: TBytes; procedure _Write(const aString: String); begin {$IFDEF USE_ANSI_CONFIG} Bytes := TEncoding.Default{Ansi}.GetBytes(aString); {$ELSE} Bytes := TEncoding.Unicode.GetBytes(aString); {$ENDIF ~USE_ANSI_CONFIG} Stream.WriteBuffer(Pointer(Bytes)^, Length(Bytes)); end; begin inherited Create(MethodName); Stream := TFileStream.Create(TestFileName, fmCreate); try {$IFDEF USE_ANSI_CONFIG} Bytes := TEncoding.Default{Ansi}.GetPreamble; {$ELSE} Bytes := TEncoding.Unicode.GetPreamble; {$ENDIF ~USE_ANSI_CONFIG} if Length(Bytes) > 0 then Stream.WriteBuffer(Pointer(Bytes)^, Length(Bytes)); _Write(CONTENTS_FOR_INI); finally FreeAndNil(Stream); end; end; destructor TIniReadSectionsBehaviourTester.Destroy; begin DeleteFile(TestFileName); inherited Destroy; end; procedure TIniReadSectionsBehaviourTester.SetUp; begin inherited SetUp; end; procedure TIniReadSectionsBehaviourTester.TearDown; begin inherited TearDown; end; function TIniReadSectionsBehaviourTester.TestFileName: string; begin Result := IncludeTrailingPathDelimiter(ExtractFilePath(ParamStr(0))) + READSECTIONS_TEST_FILENAME; end; procedure TIniReadSectionsBehaviourTester.ReadSectionsAndCheckThem(const aIniClass: TMyIniClass; aSection: string; aExpectedValues: array of string); var Ini: TCustomIniFile; IniFile: TIniFile absolute Ini; MemIniFile: TMemIniFile absolute Ini; StringsRead: TStringList; i: Integer; begin StringsRead := TStringList.Create; try // Safe way of instantion because of polymorfism lack in standard Ini classes from IniFiles //Ini := aIniClass.Create(TestFileName); if aIniClass = TIniFile then IniFile := TIniFile.Create(TestFileName) else if aIniClass = TMemIniFile then MemIniFile := TMemIniFile.Create(TestFileName) else Fail(Format('Unexpected Ini class %s', [aIniClass.ClassName])); try if aSection = NO_SECTION then Ini.ReadSections(StringsRead) else Ini.ReadSections(aSection, StringsRead); CheckEquals(High(aExpectedValues) - Low(aExpectedValues) + 1, StringsRead.Count); for i := Low(aExpectedValues) to High(aExpectedValues) do CheckEquals(aExpectedValues[i], StringsRead[i], Format('Testing section %s', [aExpectedValues[i]])); finally FreeAndNil(Ini); end; finally FreeAndNil(StringsRead); end; end; procedure TIniReadSectionsBehaviourTester.ReadSectionValuesAndCheckThem(const aIniClass: TMyIniClass); const UseSection = 'Section3'; var Ini: TCustomIniFile; IniFile: TIniFile absolute Ini; MemIniFile: TMemIniFile absolute Ini; ExtraNrOfCommentedKeys: Integer; StringsRead: TStringList; i: Integer; ValueInIni: string; begin // Test to check that ReadSectionValues reads the correct number of keys from a section and reads // the correct value for each key. // The standard Ini classes from IniFiles do not remove extra comments. Here we adjust for that by // increasing the number of expected keys with the number of keys that have been commented out by // non-standard-Windows means (';'). ExtraNrOfCommentedKeys := 0; if ( aIniClass = TIniFile ) or ( aIniClass = TMemIniFile ) then ExtraNrOfCommentedKeys := 1; // Safe way of instantion because of polymorfism lack in standard Ini classes from IniFiles //Ini := aIniClass.Create(TestFileName); if aIniClass = TIniFile then IniFile := TIniFile.Create(TestFileName) else if aIniClass = TMemIniFile then MemIniFile := TMemIniFile.Create(TestFileName) else Fail(Format('Unexpected Ini class %s', [aIniClass.ClassName])); try StringsRead := TStringList.Create; try Ini.ReadSectionValues(UseSection, StringsRead); CheckEquals(ExtraNrOfCommentedKeys + High(KEYS_IN_SECTION_3) - Low(KEYS_IN_SECTION_3) + 1, StringsRead.Count, UseSection + ' in test file has a different number of keys than expected'); for i := Low(KEYS_IN_SECTION_3) to High(KEYS_IN_SECTION_3) do begin ValueInIni := Ini.ReadString(UseSection, KEYS_IN_SECTION_3[i], '<<<Fout>>>'); CheckEquals(True, StringsRead.IndexOfName(KEYS_IN_SECTION_3[i]) > -1, Format('Key %s not found in StringsRead', [KEYS_IN_SECTION_3[i]])); CheckEquals(ValueInIni, StringsRead.Values[KEYS_IN_SECTION_3[i]], Format('Value of key %s in StringsRead is different', [KEYS_IN_SECTION_3[i]])); end; finally FreeAndNil(StringsRead); end; finally FreeAndNil(Ini); end; end; // =============================== ReadSections - TIniFile ========================================= procedure TIniReadSectionsBehaviourTester.IniFile_ReadSectionsZonderSectionParameter; begin ReadSectionsAndCheckThem(TIniFile, NO_SECTION, SECTIONS_IN_TEST); end; procedure TIniReadSectionsBehaviourTester.IniFile_ReadSectionsMetSectionParameter_LegeWaarde; begin ReadSectionsAndCheckThem(TIniFile, '', SECTIONS_IN_TEST); end; procedure TIniReadSectionsBehaviourTester.IniFile_ReadSectionsMetSectionParameter_ExacteWaarde; begin ReadSectionsAndCheckThem(TIniFile, EXACT_SECTION_NAME, [EXACT_SECTION_NAME]); end; procedure TIniReadSectionsBehaviourTester.IniFile_ReadSectionsMetSectionParameter_GedeeltelijkeWaarde; begin ReadSectionsAndCheckThem(TIniFile, PARTIAL_SECTION_NAME, SECTIONS_IN_PARTIAL_TEST); end; procedure

TIniReadSectionsBehaviourTester.IniFile_ReadSectionsMetSectionParameter_NietBestaandeWaarde; begin ReadSectionsAndCheckThem(TIniFile, NON_EXISTENT_SECTION_NAME, []); end; // =============================== ReadSections - TMemIniFile ====================================== procedure TIniReadSectionsBehaviourTester.MemIniFile_ReadSectionsZonderSectionParameter; begin ReadSectionsAndCheckThem(TMemIniFile, NO_SECTION, SECTIONS_IN_TEST); end; procedure TIniReadSectionsBehaviourTester.MemIniFile_ReadSectionsMetSectionParameter_LegeWaarde; begin ReadSectionsAndCheckThem(TMemIniFile, '', SECTIONS_IN_TEST); end; procedure TIniReadSectionsBehaviourTester.MemIniFile_ReadSectionsMetSectionParameter_ExacteWaarde; begin ReadSectionsAndCheckThem(TMemIniFile, EXACT_SECTION_NAME, [EXACT_SECTION_NAME]); end; procedure TIniReadSectionsBehaviourTester.MemIniFile_ReadSectionsMetSectionParameter_GedeeltelijkeWaarde; begin ReadSectionsAndCheckThem(TMemIniFile, PARTIAL_SECTION_NAME, SECTIONS_IN_PARTIAL_TEST); end; procedure TIniReadSectionsBehaviourTester.MemIniFile_ReadSectionsMetSectionParameter_NietBestaandeWaarde; begin ReadSectionsAndCheckThem(TMemIniFile, NON_EXISTENT_SECTION_NAME, []); end; // =============================== ReadSectionValues =============================================== procedure TIniReadSectionsBehaviourTester.IniFile_ReadSectionValuesAndCheckThem; begin ReadSectionValuesAndCheckThem(TIniFile); end; procedure TIniReadSectionsBehaviourTester.MemIniFile_ReadSectionValuesAndCheckThem; begin ReadSectionValuesAndCheckThem(TMemIniFile); end; initialization RegisterTest('Ini', TIniReadSectionsBehaviourTester.Suite); end.

QC #: 85895 - Status: Closed

QC #: Project Date Reported: Area:85895 Delphi 7/2/2010 VCL\Additional Controls\TColorBox

Description Steps:[QC Short Description] In some cases TColorBox.Selected property does not work properly. [QC Description] In some cases TColorBox.Selected property does not work properly. QC Entry 85895 Added by Sysop <<<<<<<<<<<<<<<<<< I think this issue is due to lazy initialization behavior of TColorBox. So, as a woraround, we need to access its Handle property before setting color. ------------ ... Form2.ColorBox1.Handle; // <<---- add this line Form2.ColorBox1.Selected := clRed; Form2.ShowModal; ... ------------ >>>>>>>>>>>>>>>>>> [SB: as auto reg]

1.Place a TColorBox to a secondary form. 2.Set Style property of a TColorBox to [cbStandardColors, cbCustomColor, cbPrettyNames] in the Object Inspector (not by the code!). 3.Add code to the master form: Form2 := TForm2.Create(nil); try Form2.PopupParent := Self; Form2.ColorBox1.Selected := clRed; Form2.ShowModal; finally Form2.Free; end; Selected color will be clBlack.

QC #: 85960 - Status: Closed

QC #: Project Date Reported: Area: 85960 Delphi 7/5/2010 Compiler\Delphi\Generics Description Steps:[QC Short Description] threadvar + generic class = [DCC Fatal Error] F2084 Internal Error: G5993 [QC Description]

program Project112; {$APPTYPE CONSOLE} uses SysUtils, Forms; type TestClass<T> = class class threadvar I : Integer; end; Test = TestClass<TForm>; begin try { TODO -oUser -cConsole Main : Insert code here } except on E: Exception do Writeln(E.ClassName, ': ', E.Message); end; end.

threadvar's in generic classes cause [DCC Fatal Error] Unit6.pas(28): F2084 Internal Error: G5993 Test case: type TestClass<T> = class class threadvar I : Integer; end; Test = TestClass<TForm>; QC Entry 85960

QC #: 85966 - Status: Closed

QC #: Project Date Reported: Area: 85966 Delphi 7/5/2010 Compiler\Delphi\Generics Description Steps:[QC Short Description] Hiding virtual method + nested generics = Internal Error: AV0745BC74-R0000001E-0 [QC Description] [DCC Fatal Error] F2084 Internal Error: AV0745BC74-R0000001E-0 is caused when hiding a virtual method in nested generic classes across ACROSS two units and I think at least three classes. The compiler should instead output a warning that the method had been hidden. Although this is quite simple to work-around it is still serious because it took hours to determine the exact cause. This is best described by looking the code: Unit A: type TOuterA<T : class> = class type TInnerA = class procedure Faulty; virtual; abstract; end; end; TOuterB<T : class> = class (TOuterA<T>) type TInnerB = class (TOuterA<T>.TInnerA) end; end; Unit B: TOuterC<T : class> = class(TOuterB<T>) type TInnerC = class(TOuterB<T>.TInnerB) procedure Faulty; virtual; end; end; QC Entry 85966

Create a package, add the following units: unit UnitA; interface type TOuterA<T : class> = class type TInnerA = class procedure Faulty; virtual; abstract; end; end; TOuterB<T : class> = class (TOuterA<T>) type TInnerB = class (TOuterA<T>.TInnerA) end; end; implementation end. --- unit UnitB; interface uses UnitA; type TOuterC<T : class> = class(TOuterB<T>) type TInnerC = class(TOuterB<T>.TInnerB) procedure Faulty; virtual; end; end; implementation end.

QC #: 85979 - Status: Closed

QC #: Project Date Reported: Area:

85979 Delphi 7/5/2010 Database\DataSnap Description Steps:[QC Short Description] TSqlServerMethod.ServerMethodName have 'Select' word error [QC Description] if TSqlServerMethod.ServerMethodName include 'Select' word, (for example:TmySelectServerMethod.SelectMethod), TSqlServerMethod happen error: TmySelectServerMethod.SelectMethodWhereSQL method not found in the server method list this error code in the SqlExpr.pas, line 5777: function TCustomSQLDataSet.CheckDetail(const SQL: UnicodeString): UnicodeString; begin Result := SQL; if pos(SParam, SQL) = 0 then if pos(SSelect, UnicodeString(WideLowerCase(SQL))) > 0 then // Select Query with no ?, but Parameters are set Result := AddParamSQLForDetail(Params, SQL, True); end; QC Entry 85979

DataSnapRDM.Native.DB.Test.exe connection=DSTCP_WIN32 -s:TestRaid_278160 -or- if TSqlServerMethod.ServerMethodName include 'Select' word, (for example:TmySelectServerMethod.SelectMethod), run TSqlServerMethod.ExecuteMethod happen error: TmySelectServerMethod.SelectMethodWhereSQL method not found in the server method list this error caused by code in the SqlExpr.pas, line 5777: function TCustomSQLDataSet.CheckDetail(const SQL: UnicodeString): UnicodeString; begin Result := SQL; if pos(SParam, SQL) = 0 then if pos(SSelect, UnicodeString(WideLowerCase(SQL))) > 0 then <=== error happen!!!!!! it is not must be sql statement. //SQL is TmySelectServerMethod.SelectMethod Result := AddParamSQLForDetail(Params, SQL, True); end;

QC #: 85993 - Status: Resolved

QC #: Project Date Reported: Area: 85993 Delphi 7/6/2010 VCL\Thread support Description Steps:[QC Short Description] TThread.Synchronize method doesn't work in an OCX [QC Description] In an OCX project which create a TThread object, the call to the method Synchronize is never executed See the ttached project group : 1) Compile and register the server project 2) Compile and execute the client project 3) Observe that the value displayed by the Active Form is never update because the Synchronize method doesn't work. QC Entry 85993

1) Create an OCX application Create a new thread class type In the Execute method of this new class, call the Synchronize method Create an Active Form In the Active Form create an instance of the previous thread class and invoke the capability of the thread which calls the Synchronize method. 2) Create a client application for the previous Active Form 3) Check the termination of the Synchronize method Open the attached project group : 1) Compile and register the server project 2) Compile and execute the client project 3) Observe that the value display is never update because the Synchronize method doesn't work.

QC #: 86035 - Status: Closed

QC #: Project Date Reported: Area: 86035 C++Builder 7/7/2010 IDE\Code Completion Description Steps:[QC Short Description] Code Insight crash [QC Description] Code Insight stops working when a certain header file (third party) is included in the project. Using the Kibitz Error Message function written by Moritz Beutel shows the following error message: [BCC Kibitz Message] preProcess.cpp(155): F1004 Internal compiler

Detailed steps to reproduce: - download the attachment - create a new VCL Console or Forms application - add preProcess.cpp (from the attachment) to the project - open preProcess.cpp in the editor, go to line 914007 - place the cursor after "networkDiagram->" and hit Ctrl+Space. Exp.: Code Completion listbox appears Act.: Nothing happens.

error at 0x654886e with base 0x6520000 At his suggestion, I've preprocessed one of the source files and attached it here. Note that the application compiles and runs without error. Also note that when I move all the source code to BCB6, code insight works properly. QC Entry 86035

Optional to use Moritz' Kibitz Error Message expert: - download and install the expert at http://mb.audacia-software.de/pfiles/KibitzErrorsExpert.zip (see readme.txt for detailed instructions) - enable the "Kibitz Errors Expert" in the "Help" menu With this installed: Act.: "Kibitz Errors" message pane displays this: [BCC Kibitz Message] preProcess.cpp(155): F1004 Internal compiler error at 0x51ba26e with base 0x5190000

QC #: 86050 - Status: Closed

QC #: Project Date Reported: Area:86050 Delphi 7/7/2010 Compiler\Delphi\Errors - Warnings

Description Steps:[QC Short Description] Weaver - Internal Compiler Error C4609 Fulcrum - Internal Compiler Error C4747 QC Entry 86050

The following code produces Internal Error: C4609 on compilation: program Project1; {$APPTYPE CONSOLE} var i:integer; begin for i:=0 to 1000 do begin while true do begin end; if (i and 7)=0 then begin end; end; end. This happens both when the loops have meaningful code inside and when they are empty, as in the example. More info: This issue works on the Fulcrum IDE build 15.0.3836.32265, but from the command line it doesn't work, showing Internal Compile Error C4747. On Weaver, build no 14.0.3593.25826, it shows Internal Compile Error from both the IDE and the command line.

QC #: 86159 - Status: Closed

QC #: Project Date Reported: Area: 86159 C++Builder 7/11/2010 Linker\ILINK32 Description Steps:[QC Short Description] ILINK32 creates invalid VMTs when dealing with Generics [QC Description] I have a C++ application (s. attachment) with a delphi unit that contains a procedure that calls TList<string>.Create. Calling that procedure from the C++ application produces an Access Violation in TObject.CreateInstance. Apparently the ClassParent pointer becomes invalid. As it turns out the parent pointer of TList<string> does not point to TEnumerable<string> but instead to an entry in the module's import table that references the instance of TEnumerable<string> that is

1. Open, compile and run the attached project. 2. Click the button.

contained in rtl140.bpl. Consequently the following code also crashes: TEnumerable<string>.ClassName; since TEnumerable<string> points to the import table and not the VMT. Of course this only happens when linking against runtime packages. QC Entry 86159

QC #: 86180 - Status: Closed

QC #: Project Date Reported: Area:86180 Delphi 7/11/2010 IDE\Code Editor\Formatting Description Steps:[QC Short Description] Ctrl+D formates without confirmation [QC Description] If you fail pressing Ctrl+S to save the source and inspite you hit Ctrl+D the code is formatted without any confirmation request. Then if you automatically hit Ctrl+S again, this time correct, you have a hard job to do. If you have than to reformat 15000 code rows, maybe repeated times, this is a real disaster. QC Entry 86180

Hit Ctrl+D and wait on the confirmation to reformat: You get all formatted without it.

QC #: 86205 - Status: Closed

QC #: Project Date Reported: Area: 86205 Delphi 7/12/2010 Midas\TClientDataSet Description Steps:[QC Short Description] ClientDataset.Locate fails on boolean fields (w/Fix) [QC Description] When trying to use clientdataset locate function it fails if one of the fields you're trying to locate is a boolean type; the formatting of the filter string is improper in DBClient.pas line ~4143; QC Entry 86205

TDBXFulcrumBugsSuite.Native.DB.Test.exe connection=ibconnection -s:TestRaid_278336 -OR- if cliendataset.Locate('Stringfiledname;BoolFieldname;', VarArrayOf(['searchtext',true]),[]) then showmessage('success') else showmessage('fail'); Will always fail to locate a record!

QC #: 86231 - Status: Closed

QC #: Project Date Reported: Area: 86231 C++Builder 7/13/2010 VCL\Exceptions Description Steps:[QC Short Description] HandleException() crashes outside the IDE [QC Description] Calling HandleException() in an application that is run outside the IDE yields an Access Violation (read of address 00000000).

bcc32 -tCV 278335.cpp 278330.exe res: * * * CRASHED * * *

According QC#1826 this has been fixed long ago, but apparently hasn't. QC Entry 86231 Added by Sysop <<<<<<<<<<<<<< This issue is same as RAID#201931. >>>>>>>>>>>>>>

QC #: 86282 - Status: Closed

QC #: Project Date Reported: Area: 86282 Delphi 7/14/2010 RTL\Delphi\Other RTL Description Steps:[QC Short Description] TStringBuilder.replace does not work [QC Description] TStringBuilder.replace will stack overflow and access violate if the replacement string is longer than the find string. QC Entry 86282 [SB: has auto test]

Create a new form, and a button, and then use this code in the onclick event: procedure TForm21.Button1Click(Sender: TObject); var StringBuilder: TStringbuilder; InitialData, ReplaceData, a: string; Capacity: Integer; i: Integer; begin StringBuilder := TStringBuilder.Create; try //Create some initial data InitialData := 'bbbb'; for i := 1 to 10 do InitialData := InitialData + InitialData; //Add the data to the StringBuilder StringBuilder.Append(InitialData); //Define some replacement text which is larger than InitialData ReplaceData := 'aaaa'; for i := 1 to 10 do ReplaceData := ReplaceData + ReplaceData; //The following line will stack overflow and access violate a := StringBuilder.Replace('bbb', ReplaceData).ToString; ShowMessage(a); finally StringBuilder.Free; end; end;

QC #: 86292 - Status: Closed

QC #: Project Date Reported: Area: 86292 Delphi 7/15/2010 IDE\Class Completion Description Steps:[QC Short Description] Class complition with "inline" record fields. [QC Description] Class complition (Shift+Ctrl+C) in a *whole* unit will be blocked if the code like this is present: type TMy = class private FField1: record F1: Integer; F2: Integer; end; public procedure P; // Shift+Ctrl+C here end; You !SHOULD! support this complitely VALID Pascal syntax in the class complition parser. As I understand this simplified parser should be able to properly skip record...end pairs. Same problem with local variables... This prevent me from writing laconic code without unnessessary, explicitly declared types. QC Entry 86292

QC #: 86323 - Status: Closed

QC #: Project Date Reported: Area:86323 Delphi 7/16/2010 IDE\Code Editor\Formatting Description Steps:[QC Short Description] Nested case statements in type definitions are not formatted correct [QC Description] Code formatter ignores formatter settings in nested case statements in type definition. On the first level, the rules are used correct. QC Entry 86323

Enter code like this: TFoo = packed record case Integer of 0: (dwTic: DWord; case Integer of 0: (wTac: Word; wToe: Word; ); 1: (dwTric: DWord; ); ); 255: (abyByteArray: array [0 .. 11] of Byte); end; Press <ctrl>+D Result: TFoo = packed record case Integer of 0: (dwTic: DWord; case Integer of 0: (wTac: Word; wToe: Word; ); 1: (dwTric: DWord; ); ); 255: (abyByteArray: array [0 .. 11] of Byte); end; Expected result: TFoo = packed record case Integer of 0: (dwTic: DWord; case Integer of 0: (wTac: Word; wToe: Word; ); 1: (dwTric: DWord; ); ); 255: (abyByteArray: array [0 .. 11] of Byte); end;

QC #: 86335 - Status: Closed

QC #: Project Date Reported: Area: 86335 C++Builder 7/16/2010 CodeGuard Description Steps:[QC Short Description] CG Error if two CRTDLLs are loaded QC Entry 86335

Two Projects: - First Project is DLL with DynamicRTL (must be Dynamic) - Second Project is EXE (Console) with DynamicRTL The EXE loads the DLL on startup (Binding 2). The CodeGuard reports a error saying that two different CRTDLLs are loaded (name of the DLL-Project) (c:\windows\system32\cc32100mt.dll) This behavior is new in C++ Builder 2010. Older version worked fine. We need a solution on that, since we strongly relay on CodeGuard for Code Quality reasons.

QC #: 86364 - Status: Closed

QC #: Project Date Reported: Area: 86364 C++Builder 7/17/2010 VCL\Graphics Description Steps:[QC Short Description] Unresolved External SetPrinter [QC Description] I am using RAD Studio 2010 with all the latest updates applied to it (v 14.0.3593.25826) and am having trouble with the following method: function SetPrinter(NewPrinter: TPrinter): TPrinter; When I try and use this function I get an unresolved external linker error. QC Entry 86364

This can be simulated by starting a new project and putting in the following code: TPrinter *new_printer = new TPrinter(); TPrinter *old_printer = SetPrinter(new_printer); When I try and build this I get: [ILINK32 Error] Error: Unresolved external '__fastcall Printers::SetPrinterA(Printers::TPrinter *)'

QC #: 86394 - Status: Closed

QC #: Project Date Reported: Area: 86394 C++Builder 7/19/2010 RTL\C++\Header Files Description Steps:

[QC Short Description] Missing #pragma alias statements in several headers [QC Description] Many of the RTL/VCL header files use #pragma alias statements when _VCL_ALIAS_RECORDS is defined to re-map function/method names that were incorrectly altered by #define statements in Win32 API headers. However, several RTL/VCL headers, such as StrUtils.hpp, are missing aliases. A code review of all RTL/VCL header files needs to be done so missing aliases can be inserted where needed. QC Entry 86394

#include <StrUtils.hpp> UnicodeString s = ReplaceText(L"1 2 3 4 5", L"2", L"1"); Expected: compiles Actual: [ILINK32 Error] Error: Unresolved external '__fastcall Strutils::ReplaceTextW(const System::UnicodeString, const System::UnicodeString, const System::UnicodeString)' referenced from "...".

QC #: 86542 - Status: Closed

QC #: Project Date Reported: Area: 86542 Delphi 7/23/2010 Compiler\Delphi\Generics Description Steps:[QC Short Description] SizeOf returns an invalid value for an open array parameter based on generic type parameter [QC Description] The sample program outputs the size of the static array "a". Both methods are expected to return 12 (=sizeof(integer)*length(a)), however only G<T>.bar returns the proper value. SizeOf in G<T>.foo effectively returns the length of "a" instead of its size. QC Entry 86542

Compile and run that attached application below. See the following program output indicating failure. FAIL Value1=3 Value2=12 program BTS278818; { SizeOf returns an invalid value for an open array parameter based on generic type parameter } {$apptype console} type G<T> = class class function foo(const a: array of T): integer; class function bar(const a: array of integer): integer; end; class function G<T>.foo(const a: array of T): integer; begin result := sizeof(a) end; class function G<T>.bar(const a: array of integer): integer; begin result := sizeof(a) end; var a: array[0..2] of integer = (1,2,3); procedure DoTest; var Value1: Integer; Value2: Integer; begin Value1 := G<integer>.foo(a); Value2 := G<integer>.bar(a); if Value1 = Value2 then WriteLn('PASS') else WriteLn('FAIL Value1=', Value1, ' Value2=', Value2); end; begin try

DoTest; except on E: TObject do WriteLn('FAIL - Exception'); end; end.

QC #: 86558 - Status: Closed

QC #: Project Date Reported: Area:86558 Delphi 7/24/2010 Compiler\Delphi\Error Recovery

Description Steps:[QC Short Description] Error recovery from "class of generic/instantiated type" results in ICE [QC Description] Try to compile the sample program: the compiler crashes attempting to instantiate G<integer>. QC Entry 86558

type G<T> = class public type ref = class of G<T>{G<integer>}; // Error: E2029 ';' expected but '<' found end; var a: G<integer>; // F2084 Internal Error: AV0044A3C5-R00000010-0 begin end.

QC #: 86566 - Status: Closed

QC #: Project Date Reported: Area: 86566 Delphi 7/24/2010 Compiler\Delphi Description Steps:[QC Short Description] Internal errors URW1831 and I3418 caused by inlining and $TypedAddress [QC Description] Try to compile the unit "test": test.pas(19) Fatal: F2084 Internal Error: URW1831 Try to compile it the second time (note that a.dcu already exists): test.pas(16) Fatal: F2084 Internal Error: I3418 QC Entry 86566

--8<-------8<-------8<--- a.pas unit a; interface procedure X; implementation procedure X; begin end; end. --8<-------8<-------8<--- test.pas unit test; interface function offender: pointer; inline; // remove "inline" to avoid an ICE implementation uses a; {$TypedAddress on} // remove this to avoid an ICE function offender: pointer; begin result := @X end; end. --8<-------8<-------8<---

QC #: 86572 - Status: Closed

QC #: Project Date Reported: Area: 86572 Delphi 7/24/2010 Database\TField Description Steps:[QC Short Description] TField.AssignValue() doesn't handle all possible types of TVarRec [QC Description] TField.AssignValue() consists of one big "case AVarRec.VType of" statement, but one case is incorrect and another one is missing. The following snippet should illustrate both the problem and the fix: // ----- // DB.pas, l. 4265ff procedure TField.AssignValue(const Value: TVarRec); ... begin with Value do case VType of ... vtPChar:

TDBXFulcrumBugsSuite.Native.DB.Test.exe connection=ibconnection -s:TestRaid_278924 -OR- Unzip the attached project and run it. Caption should show: "Foo" for both fields. ------------------------- Old Steps: In a new VCL Forms application, insert, build and run this code: // ----- uses DB, DBTables;

AsString := string(VPChar); + vtPWideChar: + AsString := string(VPWideChar); ... vtVariant: if not VarIsClear(VVariant^) then AsVariant := VVariant^; vtWideString: - AsWideString := UnicodeString(VWideString); + AsWideString := WideString(VWideString); vtInt64: AsVariant := VInt64^; vtUnicodeString: AsString := string(VUnicodeString); else Error; end; end; // ----- QC Entry 86572

procedure TForm2.FormCreate(Sender: TObject); var table : TTable; WC: PWideChar; begin table := TTable.Create (nil); table.FieldDefs.Add ('test', ftInteger); table.IndexDefs.Add ('primary', 'test', [ixPrimary]); table.DatabaseName := ExtractFilePath (Application.ExeName); table.TableName := 'tester.db'; table.CreateTable; table.Open; WC := '8'; try table.FindKey ([WC]); except on e: Exception do ShowMessage (e.Message); end; end; // ----- Exp.: no exception Act.: EDatabaseError: 'Invalid value for field 'test'' While it's easy to demonstrate the failure for the missing "case vtPWideChar", the mistake in "case vtWideString" usually goes unnoticed, mostly because SetAsWideString() takes a "const UnicodeString" and doesn't modify the reference count unless an error occurs. In this case, it may modify the reference count of what it thinks is an UnicodeString, but it in fact it corrupts memory because the string is actually a WideString

QC #: 86768 - Status: Closed

QC #: Project Date Reported: Area: 86768 Delphi 7/30/2010 VCL\Graphics Description Steps:[QC Short Description] TIcon does not support loading 256x256 icons correctly [QC Description] TIcon does not correctly support 256x256 icons. The width and height fields in the ICO header are 0, since they are stored as single bytes and thus cannot contain values of 256. When loading a 256x256 icon using TIcon.LoadFrom...(), the resulting TIcon.Width and TIcon.Height properties are 0, not 256. On some systems, this incompatibility in TIcon is causing EOutOfResource exceptions to be raised, such as when assigning such as TIcon to a TBitmap. If Graphics.ReadIcon() is tweaked to assume width/height=256 when it encounters width/height=0 in the ICO header, then everything works ok. QC Entry 86768

var Icon : TIcon; Bitmap : TBitmap; begin Icon := TIcon.Create; try Bitmap := TBitmap.Create; try Icon.LoadFromFile('c:\temp\bigicon.ico'); // <- use a 256x256 icon file, see attached Bitmap.Width := Icon.Width; // <-- will be 0, somes raises EOutOfResources Bitmap.Height := Icon.Height; // <-- will be 0 Bitmap.Canvas.Draw(0, 0, Icon ) ; Bitmap.SaveToFile('c:\temp\bigicon.bmp') ; finally Bitmap.Free; end; finally Icon.Free; end; end;

QC #: 86771 - Status: Closed

QC #: Project Date Reported: Area:

86771 Delphi 7/30/2010 Compiler\Delphi\Code Generation/Optimization

Description Steps:

[QC Short Description] Wrong Self with an event in a packed record and a stdcall procedure [QC Description] Calling an event, which has been passed within a packed record with a specific size, in a stdcall procedure or in another method or class method called from a stdcall procedure fails, because Self is wrong. (Noticed by USc when working on some old code with D2010. The actual code uses stdcall and packed record due to historical reasons and can be changed to workaround the problem.) This is regression that obviously happend between D7 and D2005. -> see steps QC Entry 86771

- save the attachment or the following code - dcc32 EventInRecordStdCallTest.dpr - execute EventInRecordStdCallTest.exe expected: PASS actual: FAIL see #1, #2 and #3 - fails only with packed record, a specific record size and stdcall program EventInRecordStdCallTest; {$APPTYPE CONSOLE} type TFooProgressEvent = procedure of object; TFooCalculationValues = packed record//#1 PaddingBytes: array[0..30] of Byte;//#2 fails with 14, 18, 22, 26, ... OnProgress: TFooProgressEvent; end; procedure CalculateFoo(AValues: TFooCalculationValues); stdcall;//#3 begin AValues.OnProgress(); end; type TFooTestClass = class(TObject) private procedure DoFooProgress; public constructor Create; destructor Destroy; override; procedure TestCalculateFoo; end; var FooInstancePointer: TFooTestClass = nil; Counter: Integer = 0; { TFooTestClass } constructor TFooTestClass.Create; begin Assert(not Assigned(FooInstancePointer)); FooInstancePointer := Self; end; destructor TFooTestClass.Destroy; begin FooInstancePointer := nil; inherited Destroy; end; procedure TFooTestClass.DoFooProgress; begin if Self = FooInstancePointer then Inc(Counter); end; procedure TFooTestClass.TestCalculateFoo; var InRec: TFooCalculationValues; begin InRec.OnProgress := DoFooProgress; CalculateFoo(InRec); end; var FooTest: TFooTestClass; begin FooTest := TFooTestClass.Create; try FooTest.TestCalculateFoo; finally FooTest.Free; end; if Counter = 1 then WriteLn('PASS') else WriteLn('FAIL'); end.

QC #: 86911 - Status: Closed

QC #: Project Date Reported: Area: 86911 Delphi 8/4/2010 IDE\Code Editor\ Description Steps:[QC Short Description] class operator identation error [QC Description] unit ufmMain; interface uses Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms, Dialogs, StdCtrls, ComCtrls, clCookies, clTcpClient, clHttp, ExtCtrls; type TfmMain = class(TForm) FclHttpPoster: TclHttp; FclCookieMng: TclCookieManager; lbl1: TLabel; FedtURL: TEdit; lbl2: TLabel; FcbxType: TComboBox; lbl3: TLabel; FlvPost: TListView; FbtnAdd: TButton; FbtnDelete: TButton; FbtnSave: TButton; FTray: TTrayIcon; lbl4: TLabel; FedtCycle: TEdit; lbl5: TLabel; FStat1: TStatusBar; FtmrUp: TTimer; FbtnRun: TButton; lbl6: TLabel; FedtUserName: TEdit; lbl7: TLabel; FedtPassword: TEdit; procedure FbtnAddClick(Sender: TObject); procedure FbtnDeleteClick(Sender: TObject);

See lines 138, 151 Added by Sysop <<<<<<<<<<<<<<<<<<<<<<<<<<<< After lines 138, 151 have a blank line! class operator TSiteInfo.Equal(A, B: TSiteInfo): Boolean; var I: Integer; begin Result := True; I := 0; while Result and (I < 255) do begin Result := A.URL[I] = B.URL[I]; I := I + 1; end; end; // ========================>>>> Like to: class operator TSiteInfo.Equal(A, B: TSiteInfo): Boolean; var I: Integer; begin Result := True; I := 0; while Result and (I < 255) do begin Result := A.URL[I] = B.URL[I]; I := I + 1; end; end; >>>>>>>>>>>>>>>>>>>>>>>>>>>> [vk] Fixed "operator" keyword support. But user empty line is saved in the source code because of parameter "Maximum Number of Empty lines = 1". Change it to 0 please

procedure FbtnRunClick(Sender: TObject); procedure FTrayClick(Sender: TObject); private procedure SaveData(); public { Public declarations } end; var fmMain: TfmMain; implementation {$R *.dfm} type TSiteInfo = packed record URL: string[255]; SiteType: Byte; UserName, Password: string[64]; procedure Assign(A: string); class operator Equal(A, B: TSiteInfo): Boolean; class operator Equal(A: TSiteInfo; B: string): Boolean; class operator Equal(A: string; B: TSiteInfo): Boolean; end; procedure TfmMain.FbtnAddClick(Sender: TObject); var NewItem: TListItem; I: Integer; begin for I := 0 to FlvPost.Items.Count - 1 do if (FlvPost.Items[I].Caption = Trim(FedtURL.Text)) then Exit(); NewItem := FlvPost.Items.Add(); NewItem.Caption := Trim(FedtURL.Text); NewItem.SubItems.Add(FcbxType.Text); end; procedure TfmMain.FbtnDeleteClick(Sender: TObject); var I: Integer; begin I := 0; with FlvPost do while (I < Items.Count) do begin if (Items[I].Checked) then Items[I].Delete() else I := I + 1; end; SaveData(); end; procedure TfmMain.FbtnRunClick(Sender: TObject); var I: Integer; begin if (FtmrUp.Enabled = False) then begin try I := StrToInt(FedtCycle.Text); except ShowMessage('B?n chua nh?p chu k·'); Exit(); end; FtmrUp.Interval := I * 60 * 1000; FtmrUp.Enabled := True; FbtnRun.Caption := 'D?ng'; Hide(); end else begin FtmrUp.Enabled := False; FbtnRun.Caption := 'B?t d?u'; end;

end; procedure TfmMain.FTrayClick(Sender: TObject); begin Show(); BringToFront(); end; procedure TfmMain.SaveData(); var I: Integer; F: TextFile; A: TSiteInfo; begin try AssignFile(F, 'AutoSubmit.dat'); {$I-} Rewrite(F); {$I+} with FlvPost do for I := 0 to Items.Count - 1 do Writeln(F, Items[I].Caption, ' ', Items[I].SubItems[0]); finally CloseFile(F); end; end; { TSiteInfo } class operator TSiteInfo.Equal(A, B: TSiteInfo): Boolean; var I: Integer; begin Result := True; I := 0; while Result and (I < 255) do begin Result := A.URL[I] = B.URL[I]; I := I + 1; end; end; class operator TSiteInfo.Equal(A: TSiteInfo; B: string): Boolean; var T: TSiteInfo; begin FillChar(T, SizeOf(T), 0); T.URL := B; Result := A = T; end; procedure TSiteInfo.Assign(A: string); begin FillChar(Self, SizeOf(Self), 0); URL := A; end; class operator TSiteInfo.Equal(A: string; B: TSiteInfo): Boolean; begin Result := B = A; end; end. ///////////////////////////////////////////////////////// Aspect to:.... unit ufmMain; interface uses

Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms, Dialogs, StdCtrls, ComCtrls, clCookies, clTcpClient, clHttp, ExtCtrls; type TfmMain = class(TForm) FclHttpPoster: TclHttp; FclCookieMng: TclCookieManager; lbl1: TLabel; FedtURL: TEdit; lbl2: TLabel; FcbxType: TComboBox; lbl3: TLabel; FlvPost: TListView; FbtnAdd: TButton; FbtnDelete: TButton; FbtnSave: TButton; FTray: TTrayIcon; lbl4: TLabel; FedtCycle: TEdit; lbl5: TLabel; FStat1: TStatusBar; FtmrUp: TTimer; FbtnRun: TButton; lbl6: TLabel; FedtUserName: TEdit; lbl7: TLabel; FedtPassword: TEdit; procedure FbtnAddClick(Sender: TObject); procedure FbtnDeleteClick(Sender: TObject); procedure FbtnRunClick(Sender: TObject); procedure FTrayClick(Sender: TObject); private procedure SaveData(); public { Public declarations } end; var fmMain: TfmMain; implementation {$R *.dfm} type TSiteInfo = packed record URL: string[255]; SiteType: Byte; UserName, Password: string[64]; procedure Assign(A: string); class operator Equal(A, B: TSiteInfo): Boolean; class operator Equal(A: TSiteInfo; B: string): Boolean; class operator Equal(A: string; B: TSiteInfo): Boolean; end; procedure TfmMain.FbtnAddClick(Sender: TObject); var NewItem: TListItem; I: Integer; begin for I := 0 to FlvPost.Items.Count - 1 do if (FlvPost.Items[I].Caption = Trim(FedtURL.Text)) then Exit(); NewItem := FlvPost.Items.Add(); NewItem.Caption := Trim(FedtURL.Text); NewItem.SubItems.Add(FcbxType.Text); end; procedure TfmMain.FbtnDeleteClick(Sender: TObject); var I: Integer; begin I := 0;

with FlvPost do while (I < Items.Count) do begin if (Items[I].Checked) then Items[I].Delete() else I := I + 1; end; SaveData(); end; procedure TfmMain.FbtnRunClick(Sender: TObject); var I: Integer; begin if (FtmrUp.Enabled = False) then begin try I := StrToInt(FedtCycle.Text); except ShowMessage('B?n chua nh?p chu k·'); Exit(); end; FtmrUp.Interval := I * 60 * 1000; FtmrUp.Enabled := True; FbtnRun.Caption := 'D?ng'; Hide(); end else begin FtmrUp.Enabled := False; FbtnRun.Caption := 'B?t d?u'; end; end; procedure TfmMain.FTrayClick(Sender: TObject); begin Show(); BringToFront(); end; procedure TfmMain.SaveData(); var I: Integer; F: TextFile; A: TSiteInfo; begin try AssignFile(F, 'AutoSubmit.dat'); {$I-} Rewrite(F); {$I+} with FlvPost do for I := 0 to Items.Count - 1 do Writeln(F, Items[I].Caption, ' ', Items[I].SubItems[0]); finally CloseFile(F); end; end; { TSiteInfo } class operator TSiteInfo.Equal(A, B: TSiteInfo): Boolean; var I: Integer; begin Result := True; I := 0; while Result and (I < 255) do begin Result := A.URL[I] = B.URL[I]; I := I + 1; end; end; class operator TSiteInfo.Equal(A: TSiteInfo; B: string): Boolean; var T: TSiteInfo;

begin FillChar(T, SizeOf(T), 0); T.URL := B; Result := A = T; end; procedure TSiteInfo.Assign(A: string); begin FillChar(Self, SizeOf(Self), 0); URL := A; end; class operator TSiteInfo.Equal(A: string; B: TSiteInfo): Boolean; begin Result := B = A; end; end. QC Entry 86911

QC #: 86955 - Status: Closed

QC #: Project Date Reported: Area:86955 Delphi 8/5/2010 Documentation\Online Help\Object Pascal

Description Steps:[QC Short Description] Spelling error in compiler directive name SCOPEDEUNMS [QC Description] In the topic "Scoped Enums (Delphi)" ms-help://embarcadero.rs2010/rad/Scoped_Enums_(Delphi).html there is a spelling error in the directive's name, on line "Syntax {$SCOPEDEUNMS ON}, or {$SCOPEDENUMS OFF}" it is wrongly spelled SCOPEDEunMS instead of SCOPEDEnuMS in the "{$SCOPEDEUNMS ON}," part. Help update 3 installed. QC Entry 86955

QC #: 87047 - Status: Closed

QC #: Project Date Reported: Area: 87047 Delphi 8/9/2010 Midas\TClientDataSet Description Steps:[QC Short Description] Unable to use ByteField In Aggregate [QC Description] When building an aggregate if one of the fields is a Byte the code will complie, and not run. The error is imcompatible field type. aggregate was Sum(Float * SmallInt * Byte) I want to use a byte to reduce memory usage QC Entry 87047 Added by Sysop <<<<<<<<<< This issue is similar to RAID#275839(QC#83610) >>>>>>>>>>

TDBXFulcrumBugsSuite.Native.Db.Test.exe connection=ibconnection -s:TestRaid_279575 -OR- On form attached are 2 clientdatasets ClientDataSet1 has field OnSite defined as TByteField ClientDataSet2 has field OnSite defined as TSmallIntField There is an aggregate define in the Agg editor whicj is Tot_OnSite = Sum(Volume * Include * OnSite) If you open the fields editor then Create DataSet for ClientdataSet1 you get Tpye Mismatch error for ClientDataSet2 it creates the dataset

QC #: 87092 - Status: Closed

QC #: Project Date Reported: Area: 87092 Delphi 8/10/2010 RTL\Delphi Description Steps:[QC Short Description] Invalid summaries are calculated based on FMTBCD values [QC Description] Summing up elements of an array containing FMTBCD values produces different results when enumerating the array from the beginning to the end and vice versa. note: This bug can be reproduced in all IDEs starting from RAD 2007, but cannot be reproduced in Delphi 7. Our customers consider this bug critical when using FMTBCD fields for summary calculations. Please fix it. QC Entry 87092 (JJS) In Fulcrum, I am seeing an unexpected ERangeError on the statement "Sum1 := Sum1 + Data[I];", where the output of the programis seen as follows. #1 I=14 J=414 #2 Sum1=18891.8 Sum2=17811.569 #3 Data[I]=5.9 Data[J]=9410.5 #4 FAIL - Exception=ERangeError The break happens in FMTBcd.MoveBytesToRight while doing the add.

Using the attached program below and the attached data file. program FMTBCD_InvalidCalculations; {$APPTYPE CONSOLE} uses Classes, Variants, fmtBCD, SysUtils; procedure DoTest; var I, J: Integer; B: TBCD; // Data: array of Variant; Stream: TFileStream; Sum1, Sum2: Variant; L: Integer; Data: Variant; V: Variant; begin Stream := TFileStream.Create('bcd_data.dat', fmOpenRead or fmShareDenyNone); L := Stream.Size div SizeOf(TBCD); WriteLn('#0 L=', L); // SetLength(Data, L); Data := VarArrayCreate([0, L-1], varVariant); for I := 0 to L - 1 do begin Stream.ReadBuffer(B, SizeOf(TBCD)); // VarFMTBcdCreate(Data[I], B); VarFMTBcdCreate(V, B); Data[I] := V; end; Stream.Free; // calculate summaries of FMTBCD values Sum1 := 0; Sum2 := 0; J := L; //Length(Data); // for I := 0 to Length(Data) - 1 do for I := 0 to L-1 do begin Dec(J); WriteLn('#1 I=', I, ' J=', J); WriteLn('#2 Sum1=', Sum1, ' Sum2=', Sum2); WriteLn('#3 Data[I]=', Data[I], ' Data[J]=', Data[J]); WriteLn; WriteLn('#4'); Sum1 := Sum1 + Data[I]; WriteLn('#5'); Sum2 := Sum2 + Data[J]; WriteLn('#6'); end; if Sum1 <> Sum2 then raise EVariantError.CreateFmt('Invalid fmtBCD calculations' +

' DirectSum = %s, ReverseSum = %s', [VarToStr(Sum1), VarToStr(Sum2)]); end; begin try DoTest; except on E: TObject do WriteLn('FAIL - Exception=', E.ClassName); end; end.

QC #: 87161 - Status: Closed

QC #: Project Date Reported: Area: 87161 Delphi 8/12/2010 VCL Description Steps:[QC Short Description] TThemeServices.PaintBorder fails painting when control has left scrollbar [QC Description] TThemeServices.PaintBorder paints corner rect in the improper place, when control has left vertical scrollbar and EraseLRCorner parameter is True. There is: W := GetSystemMetrics(SM_CXVSCROLL); H := GetSystemMetrics(SM_CYHSCROLL); InflateRect(EmptyRect, -2, -2); with EmptyRect do EmptyRect := Rect(Left, Bottom - H, Left + W, Bottom) It should be: W := GetSystemMetrics(SM_CXVSCROLL); H := GetSystemMetrics(SM_CYHSCROLL); InflateRect(EmptyRect, -2, -2); with EmptyRect do if UseRightToLeftScrollBar then EmptyRect := Rect(Left, Bottom - H, Left + W, Bottom) else EmptyRect := Rect(Right - W, Bottom - H, Right, Bottom); See attachment for screenshots. QC Entry 87161

See attachment.

QC #: 87163 - Status: Closed

QC #: Project Date Reported: Area:87163 Delphi 8/12/2010 VCL\Core VCL Classes\TWinControl

Description Steps:[QC Short Description] WMNCPaint fails painting bevels when control has left scrollbar [QC Description] TWinControl.WMNCPaint paints bevel in the improper place, when control has left vertical scrollbar.

See attachment.

There is: WinStyle := GetWindowLong(Handle, GWL_STYLE); if (WinStyle and WS_VSCROLL) <> 0 then Inc(Right, GetSystemMetrics(SM_CYVSCROLL)); It should be: WinStyle := GetWindowLong(Handle, GWL_STYLE); if (WinStyle and WS_VSCROLL) <> 0 then if UseRightToLeftScrollBar then Dec(Left, GetSystemMetrics(SM_CYVSCROLL)) else Inc(Right, GetSystemMetrics(SM_CYVSCROLL)); See attachment for screenshots. QC Entry 87163

QC #: 87281 - Status: Closed

QC #: Project Date Reported: Area:87281 Delphi 8/16/2010 Compiler\Delphi\Other Compiler

Description Steps:[QC Short Description] {$ALIGN 8} does not align uint64 to QWORD boundary [QC Description] With {$ALIGN 8}, a record field of size uint64 or int64 (being 8 bytes in size) would be expected to be aligned to a QWORD/8-byte boundary in memory. However, it is aligned to a DWORD/4-byte boundary. Apparently, the same bug is present in Delphi 2009, but not in D2006 or D2007. QC Entry 87281

Run and examine the code appended below, taking note of the addresses reported for the uint64-typed fields. program D2010_Align8_Bug; {$APPTYPE CONSOLE} uses sysutils; type {$ALIGN 8} TRec8 = record b1: byte; u1, u2: uint64; end; var R8a, R8b: TRec8; procedure CheckAddr (var p; TargetAlignment: byte); var k,j: byte; i: integer; begin i:= integer (addr(p)); for k := 4 downto 0 do begin j:= 1 SHL k; if i mod j = 0 then begin write ('Addr= ',inttohex(i,8),'h - Aligned to: ',j,' - '); if j >= TargetAlignment then writeln ('OK') else writeln ('FAIL'); exit; end; end; end; begin CheckAddr (R8a.u1, 8); CheckAddr (R8a.u2, 8); CheckAddr (R8b.u1, 8); CheckAddr (R8b.u2, 8); readln; end.

QC #: 87292 - Status: Closed

QC #: Project Date Reported: Area: 87292 Delphi 8/16/2010 Midas\TClientDataSet Description Steps:[QC Short Description] Aggregate Returns Summing Errors [QC Description] Using an aggreate in a TClientDataSet at times returns an error for summed values, in my case did not check other aggregates. For example in a cds with 4 values, each value represents an Index, the sum of a field will return a sum of 2 index entries. The aggregate appears to not always follow the Index. Hence some index values appear to be linked, however not all. If you Filter the dataset on the Index, it will return the correct value. If turn off the aggregates, switch the index, restore the index then set the aggregates to active, it will then (from initial study) return the correct value. If you close and the open the CDS, you get the correct value. This appears to be a dynamic problem, were the index used by the aggregate does not follow the index used for selecting and sorting the

TDBXFulcrumBugsSuite.Native.Db.Test.exe -s:TestRaid_279838 -OR- Since this appears to be a dynamic problem see attached example. 1)Build and run example then 2)Click Start and 8 records will be processed, each entery has 2 records 3) Examine the results The upper grid is hooked to the data in a second CDS via a provider and yields the correct results The lower grid is hooked to the main CDS notice that the AggFT_Amt does not match FT_Amt of all entries and AggAdd doesn't match LFMJ_Added. 4) If you press Reset check 'Reset Index After Post' you will get the correct results. The Reset Index does 1) Turn Off aggregates

data QC Entry 87292

2) Switch Index 3) Restore Index 4) Turn On Aggregates I also found will building this, the cross linked values have other triggers if you uncheck 'Post Alternate Amount' this will not fail If you check 'Post Secondary Values' the cross linking is different.