evalf / nutils

The nutils project
http://www.nutils.org/
MIT License
88 stars 48 forks source link

rm function.replace, add deep and shallow variants #863

Closed gertjanvanzwieten closed 5 months ago

gertjanvanzwieten commented 5 months ago

This PR removes the general function.replace decorator and replaces it with the specialized deep_replace_property (used for simplified and optimized_for_numpy) and shallow_replace (used for replace_arguments, _deep_flatten_constants and _combine_loop_concatenates). The differences between the two constructs are as follows:

@deep_replace_property

@shallow_replace