Evaluate

Evaluate[expr]

causes expr to be evaluated even if it appears as the argument of a function whose attributes specify that it should be held unevaluated.

Details

  • You can use Evaluate to override HoldFirst etc. attributes of builtin functions.
  • Evaluate only overrides HoldFirst etc. attributes when it appears directly as the head of the function argument that would otherwise be held. »

Examples

open allclose all

Basic Examples  (1)

Evaluate inside a Hold:

Scope  (1)

Evaluate works for arguments of any symbol with attributes HoldAll, HoldFirst, or HoldRest:

Since Attributes is HoldAll, use Evaluate to find the properties of the value of x:

Applications  (3)

Unprotect a system symbol to make a definition for it:

Restore protection:

Force evaluation of the right-hand side of a delayed definition:

Build a function from an expression:

Properties & Relations  (3)

Evaluate does not work inside functions with attribute HoldAllComplete:

Use Unevaluated to temporarily treat a function as if it were HoldAll:

Evaluate does not work inside Unevaluated:

Possible Issues  (1)

Evaluate works only on the first level, directly inside a held function:

Wolfram Research (1991), Evaluate, Wolfram Language function, https://reference.wolfram.com/language/ref/Evaluate.html.

Text

Wolfram Research (1991), Evaluate, Wolfram Language function, https://reference.wolfram.com/language/ref/Evaluate.html.

BibTeX

@misc{reference.wolfram_2020_evaluate, author="Wolfram Research", title="{Evaluate}", year="1991", howpublished="\url{https://reference.wolfram.com/language/ref/Evaluate.html}", note=[Accessed: 03-March-2021 ]}

BibLaTeX

@online{reference.wolfram_2020_evaluate, organization={Wolfram Research}, title={Evaluate}, year={1991}, url={https://reference.wolfram.com/language/ref/Evaluate.html}, note=[Accessed: 03-March-2021 ]}

CMS

Wolfram Language. 1991. "Evaluate." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/ref/Evaluate.html.

APA

Wolfram Language. (1991). Evaluate. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/Evaluate.html