samples/ydl2idl.ysl2
author Volker Birk <vb@pep.foundation>
Sun, 15 Oct 2017 09:05:19 +0200
changeset 16 da8160da8d3e
parent 0 76005e62091d
permissions -rw-r--r--
glob() does not sort any more - adding sorted() function
include yslt.yml2

tstylesheet {
    template "module" {
        | module «name(*)» {
        apply "*/interface";
        | };
    }

    template "interface" {
        | interface «name(*)» {
        apply "*/*", mode="func";
        | };
    }

    template "*", mode="func"
        | «name(.)» «name(*)»(`apply "*/*", mode="parms";`);

    template "*", mode="parms" {
        > «name(.)» «name(*)» «name(*/*)»
        if "position() != last()" > , 
    }
}