Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [cdt-dev] How to add comments and one more issue
  • From: Ming Cheng <chengm349@xxxxxxxxxxx>
  • Date: Mon, 2 Dec 2019 09:50:15 +0000
  • Accept-language: en-US
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none
  • Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=pvKiM97qfEzLwo2qDXhJSGAfMWtOvmoz650ib7wxAOo=; b=E2ZVvp7y70JI4BehtoI/zrTozFYOFxQLqzpHjgMtIRfMMzJ6DoiKHeBS/pUo2XaAawWgo1BB0JB21BwWptX35jX3mmzEtSIVFbpS7gGnNVkyZLpcrQlk6/cY9Iwk1tNjBvXhrnAwwFqlEWezuVNmt/XqR90Fgth8O/+o24g8uCk9WXRw+XLSE7kV1TUF7zySbzfdRL00iVZeeHrZutz4gnONUgU0lqXPU9p6RAMjwYjfCoQYyTwCH61qm1PHZVj33Q7zApoCQ0iaCng0ZwIVVv9GpI2YigzlCXYda0heNRPb23GgJ+gL1MM+XgUz69IdldCzhph58fBxkkYz8jHAaA==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=QxR3VTUAE0dpG3VeMJksk+zEJAgqQAlDeidZ28kor5g1CgreiH+bmHmN6U/6k6iM+nlqQ3CnIKiJ8WlmSyc4zRNpXVZ595GgxCgoP0iMuP41/sn1V30Ej8T4k7Dyh6MPXlHLn4GiVpsXyBH83Gm+bFQx9yezsO5U8TIVtdANqiYS/lg4wubIDkYwc6mtfexbkDwCdqJ1EKmcayDwWC/lWMspm73MEhiTkD9bm2Nf3AZwSwipwub2AqshCC3rnljj852i/HJwMgjsJdYS/KkDGYGm8pPWFMCIQHUmhvIgl9CaHreUeAAmFrFr8/ClhhkDassX/rxJCJ7GlkAbeNwO5g==
  • Delivered-to: cdt-dev@xxxxxxxxxxx
  • List-archive: <https://www.eclipse.org/mailman/private/cdt-dev>
  • List-help: <mailto:cdt-dev-request@eclipse.org?subject=help>
  • List-subscribe: <https://www.eclipse.org/mailman/listinfo/cdt-dev>, <mailto:cdt-dev-request@eclipse.org?subject=subscribe>
  • List-unsubscribe: <https://www.eclipse.org/mailman/options/cdt-dev>, <mailto:cdt-dev-request@eclipse.org?subject=unsubscribe>
  • Thread-index: AQHVpmtB8mCScUQrnUqeNjZMd1DicKemnsGa
  • Thread-topic: How to add comments and one more issue

Keen to receive any comment.

 

Sent from Mail for Windows 10

 

From: Ming Cheng
Sent: Friday, November 29, 2019 12:19 PM
To: cdt-dev@xxxxxxxxxxx
Subject: How to add comments and one more issue

 

Hi,

 

How to add “//” and “/* … */” style comments into a ITranslatorUnit?

 

I don’t know why the following code does not work as expected:

 

Void GenerateCPPSrc()

{

….

/*IInclude inc = tu.getInclude("QfixLogger.h");

                JOptionPane.showMessageDialog( null, "1" );

                if (false == inc.exists()) {

                    JOptionPane.showMessageDialog( null, "1.1" );

                    tu.createInclude("QfixLogger.h", false, null, monitor);

                    JOptionPane.showMessageDialog( null, "1.2" );

                }  else {

                    JOptionPane.showMessageDialog( null, "2" );

                }*/

…..

}

 

If my file does not have QfixLogger.h, I can see 1, but no 1.1/1.2, neither 2.

If I don’t do inc.exists() checking, and I call GenerateCPPSrc more than 1 time, then I can see several  “#include “QfixLogger.h” “ in my file.

 

Rgds.

Sent from Mail for Windows 10

 

 


Back to the top