Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 366664 - [Xbase] wrong synthetic variable names for arrays
Summary: [Xbase] wrong synthetic variable names for arrays
Status: CLOSED FIXED
Alias: None
Product: TMF
Classification: Modeling
Component: Xtext (show other bugs)
Version: 2.2.0   Edit
Hardware: PC Mac OS X - Carbon (unsup.)
: P3 normal (vote)
Target Milestone: M5   Edit
Assignee: Jan Koehnlein CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-12-14 01:28 EST by Sven Efftinge CLA
Modified: 2017-09-19 17:18 EDT (History)
2 users (show)

See Also:
sven.efftinge: juno+


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Sven Efftinge CLA 2011-12-14 01:28:38 EST
def test(Object x) {
		switch x {
			String[] : x.get(0)
		}
	}

translates  to

  public String test(final Object x) {
    String _switchResult = null;
    boolean matched = false;
    if (!matched) {
      if (x instanceof String[]) {
        final String[] _string[] = (String[])x;
        matched=true;
        final String[] _typeConverted__string[] = (String[])_string[];
        String _get = ((List<String>)Conversions.doWrapArray(_typeConverted__string[])).get(0);
        _switchResult = _get;
      }
    }
    return _switchResult;
  }
Comment 1 Jan Koehnlein CLA 2012-01-17 10:55:37 EST
Pushed to MASTER
Comment 2 Karsten Thoms CLA 2017-09-19 17:07:17 EDT
Closing all bugs that were set to RESOLVED before Neon.0
Comment 3 Karsten Thoms CLA 2017-09-19 17:18:59 EDT
Closing all bugs that were set to RESOLVED before Neon.0