[Seed7-users] Interface Parameter Bug
Interpreter and compiler for the Seed7 programming language.
Brought to you by:
thomas_mertes
|
From: Zaakari <Za...@pr...> - 2022-07-23 20:49:34
|
Hey Thomas, It seems I have encountered a bug involving interfaces. I've attached a short script to demonstrate the problem, but--in short--if you pass an object as an "in var" parameter into a function accepting an interface type, then pass that parameter into a sub-function as an "inout" parameter, any changes made to the object in the sub-function will affect the original object at the top level (even though, it was initially passed in as "in var"). This problem doesn't seem to occur with either simple types (like integers) or with non-interface objects, just with implementation types. If you would take a look some time, that would be great. Thanks, Zachary |