View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0006159 | JEDI VCL | 00 JVCL Components | public | 2013-07-04 17:43 | 2015-09-14 13:20 |
Reporter | Arioch | Assigned To | AHUser | ||
Priority | normal | Severity | minor | Reproducibility | have not tried |
Status | closed | Resolution | fixed | ||
Product Version | Daily / GIT | ||||
Target Version | Fixed in Version | 3.48 | |||
Summary | 0006159: Two functions to be removed for XE2+ from JvJCLUtils | ||||
Description | function InvalidateRect(hWnd: HWND; const lpRect: TRect; bErase: BOOL): BOOL; begin Result := Windows.InvalidateRect(hWnd, @lpRect, bErase); end; function InvalidateRect(hWnd: HWND; lpRect: PRect; bErase: BOOL): BOOL; begin Result := Windows.InvalidateRect(hWnd, lpRect, bErase); end; -------- They are already in Windows.pas and due to this programs do not compile, instead throwing "ambiguous overloaded call" error -------- Also they should be marked "inline" | ||||
Tags | No tags attached. | ||||
|
http://stackoverflow.com/questions/17474753/ These declarations are to be removed for Delphi 2009+ |
2013-07-05 12:59
|
0006159_JvJCLUtils.pas.patch (1,011 bytes)
Index: JvJCLUtils.pas =================================================================== --- JvJCLUtils.pas (revision 13494) +++ JvJCLUtils.pas (working copy) @@ -471,8 +471,11 @@ function CreateScreenCompatibleDC: HDC; +{$IfNDef RTL200_UP} +// Else overloads are already in Windows.pas and this declaration may provoke "ambiguos call" error function InvalidateRect(hWnd: HWND; const lpRect: TRect; bErase: BOOL): BOOL; overload; {$IFDEF SUPPORTS_INLINE} inline; {$ENDIF} function InvalidateRect(hWnd: HWND; lpRect: PRect; bErase: BOOL): BOOL; overload; {$IFDEF SUPPORTS_INLINE} inline; {$ENDIF} +{$EndIf} { begin JvRLE } @@ -4060,6 +4063,7 @@ Result := CreateCompatibleDC(HDC_DESKTOP); end; +{$IfNDef RTL200_UP} function InvalidateRect(hWnd: HWND; const lpRect: TRect; bErase: BOOL): BOOL; begin Result := Windows.InvalidateRect(hWnd, @lpRect, bErase); @@ -4069,6 +4073,7 @@ begin Result := Windows.InvalidateRect(hWnd, lpRect, bErase); end; +{$EndIf} { begin JvRLE } |
|
Fixed in master branch. |
|
I used {$IfNDef RTL200_UP} You committed {$IFNDEF COMPILER12_UP} I wonder which is better. Actually the error is generated by RTL, not the compiler. If we consider RTL to be uniquely identified by compiler, then RTL_xxxx symbols in jedi.inc seem to be redundant and only waste attention span and name space. However if we'd think they matter - for code self-documenting if nothing else - then it looks RTL200_UP symbol is more proper choice. |
|
The JCL mainly uses the RTLxxx defines whereas the JVCL uses the COMPILERxx defines. |
|
I thin that could be documented, or unified between these tightly coupled projects |
Date Modified | Username | Field | Change |
---|---|---|---|
2013-07-04 17:43 | Arioch | New Issue | |
2013-07-04 18:59 | Arioch | Note Added: 0020554 | |
2013-07-05 12:59 | Arioch | File Added: 0006159_JvJCLUtils.pas.patch | |
2013-07-05 23:22 | AHUser | Note Added: 0020557 | |
2013-07-05 23:22 | AHUser | Status | new => resolved |
2013-07-05 23:22 | AHUser | Fixed in Version | => Daily / SVN |
2013-07-05 23:22 | AHUser | Resolution | open => fixed |
2013-07-05 23:22 | AHUser | Assigned To | => AHUser |
2013-08-20 17:16 | Arioch | Note Added: 0020585 | |
2013-08-20 17:16 | Arioch | Status | resolved => feedback |
2013-08-20 17:16 | Arioch | Resolution | fixed => reopened |
2013-08-20 22:18 | AHUser | Note Added: 0020586 | |
2013-08-23 10:02 | Arioch | Note Added: 0020594 | |
2013-08-23 10:02 | Arioch | Status | feedback => closed |
2013-08-23 10:02 | Arioch | Resolution | reopened => fixed |
2015-09-14 13:20 | obones | Fixed in Version | Daily / GIT => 3.48 |