digitalmars.D.bugs - [Issue 8591] New: typecons.RefCounted.refCountedPayload should be nothrow
- d-bugmail puremagic.com (23/23) Aug 26 2012 http://d.puremagic.com/issues/show_bug.cgi?id=8591
- d-bugmail puremagic.com (18/18) Aug 26 2012 http://d.puremagic.com/issues/show_bug.cgi?id=8591
- d-bugmail puremagic.com (16/16) Aug 27 2012 http://d.puremagic.com/issues/show_bug.cgi?id=8591
- d-bugmail puremagic.com (11/11) Sep 02 2012 http://d.puremagic.com/issues/show_bug.cgi?id=8591
- d-bugmail puremagic.com (7/8) Sep 02 2012 nothrow, pure, and @safe are inferred for templated functions and lambda...
- d-bugmail puremagic.com (9/9) Sep 02 2012 http://d.puremagic.com/issues/show_bug.cgi?id=8591
http://d.puremagic.com/issues/show_bug.cgi?id=8591 Summary: typecons.RefCounted.refCountedPayload should be nothrow Product: D Version: D2 Platform: All OS/Version: All Status: NEW Severity: normal Priority: P2 Component: Phobos AssignedTo: nobody puremagic.com ReportedBy: monarchdodra gmail.com --- Comment #0 from monarchdodra gmail.com 2012-08-26 10:51:04 PDT --- When autoInit == RefCountedAutoInitialize.no, then: refCountedPayload() (and "alias refCountedPayload this") should be nothrow. This can be fixed by declaring two different functions in a static if bloc... but this may break the auto doc? Fix is in pull request 736 https://github.com/D-Programming-Language/phobos/pull/736 -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------
Aug 26 2012
http://d.puremagic.com/issues/show_bug.cgi?id=8591 Jonathan M Davis <jmdavisProg gmx.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |jmdavisProg gmx.com --- Comment #1 from Jonathan M Davis <jmdavisProg gmx.com> 2012-08-26 11:01:30 PDT --- Marking it as nothrow should be completely unnecessary. The function is templated. nothrow should be inferred. And having to duplicate the function to have a nothrow and non-nothrow version is definitely undesirable. However, attribute inferrence seems to be very broken right now ( bug# 8504 ), so it wouldn't surprise me in the least if it's not being inferred properly in this case. Attribute inferrence seems to work _sometimes_, but I have yet to figure out under what conditions it does. It's _supposed_ to be inferred for all templated functions, delegates which are explicitly typed, and lambdas, but it only works in a fraction of those circumstances. -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------
Aug 26 2012
http://d.puremagic.com/issues/show_bug.cgi?id=8591 --- Comment #2 from monarchdodra gmail.com 2012-08-27 06:36:37 PDT --- I didn't know that nothrow could be inferred. Also, I completely agree that duplicating the function is, at best, un-desirable. Yet the inference doesn't wor;: However, I am not calling "refCountedPayload" directly, but the alias "alias refCountedPayload this". Maybe that is the reason? Or not, I just read #8504. Anyways, it is preventing me from marking other functions as unconditionally nothrow. I think that in the long run, it is better to have a single workaround, which can be centrally fixed later, rather than having a bunch of functions work around it, potentially never fixing some of those workaround. -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------
Aug 27 2012
http://d.puremagic.com/issues/show_bug.cgi?id=8591 --- Comment #3 from github-bugzilla puremagic.com 2012-09-02 10:29:54 PDT --- Commits pushed to master at https://github.com/D-Programming-Language/phobos https://github.com/D-Programming-Language/phobos/commit/46244164099ec139dad4282c167ea02caac2ecda Fixes for issue 8591 (nothrow) https://github.com/D-Programming-Language/phobos/commit/5272df64b29cc5245193c629a5fc15ab0ef2bcf6 Merge pull request #763 from monarchdodra/bug8591 Bug8591 -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------
Sep 02 2012
http://d.puremagic.com/issues/show_bug.cgi?id=8591 --- Comment #4 from Jonathan M Davis <jmdavisProg gmx.com> 2012-09-02 15:23:36 PDT ---I didn't know that nothrow could be inferred.nothrow, pure, and safe are inferred for templated functions and lambdas: http://dlang.org/function.html#function-attribute-inference -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------
Sep 02 2012
http://d.puremagic.com/issues/show_bug.cgi?id=8591 Jonathan M Davis <jmdavisProg gmx.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED Resolution| |FIXED -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------
Sep 02 2012