dominicm00 / ham

A meaty Jam build tool replacement

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Rule expansions in return statement yielding incorrect values

dominicm00 opened this issue · comments

Rule expansions in return statements cause the return value to be incorrect. Below is an MRE:

rule Identity x : y
{
    return $(x) $(y) ;
}

rule Two x
{
    local var = 2 ;
    return [ Identity $(x) : $(var) ] ;
}

rule One
{
    local var = 1 ;
    return [ Two $(var) ] ;
}

Echo [ One ] ;
-
$ jam
1 2
$ ham
2