Skip to content

min does not work correctly in the "eval" form #598

@maciejjaskowski

Description

@maciejjaskowski
p = {'p': [4,5]}
math.eval("min([1,2], p)", p)
>> 4

instead of [1,2]

This

math.eval("min([1,2], [4,5])")

works correctly.

This does NOT work either:

p = {'p': [4,5]}
math.min([1,2], p['p'])

but that works:

p = {'p': math.matrix([4,5])}
math.min([1,2], p['p'])

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions