Over a million developers have joined DZone.
{{announcement.body}}
{{announcement.title}}

Turning Bugs Into Features

DZone's Guide to

Turning Bugs Into Features

Bugs aren't necessarily bad. Instead of squishing those bugs in your code, try turning them into features.

Free Resource

RavenDB vs MongoDB: Which is Better? This White Paper compares the two leading NoSQL Document Databases on 9 features to find out which is the best solution for your next project.  

I’m using R# for over a decade now, and it has gotten to the point where I’m actually able to utilize R# bugs to get things working better for me.

In this case, the scenario is using Find Usages as a refactoring aid. I have a tricky refactoring to do, which requires me to touch several pieces of code. In order to handle this properly, I start by Finding Usages on the relevant item. In this case, ByView.

Then I go to each of those code locations and make the required modifications.

image

So far so good, but on complex scenarios, it is hard to remember which portions I have done and which portions are still left undone. In order to handle this, I Ctrl+X, Ctrl+Z the line I find. R# detects this as a change to the code that invalidates the found usage, and suddenly, I got a nice to-do list with a strikethrough for completed tasks.

Get comfortable using NoSQL in a free, self-directed learning course provided by RavenDB. Learn to create fully-functional real-world programs on NoSQL Databases. Register today.

Topics:
performance ,r ,r# ,bug tracking

Published at DZone with permission of

Opinions expressed by DZone contributors are their own.

{{ parent.title || parent.header.title}}

{{ parent.tldr }}

{{ parent.urlSource.name }}