[asterisk-dev] ^ delimiter for the M() option in Dial

Tilghman Lesher tilghman at meg.abyt.es
Wed Dec 15 19:45:38 UTC 2010

This is one of those "we did it for so long that now it's just legacy"
types of behaviors.  With a recent bugfix, though, to ensure that
literal semicolons can appear in realtime, by escaping them, we've
run into a conflict (see https://issues.asterisk.org/view.php?id=18279).

The reason why ^ was chosen as the delimiter for Macro arguments
dates back to a very early version of Dial, when we used a very simple
parser for Dial arguments that would not allow the application delimiter
to appear within arguments, even arguments surrounded by quotes or
parentheses.  In all currently supported versions of Asterisk, we use a
more intelligent parser that deals with delimiters within options
correctly.  Thus, there is no need to continue this workaround.  However,
due to legacy concerns, I am not suggesting that we discontinue
recognizing the caret delimiter, but rather, that we simply stop
documenting it.

Note that you can use the comma today, both within the M() option in
Dial, as well as within the GOTO:<label> MACRO_RESULT dialplan variable,
and everything will work correctly (as long as you aren't setting the
MACRO_RESULT variable in the dialplan with MSet).

Does anybody have an issue with changing the documentation to reflect
a comma (or pipe, for 1.4) as the delimiter for the M() option to Dial?


More information about the asterisk-dev mailing list