Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 545539 - [12] BreakStatement should not expose setImplicit( boolean) to public
Summary: [12] BreakStatement should not expose setImplicit( boolean) to public
Status: RESOLVED FIXED
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Core (show other bugs)
Version: 4.11   Edit
Hardware: PC Windows 7
: P3 normal (vote)
Target Milestone: BETA J12   Edit
Assignee: Sarika Sinha CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 539080 544748
  Show dependency tree
 
Reported: 2019-03-19 06:03 EDT by Sarika Sinha CLA
Modified: 2019-03-19 11:57 EDT (History)
2 users (show)

See Also:
manoj.palat: review+


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Sarika Sinha CLA 2019-03-19 06:03:10 EDT
As per discussion in Bug 539080 - [12] Switch AST to JLS12,

Dom need not expose setImplicit(boolean) method to public.
Comment 1 Eclipse Genie CLA 2019-03-19 06:05:26 EDT
New Gerrit change created: https://git.eclipse.org/r/139007
Comment 2 Sarika Sinha CLA 2019-03-19 06:19:00 EDT
Why it should not be used by client -
1. case 1->2;
  changes to 
   case 1->{
            System.out.println("2");
           break 2;
           }

Client needs to remove the expression statement for "2" and add the block statement with sysout and break statements.

2. case 2->{
            System.out.println("2");
           break 2;
           }

changes to 
  case 1->2;

Client needs to remove the block statement and add the expression statment for "2". compiler will add the implicit break statement.
Comment 3 Manoj N Palat CLA 2019-03-19 06:34:05 EDT
(In reply to Sarika Sinha from comment #0)
> Dom need not expose setImplicit(boolean) method to public.

Agree. This was intended to be non-public by design

(In reply to Sarika Sinha from comment #2)
> Why it should not be used by client -
> for "2". compiler will add the implicit break statement.

+1. This is internally used by the compiler. Client should not be using this.