From patchwork Fri Jan 27 00:11:14 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Josh Stone X-Patchwork-Id: 138088 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) by ozlabs.org (Postfix) with SMTP id 7B5D0B6FA0 for ; Fri, 27 Jan 2012 11:11:38 +1100 (EST) Comment: DKIM? See http://www.dkim.org DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d=gcc.gnu.org; s=default; x=1328227899; h=Comment: DomainKey-Signature:Received:Received:Received:Received:Received: Message-Id:Received:From:Date:To:Subject:Cc:User-Agent: MIME-Version:Content-Type:Content-Transfer-Encoding:Mailing-List: Precedence:List-Id:List-Unsubscribe:List-Archive:List-Post: List-Help:Sender:Delivered-To; bh=kZEH9KEfpX9xAzoOluttpwxNWrA=; b=j05/9DFNWtRlZdhvaAKXnmiP7/xg+UEnSzETamEPoZbhKBhpMxXzTRXPxU8KWl DqfBp5bXKtm7ZjN5ZJTN3wHRvi0b2H8C7nDtvFYsSVUBwAYPNmNEEw9pMWWSQryz OLAPubyr3hakTJNpMug3VMzd9WyPneEo1sqV+z9Zf27Zo= Comment: DomainKeys? See http://antispam.yahoo.com/domainkeys DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=default; d=gcc.gnu.org; h=Received:Received:X-SWARE-Spam-Status:X-Spam-Check-By:Received:Received:Received:Message-Id:Received:From:Date:To:Subject:Cc:User-Agent:MIME-Version:Content-Type:Content-Transfer-Encoding:Mailing-List:Precedence:List-Id:List-Unsubscribe:List-Archive:List-Post:List-Help:Sender:Delivered-To; b=hk2drLWS0TIajyarutaT3ie/BQ3NHMJD69VAyNMfAFkbRkB8HcNnXuKn3LRI40 Mh9WN/f3dJ4REtqCvqEvNeNl69EL2g4K3hI3KeaxOmC+9iwCz8/Xv0yLlbd6El1w UMC0L1o3nJTdJT6pzKNyzFgqRxg2NUifQb8OnUQKizUA4=; Received: (qmail 26550 invoked by alias); 27 Jan 2012 00:11:31 -0000 Received: (qmail 26539 invoked by uid 22791); 27 Jan 2012 00:11:29 -0000 X-SWARE-Spam-Status: No, hits=-6.4 required=5.0 tests=AWL, BAYES_00, MSGID_FROM_MTA_HEADER, RCVD_IN_DNSWL_HI, SPF_HELO_PASS, T_RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Fri, 27 Jan 2012 00:11:16 +0000 Received: from int-mx09.intmail.prod.int.phx2.redhat.com (int-mx09.intmail.prod.int.phx2.redhat.com [10.5.11.22]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id q0R0BG4S006447 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Thu, 26 Jan 2012 19:11:16 -0500 Received: from moya (ovpn-113-37.phx2.redhat.com [10.3.113.37]) by int-mx09.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with SMTP id q0R0BEli025658; Thu, 26 Jan 2012 19:11:14 -0500 Message-Id: <201201270011.q0R0BEli025658@int-mx09.intmail.prod.int.phx2.redhat.com> Received: by moya (sSMTP sendmail emulation); Thu, 26 Jan 2012 16:11:14 -0800 From: "Josh Stone" Date: Thu, 26 Jan 2012 16:11:14 -0800 To: gcc-patches@gcc.gnu.org Subject: [wwwdocs] Fix quoting in gcc-4.7/porting_to.html Cc: gerald@pfeifer.com, bkoz@redhat.com, jistone@redhat.com User-Agent: Heirloom mailx 12.5 7/5/10 MIME-Version: 1.0 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Delivered-To: mailing list gcc-patches@gcc.gnu.org Hi, I noticed that the porting example for c++11 user-defined literals is using "smart" double quotes, when code should have straight quotes. There's also an operator term that should be in the nearby block. Thanks, Josh 2012-01-26 Josh Stone * htdocs/gcc-4.7/porting_to.html: Use straight quotes in code examples, and expand a wrapper around the operator term. Index: htdocs/gcc-4.7/porting_to.html =================================================================== RCS file: /cvs/gcc/wwwdocs/htdocs/gcc-4.7/porting_to.html,v retrieving revision 1.6 diff -u -p -r1.6 porting_to.html --- htdocs/gcc-4.7/porting_to.html 12 Jan 2012 21:15:51 -0000 1.6 +++ htdocs/gcc-4.7/porting_to.html 26 Jan 2012 23:52:21 -0000 @@ -215,19 +215,19 @@ valid ISO C++03 code

-const char *p = “foobar”__TIME__;
+const char *p = "foobar"__TIME__;
 

In C++03, the __TIME__ macro expands to some string literal and is concatenated with the other one. In -C++11 __TIME__ isn't expanded, instead operator -“” __TIME__ is being looked up, resulting in the +C++11 __TIME__ isn't expanded, instead operator +"" __TIME__ is being looked up, resulting in the following diagnostic:

  error: unable to find string literal operator
- ‘operator“” __TIME__’
+ ‘operator"" __TIME__’