不能传入out或ref
public IEnumerable<Shop> GetShop() { for (int i = 1; i < 11; i++) { yield return new Shop { ID = i, Name = "Shop-" + i }; } }
不能传入out或ref
public IEnumerable<Shop> GetShop() { for (int i = 1; i < 11; i++) { yield return new Shop { ID = i, Name = "Shop-" + i }; } }