
Snippets are similar to having static preprocessing included in the editor, and do not require support by a compiler.

Snippets are thus primarily used when these abstractions are not available or not desired, such as in languages that lack abstraction, or for clarity and absence of overhead. This concrete inclusion is in contrast to abstraction methods, such as functions or macros, which are abstraction within the language.


In programming practice, "snippet" refers narrowly to a portion of source code that is literally included by an editor program into a file, and is a form of copy and paste programming.
