[U-Boot] setexpr and memory access

I feel sometimes it could be convenient to use setexpr to use a memory location as argument. The code for that is pretty trivial but the question (and reason for mailing this instead of just submitting the patch) is the syntax of the command.
setexpr uses A op B and one of the possibilities for op is a *. If we also allow a * to dereference things (like done in itest) we could get something like setexpr result *3 * *4 Not sure if that is a desirable syntax.
Your opinion on this extension and syntax is appreciated.
Frans

Dear Frans,
In message ac9c93b11002240514w75d010ao8b3a52ca8ef015af@mail.gmail.com you wrote:
setexpr uses A op B and one of the possibilities for op is a *. If we also allow a * to dereference things (like done in itest) we could get something like setexpr result *3 * *4 Not sure if that is a desirable syntax.
Agreed it looks ugly, but it's the logical consequence of what we are using so far. Any other solution would probably require changes in some other areas.
Considering that, your suggestion looks fine to me.
Best regards,
Wolfgang Denk
participants (2)
-
Frans Meulenbroeks
-
Wolfgang Denk