I cannot understand problem with argument of the function

monarch_dodra monarchdodra at gmail.com
Thu Sep 19 00:47:32 PDT 2013


On Wednesday, 18 September 2013 at 21:13:27 UTC, mrd wrote:
> This bug reproducible also without a template:
>
> http://pastebin.com/QPvCFYL1
>
> $ ./bug
> works:
> Inside of body: value=1 type=ulong
> Inside of out contract: value=1 type=ulong result=[1]
> not works:
> Inside of body: value=300 type=ulong
> Inside of out contract: value=2 type=ulong result=[172, 2]

Well, as we have already concluded, you can't mutate your input 
arguments if you wish to use them again in your out contract.


More information about the Digitalmars-d-learn mailing list