List< T> .RemoveAt异常 [英] List<T>.RemoveAt Exceptions

查看:82
本文介绍了List< T> .RemoveAt异常的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想知道是否以某种方式修改了List< T> .RemoveAt ... 2007年编写此程序时,它抛出了IndexOutOfRangeException.我特别记得它引发了这些异常,并且我有关于异常的评论.

I am wondering if List<T>.RemoveAt has been modified in some way... When this program was written in 2007, it was throwing an IndexOutOfRangeException. I specifically remember it throwing those exceptions, and I have comments speaking about the exceptions.

但是,我正在检查新的元数据,并且据此,它仅引发ArgumentOutOfRangeException.我一直在试图找出是否/何时更改了该值...我有旧的日志显示它曾经抛出IndexOutOfRangeException.

But, I am checking the new metadata, and, according to that, it only throws ArgumentOutOfRangeException. I have been trying to figure out if/when this was changed... I have old logs showing that it used to throw IndexOutOfRangeException.

现在,我不确定是否需要遍历并修改所有代码...

Now, I'm unsure if I need to go through and modify all the code...

推荐答案

下面列出的所有框架版本都抛出ArgumentOutOfRangeException 

All version of the Framework listed below throw ArgumentOutOfRangeException 


这篇关于List&lt; T&gt; .RemoveAt异常的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆