digitalmars.D.learn - Really? -- Error: function `object.Throwable.message` is not nothrow
- A Guy With a Question (2/2) Nov 28 2017 What's the clean way to extract the message that passes the
- Adam D. Ruppe (6/8) Nov 28 2017 I didn't even know it had a `message`... you should be able to
- Jonathan M Davis (10/18) Nov 28 2017 I think that message was added recently for the folks at Sociomantic,
- A Guy With a Question (1/1) Nov 28 2017 .msg worked. I will let you all live.
- A Guy With a Question (3/4) Nov 28 2017 Thanks!
What's the clean way to extract the message that passes the nothrow argument? Do I really have to embed another try catch?
Nov 28 2017
On Tuesday, 28 November 2017 at 23:41:28 UTC, A Guy With a Question wrote:What's the clean way to extract the message that passes the nothrow argument? Do I really have to embed another try catch?I didn't even know it had a `message`... you should be able to pull the `.msg` member directly though, which is a simple string and not a function at all. http://dpldocs.info/experimental-docs/object.Throwable.html
Nov 28 2017
On Tuesday, November 28, 2017 23:48:06 Adam D. Ruppe via Digitalmars-d-learn wrote:On Tuesday, 28 November 2017 at 23:41:28 UTC, A Guy With a Question wrote:I think that message was added recently for the folks at Sociomantic, because they want to be able to reuse buffers for exception messages rather than passing them as string like is normally done. So, they can override message to provide the message instead of using msg. I have no idea why it wouldn't be nothrow though. That was probably an oversight. Regardless, if you're not doing anything with overriding message in your own code, then using msg should work just fine. - Jonathan M DavisWhat's the clean way to extract the message that passes the nothrow argument? Do I really have to embed another try catch?I didn't even know it had a `message`... you should be able to pull the `.msg` member directly though, which is a simple string and not a function at all. http://dpldocs.info/experimental-docs/object.Throwable.html
Nov 28 2017
.msg worked. I will let you all live.
Nov 28 2017
On Wednesday, 29 November 2017 at 00:52:41 UTC, A Guy With a Question wrote:.msg worked. I will let you all live.Thanks!
Nov 28 2017