Skip to content
Commit 3e44c304 authored by Tom Tromey's avatar Tom Tromey
Browse files

Allow lazy 'zero' value

This changes value_zero to create a lazy value.  In many cases,
value_zero is called in expression evaluation to wrap a type in a
non-eval context.  It seems senseless to allocate a buffer in these
cases.

A new 'is_zero' flag is added so we can preserve the existing
assertions in value_fetch_lazy.

A subsequent patch will add a test where creating a zero value would
fail, due to the variable size check.  However, the contents of this
value are never needed, and so creating a lazy value avoids the error
case.

parent a519e8ff
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment