List of deprecated built-ins

The following built-ins are deprecated, but still working:

  • default: This was deprecated with the introduction of the default value operator. exp1?default(exp2) is near equivalent with exp1!exp2, and (exp1)?default(exp2) is near equivalent with with (exp1)!exp2. The only difference is that prior to FreeMarker 2.4, the default built-in has always evaluated exp2, while the default value operator only evaluates it when the default value is really needed. Starting from FreeMarker 2.4, however, the default built-in was improved, and behaves exactly like the default value operator.

  • exists: This was deprecated with the introduction of the missing value test operator. exp1?exists is equivalent with exp1??, also (exp1)?exists is equivalent with with (exp1)??.

  • if_exists: This was deprecated with the introduction of the default value operator. exp1?if_exists is similar to exp1!, and (exp1)?if_exists is similar to (exp1)!. The difference is that the default value with if_exists is not only empty string, empty sequence and empty hashs at the same time, but also boolean false and a transform that does nothing and ignores all parameters.

  • web_safe: the same as html