gpt4 book ai didi

c# - CLR/C# 中的 "family of overloaded indexers"是什么?

转载 作者:太空宇宙 更新时间:2023-11-03 23:30:06 24 4
gpt4 key购买 nike

我正在阅读“Framework Design Guidelines”一书,我对其中一条规则(第 142 页)“不要在一种类型中提供超过一族的重载索引器”感到困惑。

我知道重载索引器的样子,但是什么构成了一个家庭?

最佳答案

通过 the lines

Some compilers, such as the C# compiler, enforce this guideline.

Multiple sets of indexers are not supported by some languages. If you use them, some developers will not be able to access these members.

我认为它的意思是“不要在一种类型中提供具有不同名称的索引器”。索引器系列将是一组具有相同名称的重载索引器。

关于c# - CLR/C# 中的 "family of overloaded indexers"是什么?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/32603656/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com