Re: RFR: 8298241: Replace C-style casts with JavaThread::cast [v2]

2022-12-19 Thread Doug Simon
On Thu, 15 Dec 2022 21:20:31 GMT, David Holmes wrote: >> This is a simple cleanup RFE to get rid of old-style C casts in relation to >> JavaThread. >> >> In many cases involving NULL/nullptr the cast could just be dropped. >> Sometimes a static cast is needed to disambiguate overloads. >> >>

Re: RFR: 8298241: Replace C-style casts with JavaThread::cast [v2]

2022-12-18 Thread David Holmes
On Thu, 15 Dec 2022 22:21:35 GMT, Doug Simon wrote: >> David Holmes has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Fixed commented examle. > > Is it possible to add a test based on grep to prevent re-introduction of the > unwanted C-st

Re: RFR: 8298241: Replace C-style casts with JavaThread::cast [v2]

2022-12-15 Thread Doug Simon
On Thu, 15 Dec 2022 21:20:31 GMT, David Holmes wrote: >> This is a simple cleanup RFE to get rid of old-style C casts in relation to >> JavaThread. >> >> In many cases involving NULL/nullptr the cast could just be dropped. >> Sometimes a static cast is needed to disambiguate overloads. >> >>

Re: RFR: 8298241: Replace C-style casts with JavaThread::cast [v2]

2022-12-15 Thread David Holmes
On Thu, 15 Dec 2022 07:07:26 GMT, Stefan Karlsson wrote: >> David Holmes has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Fixed commented examle. > > Marked as reviewed by stefank (Reviewer). Thanks for the reviews @stefank and @sspitsy

Re: RFR: 8298241: Replace C-style casts with JavaThread::cast [v2]

2022-12-15 Thread David Holmes
> This is a simple cleanup RFE to get rid of old-style C casts in relation to > JavaThread. > > In many cases involving NULL/nullptr the cast could just be dropped. > Sometimes a static cast is needed to disambiguate overloads. > > A couple of reinterpret_cast are needed when doing int/ptr conv