What are all the programming languages that support XML literals natively or via extension? I know of VB.NET, Scala, and Factor. Any others?
Perl? I've never used it, but XML::Literal looks like a way to do XML literals in Perl.
XSLT comes to mind. And yes, it is a programming language.
Racket provides support for XML literals via XML Boxes. It also provides a very convenient S-expression based syntax for literal XML called X-expressions.
Facebook published a PHP Extension that allows XML document fragments to be embedded in PHP code.
From the documentation page linked to above:
XHP is a PHP extension which augments the syntax of the language such that XML document fragments become valid PHP expressions. This allows you to use PHP as a stricter templating engine and offers much more straightforward implementation of reusable components.
Perl? I've never used it, but XML::Literal looks like a way to do XML literals in Perl.
© 2022 - 2024 — McMap. All rights reserved.