Quantcast
Channel: YouTrackReSharper (RSRP) - Bug and Issue Tracker
Viewing all 106942 articles
Browse latest View live

RSRP-306550: QFix "Initialize Field From Ctor Param": Breaks Usages of a Field

$
0
0
Reporter Serge Baltic (baltic) Serge Baltic (baltic)
Created Jun 1, 2012 3:26:58 PM
Updated Oct 8, 2018 6:54:11 PM
Subsystem Quick Fixes
Assignee Alisa Afonina (alisa.afonina)
Priority Normal
State Submitted
Type Bug
Fix version Backlog
Affected versions 2018.3
Fixed In Version ReSharper Undefined
VsVersion All Versions
  class O
{
public O()
{
Console.WriteLine(ss);
}
}

Introduce field from ss.
On field, on a warning, execute QFix "Initialize Field From Ctor Param".

Expected:

  class O
{
private bool ss;

public O(bool ss)
{
this.ss = ss;
Console.WriteLine(this.ss);
}
}

Actual:

  class O
{
private bool ss;

public O(bool ss)
{
this.ss = ss;
Console.WriteLine(ss);
}
}

The field usage in WriteLine is silently replaced with a parameter usage, which will break behavior of you have much code in .ctor and modify field values intending to have a new value in WriteLine.

RSRP-308184: Suggest replacing argument with its property/field

$
0
0
Reporter Andrey Shchekin (ashmind) Andrey Shchekin (ashmind)
Created Jun 6, 2012 5:00:39 AM
Updated Oct 8, 2018 7:03:46 PM
Subsystem Code Analysis - C#
Assignee Ivan Serduk (IvanSerduk)
Priority Normal
State Submitted
Type Feature
Fix version Backlog
Affected versions No Affected versions
Fixed In Version ReSharper Undefined
VsVersion All Versions
The following function:
public FullName ParseFullName(User user) {
var parts = user.FullName.Split(new[] {' '}, 2);
return new FullName(parts[0], parts[1]);
}
can be refactored to
public FullName ParseFullName(string fullName) {
var parts = fullName.Split(new[] {' '}, 2);
return new FullName(parts[0], parts[1]);
}
that is more generic.

It would be nice if ReSharper suggested simpler dependency in these (and similar) cases and provided corresponding Quick Fix.

RSRP-309834: [VB] QF 'Remove redundant cast' breaks code

$
0
0
Reporter Vladimir Reshetnikov (nikov) Vladimir Reshetnikov (nikov)
Created Jun 11, 2012 2:46:14 AM
Updated Oct 8, 2018 7:05:21 PM
Subsystem Quick Fixes
Assignee Alisa Afonina (alisa.afonina)
Priority Normal
State Submitted
Type Bug
Fix version Backlog
Affected versions 2018.3
Fixed In Version ReSharper Undefined
VsVersion All Versions
Module M
Sub Main()
CType("", String).ToCharArray() ' Remove redundant cast
End Sub
End Module

Actual:

Module M
Sub Main()
"".ToCharArray() ' error BC30035: Syntax error.
End Sub
End Module

Expected:

Module M
Sub Main()
Call "".ToCharArray() ' OK
End Sub
End Module

RSRP-312221: Suggestion infitine loop

$
0
0
Reporter Alex Berezoutsky (fergard) Alex Berezoutsky (fergard)
Created Jun 18, 2012 1:58:43 PM
Updated Oct 8, 2018 7:07:25 PM
Resolved Oct 8, 2018 7:07:25 PM
Subsystem Quick Fixes
Assignee Alisa Afonina (alisa.afonina)
Priority Normal
State Obsolete
Type Bug
Fix version Backlog
Affected versions 6.1.1
Fixed In Version ReSharper Undefined
VsVersion All Versions
The code is exactly as follows

  List<Adresa> adresy = ent.ExecuteStoreQuery<Adresa>(
@"SELECT TOP 1000 Adresy.ulice, Adresy.mesto, Adresy.psc, Adresy.stat, Adresy.cisloPopisne, Adresy.okres, Adresy.telefon, Adresy.email, Adresy.druhAdresy, Adresy.IsirIdAdresy,
Adresy.SpisovaZnacka, Adresy.IsirIdOsoby
FROM Adresy INNER JOIN
Osoby ON Adresy.IsirIdOsoby = Osoby.IsirIdOsoby INNER JOIN
Spisy ON Adresy.SpisovaZnacka = Spisy.SpisovaZnacka
WHERE (Osoby.DruhOsoby <> N'SPRÁV_INS') AND (Spisy.SpisovaZnacka = @SpisovaZnacka) ",
new SqlParameter[] { new SqlParameter("@SpisovaZnacka", spis.SpisovaZnacka) }).ToList();
and resharper keeps suggesting replacing the last line with this one and vice versa
new[] { new SqlParameter("@SpisovaZnacka", spis.SpisovaZnacka) }).ToList();

RSRP-471786: Missing suggestion when correcting a typo

$
0
0
Reporter Igor Akhmetov (Igor.Akhmetov) Igor Akhmetov (Igor.Akhmetov)
Created Oct 8, 2018 7:08:48 PM
Updated Oct 8, 2018 7:08:48 PM
Subsystem ReSpeller
Assignee Artem Bukhonov (Artem.Bukhonov)
Priority Normal
State Submitted
Type Bug
Fix version No Fix versions
Affected versions No Affected versions
Fixed In Version ReSharper Undefined
VsVersion All Versions
When correcting "mamber" R# suggests "amber" but not "member".

RSRP-315568: Problem with sealed class

$
0
0
Reporter Marius (geimas5) Marius (geimas5)
Created Jun 22, 2012 4:58:55 PM
Updated Oct 8, 2018 7:10:12 PM
Subsystem Quick Fixes
Assignee Lilia Shamsutdinova (Lilia.Shamsutdinova)
Priority Normal
State To Reproduce
Type Bug
Fix version Backlog
Affected versions 7.0
Fixed In Version ReSharper Undefined
VsVersion All Versions
If i have the following class that is used through structuremap i get the "The class is never instantaniated.

public sealed class AbnormalityReporterFactory : IAbnormalityReporterFactory
{

}

If i now apply the quickfix "Make class 'class name'" abstract i end up with the following code:
public abstract sealed class AbnormalityReporterFactory : IAbnormalityReporterFactory
{

}

RSRP-328935: VB.NET: Shorthand Casting

$
0
0
Reporter Denis Abramov (sparky2708) Denis Abramov (sparky2708)
Created Aug 3, 2012 10:26:24 PM
Updated Oct 8, 2018 7:13:27 PM
Subsystem Quick Fixes
Assignee Alisa Afonina (alisa.afonina)
Priority Normal
State Submitted
Type Improvement
Fix version Backlog
Affected versions 2018.3
Fixed In Version ReSharper Undefined
VsVersion All Versions
Suppose I have:

Option Strict On

Dim i as Integer = 15D

R# says that it needs a cast which is correct so it replaces with:
Dim i as Integer = CType(15D, Integer)

but it would be better to replace with:
Dim i as Integer = CInt(15D)

RSRP-471787: Do not format single right angle bracket on the next line

$
0
0
Reporter Andrey Dyatlov (Andrey.Dyatlov) Andrey Dyatlov (Andrey.Dyatlov)
Created Oct 8, 2018 7:22:57 PM
Updated Oct 8, 2018 7:22:57 PM
Subsystem Code Style - Formatter
Assignee Dmitry Osinovsky (Dmitry.Osinovsky)
Priority Normal
State Submitted
Type Bug
Fix version No Fix versions
Affected versions No Affected versions
Fixed In Version ReSharper Undefined
VsVersion All Versions
I'd prefer moving the whole : CSharpContextActionAvailabilityTestBase<BodyStatementToExpressionAction to the next line

RSRP-471764: Creating class and retyping it to enum makes it reload

$
0
0
Reporter Andrey Simukov (Andrey.Simukov) Andrey Simukov (Andrey.Simukov)
Created Oct 5, 2018 4:59:03 PM
Updated Oct 8, 2018 7:43:10 PM
Subsystem Platform - VS Integration
Assignee Serge Baltic (baltic)
Priority Show-stopper
State Open
Type Bug
Fix version 2018.3
Affected versions 2018.2.3
Fixed In Version ReSharper Undefined
VsVersion All Versions
1) Locate shared project
2) Create class through Add / New Item / Class - call it "TestEnum"
3) Observe "TestEnum.cs" being created
4) Rewrite the "class" part to "public enum" so you get "public enum TestEnum"
5) Start typing enum values
6) Observe that a dialog to reload the file is presented.
7) Click "No"
8) The dialog is then presented again

Disabling ReSharper solves this problem

RSRP-471746: The item 'Class1.cs' cannot be deleted.

$
0
0
Reporter Anna Milova (anna.milova) Anna Milova (anna.milova)
Created Sep 26, 2018 10:26:50 PM
Updated Oct 8, 2018 8:24:14 PM
Subsystem Platform - VS Integration
Assignee Sergey Kuks (coox)
Priority Critical
State Fixed In Branch
Type Exception
Fix version No Fix versions
Affected versions No Affected versions
Fixed In Version ReSharper Undefined
VsVersion All Versions
ReSharperPlatformVs15 Wave 183 Hive _4f065301DotnetProducts — JetBrains ReSharper Ultimate 2018.3 EAP 1 D Build 183.0.20180924.0-eap01d

JetBrains ReSharper 2018.3 EAP 1 D Build 2018.3.20180924.0-eap01d
JetBrains ReSharper C++ 2018.3 EAP 1 D Build 2018.3.20180924.0-eap01d

The item 'Class1.cs' cannot be deleted.

— EXCEPTION #1/2 [COMException]
Message = “The item 'Class1.cs' cannot be deleted.”
ExceptionPath = Root.InnerException
ClassName = System.Runtime.InteropServices.COMException
HResult = E_FAIL=EFail=80004005
StackTraceString = “
 at EnvDTE.ProjectItem.Delete()
 at EnvDTE.ProjectItem.Delete()
 at JetBrains.VsIntegration.ProjectDocuments.Transactions.Actions.VsDragAndDropUtil.<>c__DisplayClass4_1.<DeleteProjectModelElement>b__0()


— Outer —

— EXCEPTION #2/2 [LoggerException]
Message = “The item 'Class1.cs' cannot be deleted.”
ExceptionPath = Root
ClassName = JetBrains.Util.LoggerException
Data.ManagedThreadName = <NULL>
Data.LastExtension = cs
Data.SccRevisionShell = “<there are no packages matching the criteria>”
Data.HostProductInfo = “JetBrains ReSharper Ultimate 2018.3 EAP 1 D Build 183.0.20180924.0-eap01d”
Data.SubProducts.#0 = “JetBrains ReSharper C++ 2018.3 EAP 1 D Build 2018.3.20180924.0-eap01d”
Data.SubProducts.#1 = “JetBrains ReSharper 2018.3 EAP 1 D Build 2018.3.20180924.0-eap01d”
Data.SccRevisionEnv = “
Platform\Core\Shell,
Platform\VisualStudio:
    git::refs/heads/183-am-netat2::14af6a979ca562d9d8e762cd0a8d6a87ecc4ec69

Data.VsVersion = 15.6.27428.2027
InnerException = “Exception #1 at Root.InnerException”
HResult = COR_E_APPLICATION=80131600
StackTraceString = “
 at JetBrains.Util.LoggerBase.Log(LoggingLevel level, String message, Exception ex)
 at JetBrains.Util.LoggerBase.Log(LoggingLevel level, String message, Exception ex)
 at JetBrains.Util.Logging.LogEx.Error(ILog this, Exception ex, String message)
 at JetBrains.Util.Logging.Logger.LogException(Exception ex)
 at JetBrains.VsIntegration.ProjectDocuments.Transactions.Actions.VsDragAndDropUtil.<>c__DisplayClass4_1.<DeleteProjectModelElement>b__0()
 at JetBrains.Util.Concurrency.UnguardedCallbackMerger.ExpectUnguardedCallback(Action FNested)
 at JetBrains.VsIntegration.ProjectDocuments.Transactions.Actions.VsDragAndDropUtil.DeleteProjectModelElement(IVsAction action, VsHierarchyItem hierarchyItem, FileSystemPath location, Boolean shared)
 at JetBrains.VsIntegration.ProjectDocuments.Transactions.Actions.VsRemoveAction.Commit()
 at JetBrains.DocumentManagers.Transactions.SolutionProjectDocumentTransaction.DoCommit(IDictionary`2 dirtyDocuments, IProgressIndicator pi)
 at JetBrains.DocumentModel.Transactions.DocumentTransaction.Commit(IProgressIndicator pi)
 at JetBrains.DocumentModel.Transactions.DocumentTransaction.Commit(IUndoRedoHandler undoRedoHandler, IProgressIndicator pi)
 at JetBrains.DocumentModel.Transactions.DocumentTransactionManager.CommitTransaction(IUndoRedoHandler undoRedoHandler, IProgressIndicator pi)
 at JetBrains.DocumentModel.Transactions.DocumentTransactionManager.CommitTransaction(IProgressIndicator pi)
 at JetBrains.DocumentModel.Transactions.DocumentTransactionCookie.Commit(IProgressIndicator pi)
 at JetBrains.DocumentManagers.Transactions.ProjectModelTransactionFactory.ProjectModelTransactionCookie.Commit(IProgressIndicator pi)
 at JetBrains.ReSharper.Feature.Services.Refactorings.WorkflowExecuter.<>c__DisplayClass42_3.<InitPage>b__2(IProjectModelTransactionCookie c)
 at JetBrains.Util.Special.GeneralUtil.IfNotNull[TInput,TResult](TInput object, Func`2 functor, TResult default)
 at JetBrains.ReSharper.Feature.Services.Refactorings.WorkflowExecuter.<>c__DisplayClass42_2.<InitPage>b__1(IProgressIndicator pi)
 at JetBrains.ReSharper.Feature.Services.Refactorings.FunctionWrapper`1.ExecuteAction(IProgressIndicator pi)
 at JetBrains.UI.SrcView.Progress.UITaskExecutorRun.RunStartTaskCallTaskAction(IProperty`1 isDone, ProgressIndicator progressIndicator, TaskThreadAffinity taskThreadAffinity, Action`1 FTask, JetDispatcher dispatcherPrimary)
 at JetBrains.UI.SrcView.Progress.UITaskExecutorRun.RunCore(TaskThreadAffinity taskThreadAffinity, Action`1 FTask, Func`3 FAttachUi, ProgressIndicator progressIndicator, IWin32Window parentWindow, IThreading threading, WorkerThreadShop workerThreadShop, Boolean enforceModalityState)
 at JetBrains.UI.SrcView.Progress.UITaskExecutorRun.Run(TaskThreadAffinity taskThreadAffinity, Action`1 task, Func`3 FAttachUi, ProgressIndicator indicator, IWin32Window parentWindow, IThreading threading, WorkerThreadShop workerThreadShop, Boolean enforceModalityState)
 at JetBrains.PsiFeatures.UIInteractive.Refactorings.RefactoringsTaskExecutor.JetBrains.Application.Progress.ITaskExecutor.ExecuteTask(String name, TaskCancelable cancelable, Action`1 task)
 at JetBrains.ReSharper.Feature.Services.Refactorings.WorkflowExecuter.RunWithProgress[TResult](Func`2 action, String taskName, TResult& result)
 at JetBrains.ReSharper.Feature.Services.Refactorings.WorkflowExecuter.InitPage(IRefactoringPage page)
 at JetBrains.ReSharper.Feature.Services.Refactorings.WorkflowExecuter.NextPage(IRefactoringPage currentPage)
 at JetBrains.ReSharper.Feature.Services.Refactorings.WorkflowExecuter.MoveToNextPage()
 at JetBrains.PsiFeatures.UIInteractive.Refactorings.CommonUI.WorkflowHostWithWizardForm.<NextClick>b__18_0()
 at JetBrains.Threading.ReentrancyGuard.Execute(String name, Action action)
 at JetBrains.Threading.ReentrancyGuard.ExecuteOrQueue(String name, Action action, TaskPriority priority)
 at JetBrains.PsiFeatures.UIInteractive.Refactorings.CommonUI.WorkflowHostWithWizardForm.NextClick(Object sender, EventArgs e)
 at JetBrains.PsiFeatures.UIInteractive.Refactorings.CommonUI.RefactoringWizardForm.myContinueButton_Click(Object sender, EventArgs e)
 at System.Windows.Forms.Control.OnClick(EventArgs e)
 at System.Windows.Forms.Button.OnClick(EventArgs e)
 at System.Windows.Forms.Button.OnMouseUp(MouseEventArgs mevent)
 at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)
 at System.Windows.Forms.Control.WndProc(Message& m)
 at System.Windows.Forms.ButtonBase.WndProc(Message& m)
 at System.Windows.Forms.Button.WndProc(Message& m)
 at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
 at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
 at System.Windows.Forms.NativeWindow.DebuggableCallback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)

RSRP-471500: [Performance Report] Lag when typing

$
0
0
Reporter Steven Bouwkamp (stevenbouwkamp) Steven Bouwkamp (stevenbouwkamp)
Created Sep 13, 2018 7:12:24 PM
Updated Oct 8, 2018 9:09:18 PM
Subsystem Code Analysis - C#
Assignee Ivan Serduk (IvanSerduk)
Priority Show-stopper
State Open
Type Performance Problem
Fix version 2018.3
Affected versions No Affected versions
Fixed In Version ReSharper Undefined
VsVersion All Versions
Evaluator: False
OS Version: Microsoft Windows NT 10.0.16299.0
Product: dotCover, Version: 2018.2.20180912.160624
Product: dotTrace, Version: 2018.2.20180912.160542
Product: ReSharperCpp, Version: 2018.2.20180912.160214
Product: teamCityAddin, Version: 2018.2.20180912.160239
Product: ReSharper, Version: 2018.2.20180912.160227
Product: dotMemory, Version: 2018.2.20180912.160400
Time Zone: Eastern Standard Time

Description

Occasionally, when typing there is a noticeable lag or hitch occuring followed by a CPU spike into around 65% on an i75820k.

Been persistent through multiple versions of Visual Studio and Resharper.

There doesn't seem to be a commonality for where the problem pops up - could be in small solutions, large solutions, C#-only, VB.NET-only, or solutions with projects that are C# and VB.NET.

The lag does not go away through Visual Studio restarts, Resharper restarts, Resharper cache clears.

I've followed all performance guide reccommendations and none seem to help.

Issue was captured in one of the later snapshots, didn't realize it was already running in the first one :)

Thanks

RSRP-469921: UI input lag after saving file

$
0
0
Reporter Thomas Harrison (rolls) Thomas Harrison (rolls)
Created May 30, 2018 9:23:00 AM
Updated Oct 8, 2018 9:11:41 PM
Subsystem Psi - Caches
Assignee Dmitry Ivanov (daivanov)
Priority Critical
State Open
Type Performance Problem
Fix version 2018.3
Affected versions No Affected versions
Fixed In Version ReSharper Undefined
VsVersion All Versions
https://resharper-support.jetbrains.com/hc/en-us/requests/1340628?page=1

I get bad UI input lag (typing) after saving a file. This also occurs randomly when I haven't saved a file. Sometimes the intellisense look alike (eg the auto complete) completely fails and I have to disable resharper.

I took some performance profiles but your bug tracker doesn't upload. The performance profiler crashes and fails to attach. After spending several hours restarting processes I managed to get it to attach whilst the slowdown was occuring, then the bug tracker app uploaded at 3kb/s and timed out after several hours despite having a 100 megabit connection.

I managed to grab the performance profiles out of my temp folder before the bug reporter crashed again (crashes 9/10 times I managed to attach a bug report taking visual studio with it!).

Anyway ignoring the fact the profiler won't attach and the bug reporter is buggy and impossible to upload I've attached via sharepoint a performance profile.
https://pcmtec-my.sharepoint.com/:u:/p/roland/EaxrTT-am2hLnBpPqii5VsEBfdKPqHuoeHbK0ovda2ZG8w?e=9AIbmA

Basically this happens whenever I press ctrl+s then start typing, the UI lags badly for 15 seconds afterwards. Startup is horrendously slow as well lagging the entire UI and showing "not responding" whilst it is "processing assemblies".

I moved my cache folder to a different drive (SSD in raid) and it was no worse than my NVME PCIE SSD with 3gb/s transfer rates.

I keep seeing these files being accessed in resource monitor (ignore the path, this was before I moved the folder) when the IDE is idling away doing nothing.

Why is the UI completely locked whilst "processing assemblies"? Why does it need to process them every time I start the application?

Why does the UI lock up badly after saving? I have disabled code lense, intelli trace and everything else in the performance guide but resharper still runs like a complete dog. I was hoping spending $2k on a new 12 core, 32gb ram and NVME SSD would make things faster, but it is barely an improvement.

RSRP-469301: Unit Tests Inconclusive

$
0
0
Reporter Bradley Uffner (bradley.uffner) Bradley Uffner (bradley.uffner)
Created Apr 17, 2018 9:29:23 PM
Updated Oct 8, 2018 10:26:15 PM
Resolved Oct 3, 2018 2:55:31 PM
Subsystem Unit Testing
Assignee Angelina Elycheva (Angelina.Elycheva)
Priority Normal
State Obsolete
Type Bug
Fix version No Fix versions
Affected versions 2018.1
Fixed In Version ReSharper Undefined
VsVersion VS 2017 RTM

I have been getting strange results since upgrading to ReSharper 2018.1 in Visual Studio 15.6.5.

The Unit Test Sessions will randomly report an "Inconclusive" test result for all unit tests. I will have to repeatedly run the unit tests multiple times in order to get them to run correctly. I haven't yet found a reproducible trigger for this behavior.

Output Window for "Tests" just shows:
[4/17/2018 7:10:49 AM Informational] ------ Load Playlist started ------
[4/17/2018 7:10:49 AM Informational] ========== Load Playlist finished (0:00:00.0979608) ==========
[4/17/2018 11:21:53 AM Informational] ------ Load Playlist started ------
[4/17/2018 11:21:53 AM Informational] ========== Load Playlist finished (0:00:00.001) ==========
[4/17/2018 12:40:35 PM Informational] ------ Load Playlist started ------
[4/17/2018 12:40:35 PM Informational] ========== Load Playlist finished (0:00:00) ==========
[4/17/2018 12:41:20 PM Informational] ------ Load Playlist started ------
[4/17/2018 12:41:20 PM Informational] ========== Load Playlist finished (0:00:00.0010001) ==========

Output from Build shows:
Build with surface heuristics started at 14:23:12
Use build tool: C:\Program Files (x86)\Microsoft Visual Studio\2017\Professional\MSBuild\15.0\Bin\MSBuild.exe
Build completed in 00:00:01.158

RSRP-471664: [Performance Report] Typing response is very slow

$
0
0
Reporter Denis Papp (denis0822) Denis Papp (denis0822)
Created Sep 27, 2018 10:33:58 PM
Updated Oct 9, 2018 2:15:00 AM
Subsystem No Subsystem
Assignee Sergey Kuks (coox)
Priority Show-stopper
State Open
Type Performance Problem
Fix version 2018.3
Affected versions No Affected versions
Fixed In Version ReSharper Undefined
VsVersion All Versions
Evaluator: False
OS Version: Microsoft Windows NT 10.0.17134.0
Product: dotCover, Version: 2018.2.20180821.115217
Product: dotTrace, Version: 2018.2.20180821.115219
Product: ReSharper, Version: 2018.2.20180821.115000
Product: dotMemory, Version: 2018.2.20180821.115113
Time Zone: Central Standard Time

Description

Previously reported with #1725255

With Resharper on, gradually I will start to see a slowdown in typing response. For example, if I type in 20 characters to the Command Window, it may take several seconds for all the chracters to appear (one at a time). The problem is most obvious with the Command Window but also can be observed in the editor.

I have attached a performance snapshot..

RSRP-471592: R# build checks out files from TFS

$
0
0
Reporter Alexander Kurakin (Alexander.Kurakin) Alexander Kurakin (Alexander.Kurakin)
Created Sep 21, 2018 2:43:51 PM
Updated Oct 9, 2018 9:50:16 AM
Subsystem Solution builder
Assignee Tatyana Lunegova (lunega)
Priority Critical
State Open
Type Task
Fix version Backlog
Affected versions 2018.2.3
Fixed In Version ReSharper Undefined
VsVersion All Versions

I found sometimes are unexpectedly opened files checked out from TFS when running application. This is related to R# build.

  1. Open any solution
  2. Open file from any other solution (important)
  3. Put cursor to this opened file (important)
  4. Run F5 or click on Run icon

File gets checked out even there is no edit or something.
It must be "out of solution" file and cursor must be placed inside (focused editor) before running debug.
Disabling R# build and using VS build works fine.


RSRP-471789: Find possible throws affecting this code

$
0
0
Reporter Dave Yost (daveyost) Dave Yost (daveyost)
Created Oct 8, 2018 1:16:32 AM
Updated Oct 9, 2018 10:09:38 AM
Subsystem Code Analysis
Assignee Ivan Serduk (IvanSerduk)
Priority Normal
State Submitted
Type Feature
Fix version Backlog
Affected versions No Affected versions
Fixed In Version ReSharper Undefined
VsVersion All Versions
Find all throws in the project that would be caught by a try-catch around the selected code.

RSRP-289038: Wrong unreachable code refactoring for "do {...} while(false)"

$
0
0
Reporter Tomas Kovarik (Tomas.Kovarik) Tomas Kovarik (Tomas.Kovarik)
Created Mar 5, 2012 9:12:21 PM
Updated Oct 9, 2018 10:54:57 AM
Subsystem Quick Fixes
Assignee Alisa Afonina (alisa.afonina)
Priority Normal
State Submitted
Type Bug
Fix version Backlog
Affected versions 6.1, 2018.3
Fixed In Version ReSharper Undefined
VsVersion All Versions
I often use do { some code } while (false) in my code in cases, when a failover value is expensive to create. If something wrong happens during computing of real value, I use "break" to jump out of the block and create and return failover value. See the example below. Resharper (correctly) identifies the "while (false)" as unreachable code and offers refactoring to remove it. But by removing the "while" block I cannot use "break" to jump out of it, so it is not compilable. In this cases resharper should not offer the refactoring.

Example
public class A
{
public bool Initialized { get; private set; }

public static A CreateA(int value)
{
do
{
// Some code ....
// Some condition check
if (value == 0) { break; }
// Some code ....
// Some condition check
if (value == 1) { break; }
// Some code ....
// Some condition check
if (value == 2) { break; }

// Return initialized value
return new A { Initialized = true };
} while (false);

// Return default value
return new A();
}
}

RSRP-290324: Suggest reduce "nullableBool.HasValue && nullableBool.Value" to "nullableBool ?? false"

$
0
0
Reporter Drew Noakes (drewnoakes) Drew Noakes (drewnoakes)
Created Mar 16, 2012 3:52:02 PM
Updated Oct 9, 2018 10:56:58 AM
Resolved Oct 9, 2018 10:56:58 AM
Subsystem Quick Fixes
Assignee Alisa Afonina (alisa.afonina)
Priority Normal
State Obsolete
Type Feature
Fix version No Fix versions
Affected versions 6.1
Fixed In Version ReSharper Undefined
VsVersion All Versions
I was working with a radio button:

if (_rbClickToReposition.IsChecked.HasValue && _rbClickToReposition.IsChecked.Value)
{}

This is much nicer as:

if (_rbClickToReposition.IsChecked ?? false)
{}

R# could suggest this!

RSRP-291869: Reference assembly tooltip not available

$
0
0
Reporter Marius (geimas5) Marius (geimas5)
Created Mar 26, 2012 12:30:32 PM
Updated Oct 9, 2018 11:08:46 AM
Resolved Oct 9, 2018 11:08:46 AM
Subsystem Quick Fixes
Assignee Alisa Afonina (alisa.afonina)
Priority Normal
State Duplicate
Type Unspecified
Fix version Backlog
Affected versions 6.1.1
Fixed In Version ReSharper Undefined
VsVersion All Versions
Reference assembly tooltip is not available when part of the namepace is specified.

F.eks if i have the code:
string configFile = System.Configuration.ConfigurationManager.AppSettings["ConfigFile"];

Then the ConfigurationManager is marked in red text because the System.Configuration assebly is not referenced. but i do not get a tooltip to add a reference to it. I only get that bulb action when removing "System.Configuration"

RSRP-471654: QF 'Add reference and use type' does not work in some cases

$
0
0
Reporter Olga Rodygina (olgarodygina) Olga Rodygina (olgarodygina)
Created Sep 27, 2018 2:34:18 PM
Updated Oct 9, 2018 11:08:46 AM
Subsystem Quick Fixes
Assignee Alisa Afonina (alisa.afonina)
Priority Normal
State Submitted
Type Bug
Fix version Backlog
Affected versions 2018.3, 2018.2.3
Fixed In Version ReSharper Undefined
VsVersion All Versions
Viewing all 106942 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>