Skip to content
Snippets Groups Projects
Commit 658f2dc9 authored by Richard Henderson's avatar Richard Henderson Committed by Blue Swirl
Browse files

linux-user: Rewrite __get_user/__put_user with __builtin_choose_expr


The previous formuation with multiple assignments to __typeof(*hptr) falls
down when hptr is qualified const.  E.g. with const struct S *p, p->f is
also qualified const.

With this formulation, there's no assignment to any local variable.

Signed-off-by: default avatarRichard Henderson <rth@twiddle.net>
Signed-off-by: default avatarBlue Swirl <blauwirbel@gmail.com>
parent c732a52d
No related branches found
No related tags found
No related merge requests found
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment