ImmutableStack<T>.Peek 方法
定义
返回位于堆栈顶部的对象但不将其移除。Returns the object at the top of the stack without removing it.
public:
virtual T Peek();
public T Peek ();
abstract member Peek : unit -> 'T
override this.Peek : unit -> 'T
Public Function Peek () As T
返回
- T
位于堆栈顶部的对象。The object at the top of the stack.
实现
例外
堆栈为空。The stack is empty.