Skip to main content

Timeline for Is it ok to use goto in catch?

Current License: CC BY-SA 3.0

10 events
when toggle format what by license comment
Apr 13, 2017 at 12:40 history edited CommunityBot
replaced http://codereview.stackexchange.com/ with https://codereview.stackexchange.com/
Nov 19, 2012 at 9:22 comment added ANeves @Leonid "sometimes", such as? Do you mean String.Empty? (abhor++)
Nov 18, 2012 at 14:26 comment added Konrad Rudolph Oh how I abhor string.Empty. "" is so much shorter and not a jot less clear. But in general, this is a very clean implementation. +1
Nov 17, 2012 at 18:20 comment added dreza @Leonid Fair point. I think it's more of a style (team) preference though so might leave that to the OP to decide. Check this out stackoverflow.com/questions/263191/…. I tend to listen to his suggestions. As for limiting requests. Another good point that the OP can look into if required.
Nov 17, 2012 at 15:15 comment added Leonid How about limiting the number of attempts? Also, sometimes you should capitalize the s in String. Run StyleCop on your code and you will see.
Nov 16, 2012 at 5:28 vote accept disbeliever
Nov 16, 2012 at 1:59 comment added dreza @svick valid point. I've updated answer to reflect this. cheers.
Nov 16, 2012 at 1:58 history edited dreza CC BY-SA 3.0
Updated as per svicks suggestion
Nov 16, 2012 at 1:33 comment added svick Are you sure it's a good idea to rely on the fact that a Message of an exception won't be null or empty? I think using multiple return statements (one in try, one in catch) would be a better solution here.
Nov 15, 2012 at 7:51 history answered dreza CC BY-SA 3.0