Exception using RangeBased code outlining

SyntaxEditor for WPF Forum

Posted 4 years ago by Vadim Tsedrik
Version: 19.1.0683
Platform: .NET 4.8
Environment: Windows 10 (64-bit)
Avatar

Hi we are getting unhandled exception using RangeBased code outliner from your example:

System.NullReferenceException "Object reference not set to an instance of an object." " at ActiproSoftware.Text.Lexing.Implementation.DynamicLexicalState.Match(ITextBufferReader #o6b)
at ActiproSoftware.Text.Lexing.Implementation.MergableLexerCoordinator.GetNextToken()
at ActiproSoftware.Text.Lexing.Implementation.MergableLexerCoordinator.Parse(TextSnapshotRange snapshotRange, ILexerTarget lexerTarget)
at ActiproSoftware.Text.Lexing.Implementation.MergableLexerBase.Parse(TextSnapshotRange snapshotRange, ILexerTarget parseTarget)
at #rqc.#XYc.GetTokens(ILexer #Yqc, TextSnapshotRange #kzf, Object #hCf, Boolean #x0c, Int32& #xCf)
at ActiproSoftware.Text.Tagging.Implementation.TokenTagger.GetTokens(ILexer lexer, TextSnapshotRange desiredSnapshotRange, Object parseContext, Boolean canUpdateLineContexts, Int32& invalidateThroughOffset)
at ActiproSoftware.Text.Tagging.Implementation.TokenTagger.#N2i.#gaf()
at ActiproSoftware.Text.Tagging.Implementation.TokenTagger.#I2i.#gaf()
at ActiproSoftware.Text.Tagging.TagAggregatorBase`1.#H2i.#gaf()
at ActiproSoftware.Windows.Controls.SyntaxEditor.Implementation.TextViewLineManager.#GCk(#HCk #HCk, #xtk #Z6b)
at ActiproSoftware.Windows.Controls.SyntaxEditor.Implementation.TextViewLineManager.#MCk(#HCk #HCk, TextSnapshotRange #tCk)
at ActiproSoftware.Windows.Controls.SyntaxEditor.Implementation.TextViewLineManager.#VCk(#HCk #HCk, Int32 #fd, Boolean #Dmk, Nullable`1 #2cc, Double #0n, Nullable`1 #WCk)
at ActiproSoftware.Windows.Controls.SyntaxEditor.Implementation.TextViewLineManager.GetViewLine(Int32 #fd, Boolean #Dmk)
at ActiproSoftware.Windows.Controls.SyntaxEditor.Primitives.TextView.GetViewLine(Int32 offset, Boolean hasFarAffinity)
at ActiproSoftware.Windows.Controls.SyntaxEditor.Primitives.TextView.GetViewLine(TextPosition position)
at #V2b.#J3b.get_ViewLine()
at ActiproSoftware.Windows.Controls.SyntaxEditor.Primitives.EditorOutliningMargin.UpdateHighlightSnapshotRange(IHitTestResult hitTestResult)
at ActiproSoftware.Windows.Controls.SyntaxEditor.Primitives.EditorOutliningMargin.OnPointerMoved(Object sender, InputPointerEventArgs e)

Comments (3)

Posted 4 years ago by Actipro Software Support - Cleveland, OH, USA
Avatar

Hello,

Can you tell us exactly how to reproduce this in the Range-Based Code Outlining sample?  Or is this happening in a custom syntax language?


Actipro Software Support

Posted 4 years ago by Vadim Tsedrik
Avatar

Hello, correct it's happened not every time in a custom syntax language, when syntax editor is reloaded from xml file.

Posted 4 years ago by Actipro Software Support - Cleveland, OH, USA
Avatar

Hello,

Ok, please make a new simple sample project that shows it happening and send that to our support address.  Reference this thread in your e-mail and be sure to exclude the bin/obj folders from the ZIP you send so it doesn't get spam blocked.  Then we will debug that sample project and will see what's going on.  Thanks!


Actipro Software Support

The latest build of this product (v24.1.3) was released 28 days ago, which was after the last post in this thread.

Add Comment

Please log in to a validated account to post comments.