```{index} single: lock_hash_recurse; Hash::Util function ``` ```{index} single: Hash::Util::lock_hash_recurse; Perl function ``` # lock_hash_recurse Lock a hash and every nested hash it references, transitively. ## Synopsis lock_hash_recurse(%hash); Recurses only through hash-valued entries — a hash-of-hashes is locked throughout, but a hash-of-arrays-of-hashes has only the outermost hash locked because the recursion does not descend into arrays. Reach for `Data::Visitor` or write your own walker if you need deeper traversal. Returns a reference to the hash.