Queue/Definition: Difference between revisions

Line 1,289:
 
=={{header|ATS}}==
 
A common theme in these examples is that there is no runtime error for popping from an empty queue. Instead, you simply cannot compile a program that tries to pop from an empty queue. The type of a queue depends on its size, and you will get a type error if that size is zero.
 
=== A linear linked list as a queue ===
<lang ATS>(*------------------------------------------------------------------*)
1,448

edits