struct Element {}

type ElementStack = []&Element

fn (mut stack ElementStack) pop_front() ?&Element {
	return if stack.len > 0 {
		val := stack.first()
		stack.delete(0)
		val
	} else {
		none
	}
}

fn main() {
	mut stack := ElementStack([]&Element{})
	stack << &Element{}
	a := stack.pop_front()
	println(a)
}
