vendor/twig/twig/src/Resources/escaper.php line 36

Open in your IDE?
  1. <?php
  2. /*
  3. * This file is part of Twig.
  4. *
  5. * (c) Fabien Potencier
  6. *
  7. * For the full copyright and license information, please view the LICENSE
  8. * file that was distributed with this source code.
  9. */
  10. use Twig\Environment;
  11. use Twig\Extension\EscaperExtension;
  12. use Twig\Node\Node;
  13. use Twig\Runtime\EscaperRuntime;
  14. /**
  15. * @internal
  16. *
  17. * @deprecated since Twig 3.9
  18. */
  19. function twig_raw_filter($string)
  20. {
  21. trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
  22. return $string;
  23. }
  24. /**
  25. * @internal
  26. *
  27. * @deprecated since Twig 3.9
  28. */
  29. function twig_escape_filter(Environment $env, $string, $strategy = 'html', $charset = null, $autoescape = false)
  30. {
  31. trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
  32. return $env->getRuntime(EscaperRuntime::class)->escape($string, $strategy, $charset, $autoescape);
  33. }
  34. /**
  35. * @internal
  36. *
  37. * @deprecated since Twig 3.9
  38. */
  39. function twig_escape_filter_is_safe(Node $filterArgs)
  40. {
  41. trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
  42. return EscaperExtension::escapeFilterIsSafe($filterArgs);
  43. }