[builder] implement user-defined local variables