From owner-sc22wg14+sc22wg14-domo2=www.open-std.org@open-std.org  Thu Jan 30 23:07:11 2025
Return-Path: <owner-sc22wg14+sc22wg14-domo2=www.open-std.org@open-std.org>
X-Original-To: sc22wg14-domo2
Delivered-To: sc22wg14-domo2@www.open-std.org
Received: by www.open-std.org (Postfix, from userid 521)
	id 60E21356661; Thu, 30 Jan 2025 23:07:11 +0100 (CET)
Delivered-To: sc22wg14@open-std.org
Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124])
	by www.open-std.org (Postfix) with ESMTP id 04A993565B8
	for <sc22wg14@open-std.org>; Thu, 30 Jan 2025 23:07:10 +0100 (CET)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com;
	s=mimecast20190719; t=1738274829;
	h=from:from:reply-to:subject:subject:date:date:message-id:message-id:
	 to:to:cc:mime-version:mime-version:content-type:content-type;
	bh=UruxzKZpxCLi4QBb3xQylb73+v4q8vpcXNaedW1A8fw=;
	b=jPuCy6bxX/H2EX7gIQlt/i2zvUITfRNfPrIfM1xQcvoUD+/gTN/Vq0ThwFZge5EDuDjeM+
	iRe3a1xsjRL92IBDndcxdUhisAu+WxL54Zos4CnSw7oEUsD3X00/MhRip4T/tq1yg1T2MB
	2YXvKFBNd8qV0K3XyFphfhhlxhkYGd0=
Received: from mail-wm1-f70.google.com (mail-wm1-f70.google.com
 [209.85.128.70]) by relay.mimecast.com with ESMTP with STARTTLS
 (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id
 us-mta-531-mcbCrSceOBq8SXUqnJCj-g-1; Thu, 30 Jan 2025 17:07:08 -0500
X-MC-Unique: mcbCrSceOBq8SXUqnJCj-g-1
X-Mimecast-MFC-AGG-ID: mcbCrSceOBq8SXUqnJCj-g
Received: by mail-wm1-f70.google.com with SMTP id 5b1f17b1804b1-4388eee7073so10943955e9.0
        for <sc22wg14@open-std.org>; Thu, 30 Jan 2025 14:07:08 -0800 (PST)
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
        d=1e100.net; s=20230601; t=1738274827; x=1738879627;
        h=mime-version:message-id:subject:to:from:date:x-gm-message-state
         :from:to:cc:subject:date:message-id:reply-to;
        bh=UruxzKZpxCLi4QBb3xQylb73+v4q8vpcXNaedW1A8fw=;
        b=mB/yNF78A8EMNA3mwXs0JKLwLRegT20iBzTotkXJRxykM+yA4pyd22zHwMh/Tx7B2x
         NoIuWbqcTGjt7Y+zLfIrpanMjErlsnmgUCwORu3XXGRBwmp3kxAzQWbFx0aQcCiiZxZM
         sDXbS6GsjhDP/Exm5xQMB7CObBiJcrNM4NT7Mqe82I2RH17lBgkwYHxm2iDh6/jqoK4T
         GNQfzhlHsHzcrsRua8o5spJ5Bl1ZT3WZOmiWZ1mTs6kCMxKcrjOUtOHs3+wNQQBnQA/c
         98OiDOjVKD//WFAwo1RbgHwZqGtT2iDSr6RWAWp5K97hZ9AA7s3sdPEjR7PgYSnt+xtD
         3VuA==
X-Gm-Message-State: AOJu0YzWMKDLmiuuEfMqPX4MLQshWW9yhlzLYqXdcWT1jMPYGmG28M6h
	f8//zC1WENKS7fndeyN4m3wyLoMpw4xKDfr9Bp6Qa3/ruKVVqAQUVMT7QMZVZNJZ/IGwwwS8JsP
	gS8mTTRfLg/bV+YqqgaTGoINOjAXOxtlngydrmwyLwtrXp6KZfrwTjic2ouOyKhMmZJnp7+hwlv
	yOdxOiosDP7sSxYFEfobIc9MNCf4qLbeC99ysE
X-Gm-Gg: ASbGncve0OPad29JC5ZuIkNiDLjoJEB1AilSY5oyAA+l5mNZIPp9+3/vwVPYE7nMmPO
	hk7HH5pn9epkbFk/xrk/E+OxOMxUQ1qHOvrcKp2n2HybvFylcL3ewqjjpnGn9DMdqR/B2yTqafj
	j/dzF6U07vLAzuzwR6HfJEqe1JyDQ88f10bhvqppxF4c89GL40yizZlYlzVzq1lhH5yTBwGY1kq
	OJcIIN4wLkqBLOl276o/nrlu6JOCGB0hU1poRBO12opidY8iyl6ZvOGqWX1OYS7s8la2PinITER
	W9n4F6m9NPQ7MDlbVNRZzDBDef54s++nTf8T
X-Received: by 2002:a05:600c:4ec7:b0:438:a313:cda9 with SMTP id 5b1f17b1804b1-438e6eff297mr10005515e9.10.1738274826780;
        Thu, 30 Jan 2025 14:07:06 -0800 (PST)
X-Google-Smtp-Source: AGHT+IG0RVZRmtK4VDCDyA+TF5HZYvbXutVQlsPmWGTdkkiaACrFCHaoZj1SVJc0o0060U+/HZUbRw==
X-Received: by 2002:a05:600c:4ec7:b0:438:a313:cda9 with SMTP id 5b1f17b1804b1-438e6eff297mr10005355e9.10.1738274826248;
        Thu, 30 Jan 2025 14:07:06 -0800 (PST)
Received: from digraph.polyomino.org.uk (digraph.polyomino.org.uk. [2001:8b0:bf73:93f7::51bb:e332])
        by smtp.gmail.com with ESMTPSA id ffacd0b85a97d-38c5c11fe22sm3024073f8f.41.2025.01.30.14.07.04
        for <sc22wg14@open-std.org>
        (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);
        Thu, 30 Jan 2025 14:07:05 -0800 (PST)
Received: from jsm28 (helo=localhost)
	by digraph.polyomino.org.uk with local-esmtp (Exim 4.97)
	(envelope-from <josmyers@redhat.com>)
	id 1tdcgg-0000000HR1L-2y16
	for sc22wg14@open-std.org;
	Thu, 30 Jan 2025 22:07:02 +0000
Date: Thu, 30 Jan 2025 22:07:02 +0000 (UTC)
From: Joseph Myers <josmyers@redhat.com>
To: sc22wg14@open-std.org
Subject: N3420 lvalue conversion of incomplete types
Message-ID: <43505ab9-c992-a3bd-2504-6d53cda3de0f@redhat.com>
MIME-Version: 1.0
X-Mimecast-Spam-Score: 0
X-Mimecast-MFC-PROC-ID: MvsGz_8hxqvGpS269EFknX0SR0bhVttXCHT4JhXuTgY_1738274827
X-Mimecast-Originator: redhat.com
Content-Type: text/plain; charset=US-ASCII
Sender: owner-sc22wg14@open-std.org
Precedence: bulk

N3420 proposes replacing undefined behavior for lvalue conversion of an 
incomplete type (other than void, since lvalues can't have type void) with 
a constraint violation.


1. I see my previous reversion of changes incorrectly applied from N3244 
item 19 was incomplete.  I've now filed 
https://gitlab.gwdg.de/iso-c/draft/-/merge_requests/513 to restore the 
sentence that N3420 would remove so that we can consider the change on the 
basis of a current working draft.

Could the editors please review the 36 open merge requests (preferably 
also issue 442 for a missing paper) so that we can get a new working draft 
issued before Graz that more accurately reflects what has and hasn't been 
approved so far for C2y and can be used as a basis for future work in 
Graz?


2. The proposed changes seem to make the constraint only apply where the 
"expression" syntax production is used - not in any case going through one 
of the other syntax productions for a particular kind of expression but 
not through "expression" itself.  For example, the LHS of a 
comma-expression would, after these changes, never go through the 
expression syntax production, so not be subject to the constraint 
(although it would be subject to the present UB).  Likewise if the lvalue 
with incomplete type is cast to void.  (In the case of an unselected 
generic association, the correct handling is a bit less clear.  The 
selected generic association can be used in a context where no lvalue 
conversion takes place, so what does that mean regarding constraints for 
lvalue conversion as applied to unselected generic associations, and does 
that depend at all on the context in which _Generic is used?)

-- 
Joseph S. Myers
josmyers@redhat.com

