code: func getBoolWithRestart(d *schema.ResourceData, key string) *bool {
  	if d.HasChange(key) {
  		d.Set("reboot_required", true)
  	}
  	return structure.GetBool(d, key)
  }
docs: // getBoolWithRestart fetches a *bool for the resource data item specified at
  // key. If the value has changed, a reboot is flagged in the virtual machine by
  // setting reboot_required to true.
  //
  // This function always returns at least false, even if a value is unspecified.