Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit6043179

Browse files
committed
Fix up conditional definitions (changeset 1288314)
1 parent1502015 commit6043179

File tree

2 files changed

+18
-9
lines changed

2 files changed

+18
-9
lines changed

‎src/FSharpSource.Settings.targets‎

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -22,17 +22,17 @@
2222
<ErrorReportCondition=" '$(ErrorReport)' == ''">prompt</ErrorReport>
2323
<PlatformCondition=" '$(Platform)' == ''">AnyCPU</Platform>
2424
<OtherFlags>$(OtherFlags) --no-jit-optimize --jit-tracking</OtherFlags>
25-
<DefineConstantsCondition=" '$(DefineConstants)' == '' and 'ProjectLanguage' != 'VisualBasic'">DEBUG;TRACE;CODE_ANALYSIS;$(DefineConstants)</DefineConstants>
26-
<DefineConstantsCondition=" '$(DefineConstants)' == '' and 'ProjectLanguage' == 'VisualBasic'">DEBUG="true";TRACE="true";CODE_ANALYSIS="true";$(DefineConstants)</DefineConstants>
25+
<DefineConstantsCondition=" '$(ProjectLanguage)' != 'VisualBasic'">DEBUG;TRACE;CODE_ANALYSIS;$(DefineConstants)</DefineConstants>
26+
<DefineConstantsCondition=" '$(ProjectLanguage)' == 'VisualBasic'">DEBUG=True,TRACE=True,CODE_ANALYSIS=True,$(DefineConstants)</DefineConstants>
2727
<SIGN_WITH_MSFT_KEYCondition=" '$(SIGN_WITH_MSFT_KEY)' == ''">false</SIGN_WITH_MSFT_KEY>
2828
</PropertyGroup>
2929

3030
<PropertyGroupCondition=" '$(Configuration)' == 'Release'">
3131
<DebugTypeCondition=" '$(DebugType)' == ''">pdbonly</DebugType>
3232
<OptimizeCondition=" '$(Optimize)' == ''">true</Optimize>
3333
<ErrorReportCondition=" '$(ErrorReport)' == ''">prompt</ErrorReport>
34-
<DefineConstantsCondition=" '$(DefineConstants)'== '' and 'ProjectLanguage'!= 'VisualBasic'">TRACE</DefineConstants>
35-
<DefineConstantsCondition=" '$(DefineConstants)' == '' and 'ProjectLanguage' == 'VisualBasic'">TRACE="true"</DefineConstants>
34+
<DefineConstantsCondition=" '$(ProjectLanguage)' != 'VisualBasic'">TRACE;$(DefineConstants)</DefineConstants>
35+
<DefineConstantsCondition=" '$(ProjectLanguage)' == 'VisualBasic'">TRACE=True,$(DefineConstants)</DefineConstants>
3636
<SIGN_WITH_MSFT_KEYCondition=" '$(SIGN_WITH_MSFT_KEY)' == ''">false</SIGN_WITH_MSFT_KEY>
3737
</PropertyGroup>
3838

@@ -41,16 +41,16 @@
4141
<ErrorReportCondition=" '$(ErrorReport)' == ''">prompt</ErrorReport>
4242
<PlatformCondition=" '$(Platform)' == ''">AnyCPU</Platform>
4343
<OtherFlags>$(OtherFlags) --no-jit-optimize --jit-tracking</OtherFlags>
44-
<DefineConstantsCondition="'$(DefineConstants)' == '' and 'ProjectLanguage' != 'VisualBasic'">DEBUG;TRACE;CODE_ANALYSIS;$(DefineConstants)</DefineConstants>
45-
<DefineConstantsCondition="'$(DefineConstants)' == '' and 'ProjectLanguage' == 'VisualBasic'">DEBUG="true";TRACE="true";CODE_ANALYSIS="true";$(DefineConstants)</DefineConstants>
44+
<DefineConstantsCondition="'$(ProjectLanguage)' != 'VisualBasic'">DEBUG;TRACE;CODE_ANALYSIS;$(DefineConstants)</DefineConstants>
45+
<DefineConstantsCondition="'$(ProjectLanguage)' == 'VisualBasic'">DEBUG=True,TRACE=True,CODE_ANALYSIS=True,$(DefineConstants)</DefineConstants>
4646
<SIGN_WITH_MSFT_KEYCondition=" '$(SIGN_WITH_MSFT_KEY)' == ''">true</SIGN_WITH_MSFT_KEY>
4747
</PropertyGroup>
4848

4949
<PropertyGroupCondition=" '$(Configuration)' == 'VSRelease'">
5050
<DebugTypeCondition=" '$(DebugType)' == ''">pdbonly</DebugType>
5151
<OptimizeCondition=" '$(Optimize)' == ''">true</Optimize>
52-
<DefineConstantsCondition=" '$(DefineConstants)' == '' and 'ProjectLanguage' != 'VisualBasic'">TRACE;$(DefineConstants)</DefineConstants>
53-
<DefineConstantsCondition=" '$(DefineConstants)' == '' and 'ProjectLanguage' == 'VisualBasic'">TRACE="true";$(DefineConstants)</DefineConstants>
52+
<DefineConstantsCondition=" '$(ProjectLanguage)' != 'VisualBasic'">TRACE;$(DefineConstants)</DefineConstants>
53+
<DefineConstantsCondition=" '$(ProjectLanguage)' == 'VisualBasic'">TRACE=True,$(DefineConstants)</DefineConstants>
5454
<ErrorReportCondition=" '$(ErrorReport)' == ''">prompt</ErrorReport>
5555
<SIGN_WITH_MSFT_KEYCondition=" '$(SIGN_WITH_MSFT_KEY)' == ''">true</SIGN_WITH_MSFT_KEY>
5656
</PropertyGroup>

‎vsintegration/src/vs/FsPkgs/FSharp.LanguageService/Source.fs‎

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -291,6 +291,9 @@ module internal Source =
291291

292292
// Can't untangle from MLS Source. The purpose of this class is to
293293
// satisfy the requirement of inheriting from Source.
294+
#if DEBUG
295+
[<System.Diagnostics.DebuggerDisplay("SourceOverIdealSource({OriginalFilename})")>]
296+
#endif
294297
typeinternalSourceOverIdealSource(service:LanguageService,textLines,colorizer,filechange:IVsFileChangeEx)=
295298
inherit SourceImpl(service, textLines, colorizer)
296299

@@ -299,7 +302,9 @@ module internal Source =
299302
let mutablefilechange= filechange
300303
let mutabletextLines= textLines
301304

302-
305+
#if DEBUG
306+
letoriginalFilename= VsTextLines.GetFilename textLines
307+
#endif
303308
let mutablefileName= VsTextLines.GetFilename textLines
304309

305310

@@ -564,6 +569,10 @@ module internal Source =
564569
fileName<- newfileName
565570
(source:> IdealSource).RecolorizeWholeFile()
566571

572+
#if DEBUG
573+
overridesource.OriginalFilename= originalFilename
574+
#endif
575+
567576
// Just forward to IdealSource
568577
interface IdealSourcewith
569578
membersource.RecolorizeWholeFile()= source.IdealSource.RecolorizeWholeFile()

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp