Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [jdt-dev] Anyone spot a problem here ?
  • From: "Sankaran, Srikanth" <srikanth.sankaran@xxxxxxxxxxxxx>
  • Date: Wed, 25 Sep 2024 07:40:26 +0000
  • Accept-language: en-US
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=advantest.com; dmarc=pass action=none header.from=advantest.com; dkim=pass header.d=advantest.com; arc=none
  • Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=WPuNrWeHbcOA1PO7rPIur2QrQIwkr4CGaEbo6TyTD2U=; b=AYoSL1IFYxBLdGmv6yjqAwT59XZp7uDag5GcF/0hbKWPpai6ziIZ5cCD76mkkvx7VuvIvmiUCpoAHLuMaLT4b0Nn7YofIfJw4nczUlxHuVt81p9MZPDwX5rqq3eL562fPUe23EHmj/Dcuo4O58+BaT758NKbRUEB/LR1aUN2h+7nIL9vZuHBTd6z4KZA2UExoolWZ1iIQRCSTe8dmMIs9OHQy6EiIxww19GrnhN9KnAKZJGfi65E+f1EEcWC8FrCum67x3oSkomlrPujH0rr5/Q3n5NSIFUVa+smhWldL+GqyAsAHcl0k/0g05IIBSa/7j/D3i9yN8/X11CVn15Izw==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=cePsas+x5s3G+Kcqts1R687mebUR252ra9CoAzgNG3VIcbW8W7L3E/aoiRRL0t4PqPeJ4JrAUWbXT5FnsfOvZSHleKBaeqwOpkxLNwQ9U6xrff7CRsX6/o/B4jcxarlLFlQx5+KG0nq61kxKE7VQTGH6o1f9Rs7z7lMRA4tiTJgQPayPohtRAyEJFCn+2qZCQebRTkSOHOr/f/xDd6n4jJM6hmqmg0Q47mqGxL7fo+WvoRsCtHkVELeXqt8OzOFnpe9RQUw6t9I7ya4U99FoALQZIzQbr5MGGpPJCTKNcgLxkZvxSl3pqkyDw/HWOv4MGLPgNV4HceSVODwn8yUMzA==
  • Delivered-to: jdt-dev@xxxxxxxxxxx
  • List-archive: <https://www.eclipse.org/mailman/private/jdt-dev/>
  • List-help: <mailto:jdt-dev-request@eclipse.org?subject=help>
  • List-subscribe: <https://www.eclipse.org/mailman/listinfo/jdt-dev>, <mailto:jdt-dev-request@eclipse.org?subject=subscribe>
  • List-unsubscribe: <https://www.eclipse.org/mailman/options/jdt-dev>, <mailto:jdt-dev-request@eclipse.org?subject=unsubscribe>
  • Thread-index: AdsOS/M8o5uqHzW+R82yLFQbNvc/rQA0cFuQ
  • Thread-topic: Anyone spot a problem here ?

Here you go:

 

Comment above org.eclipse.jdt.internal.compiler.parser.Scanner.VanguardParser.parse(Goal) says:

// Canonical LALR pushdown automaton identical to Parser.parse() minus side effects of any kind, returns the rule reduced.

 

So if Parser.parse has any side effects visible to the scanner, they are going to be absent in  VanguardParser.parse.

So the setting of this.scanner.multiCaseLabelComma = this.currentToken == TerminalTokens.TokenNameCOMMA;

happens only in normal parse. And to the extent this flags steers subsequent tokenization, things are going to break!!!

 

Srikanth

 

From: jdt-dev <jdt-dev-bounces@xxxxxxxxxxx> On Behalf Of Sankaran, Srikanth via jdt-dev
Sent: 24 September 2024 12:06
To: jdt-dev@xxxxxxxxxxx
Cc: Sankaran, Srikanth <srikanth.sankaran@xxxxxxxxxxxxx>
Subject: [jdt-dev] Anyone spot a problem here ?

 

CAUTION: This email was sent from outside of Advantest.

 

In org.eclipse.jdt.internal.compiler.parser.Parser.consumeCaseLabelElement(CaseLabelKind) ?

 

Hint: in the line this.scanner.multiCaseLabelComma = this.currentToken == TerminalTokens.TokenNameCOMMA; ??

 

Srikanth


Back to the top