System.ArgumentOutOfRangeException
See original GitHub issueI got this exception during syntax checking of json files containing errors.
“Index was out of range. Must be non-negative and less than the size of the collection.”
`
[Fact]
public void TestErrorMissingClosingBracket()
{
EbnfJsonGenericParser jsonParser = new EbnfJsonGenericParser();
ParserBuilder<JsonTokenGeneric, JSon> builder = new ParserBuilder<JsonTokenGeneric, JSon>();
Parser = builder.BuildParser(jsonParser, ParserType.EBNF_LL_RECURSIVE_DESCENT, "root").Result;
ParseResult<JsonTokenGeneric, JSon> r = Parser.Parse("{");
Assert.True(r.IsError);
}
` After a first glance at the code you don’t check the position accessing tokens after end of list .
Issue Analytics
- State:
- Created 5 years ago
- Comments:5 (5 by maintainers)
Top Results From Across the Web
ArgumentOutOfRangeException Class (System)
An ArgumentOutOfRangeException exception is thrown when a method is invoked and at least one of the arguments passed to the method is not...
Read more >C# Exception Guide: ArgumentOutOfRangeException
The ArgumentOutOfRangeException exception is thrown when the argument passed to a method is not null and contains a value that is not within...
Read more >c# System.ArgumentOutOfRangeException
I'm making program that sends email with some data. I know that the System.ArgumentOutOfRangeException exception means that number in the array/ ...
Read more >Type: System.ArgumentOutOfRangeException
ArgumentOutOfRangeException is thrown when a method is invoked and at least one of the arguments passed to the method is not null and...
Read more >[Solved] How fix argumentoutofrangeexception
Exception : An unhandled exception of type 'System.ArgumentOutOfRangeException' occurred in PresentationFramework.dll Additional ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
create a branch from dev than commit on it and send me and send me a pull-request. Never commit directly on dev branch. for better tracking you should name your branch according to this issue : bugfix/78-argumentoutofrange or something like that
Should I commit to dev or make a separate branch for that issue?