Ticket #768: started.patch

File started.patch, 3.1 KB (added by westram, 7 years ago)

started to document new behavior

  • ARBDB/adlang1.cxx

     
    314314 *
    315315 * 3. operator(x, y)
    316316 *
    317  *    @@@ this decription does not match behavior!
    318  *    @@@ check description in helpfile as well
     317 *    The operator is applied to the arguments.
     318 *    If an argument is a command (starts with one of "|:/"),
     319 *    it will get executed on inputstream and the result will be used.
    319320 *
    320  *    Inputstreams will be ignored and the operator is applied
    321  *    to the arguments
    322  *
    323321 *    Example : a;b | plus(c,d)
    324322 *    Result  : c+d
    325323 */
     
    354352
    355353        case 2:
    356354            for (int i = 0; i<args->input.size(); ++i) {
     355                // @@@ need a getter method for params (pass number of param + number of input-stream (or -1 to use ""))
    357356                char *result1       = args->get_callEnv().interpret_subcommand(args->input.get(i), args->get_param(0)); // @@@ EVALUATED_PARAM (#768)
    358357                if (!result1) error = GB_await_error();
    359358                else {
  • HELP_SOURCE/oldhelp/aci.hlp

     
    9595        Multiple parameters have to be separated by ',' or ';'.
    9696
    9797        There are two distinct ways to specify such a parameter:
    98         - unquoted
    9998
     99         - unquoted
     100
    100101          Unquoted parameters are taken as specified, despite the following exceptions:
    101102           - ',;"|\)' need to be escaped by prefixing one '\'
    102103           - spaces will get removed if unprefixed by '\'
    103104
    104         - quoted
     105         - quoted
    105106
    106107          Quoted parameters begin and end with a '"'. You can use any character,
    107108          but you need to escape '\' and '"' by preceeding a '\'.
     
    109110          Example: 'remove("\"")' will remove all double quotes from input.
    110111                   'remove("\\")' will remove all backslashes from input.
    111112
    112         [@@@ behavior currently not strictly implemented]
     113        If the first character of a parameter is ':', '|' or '/' the value of the
     114        parameter is interpreted as SRT, ACI or REG expression and will be
     115        applied (to an empty input string) and its result will be used as the actual parameter.
    113116
    114117SECTION COMMANDLIST
    115118
     
    302305                    - has 1 argument, it accepts one to many input streams. The operator
    303306                      is applied to each input stream together with the argument.
    304307                      For each input stream one output stream is generated.
    305                     - has 2 arguments, it is applied to these. The arguments are interpreted as
    306                       ACI commands and are applied for each input stream. The results of
    307                       the commands are passed as arguments to the binary operator. For each input
    308                       stream one output stream is generated.
     308                    - has 2 arguments, it is applied to these (once for each input stream).
    309309
    310310        CONDITIONAL
    311311