Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 363031 - [xbase][compiler] Allow to inline static extensions (e.g. operation_plus)
Summary: [xbase][compiler] Allow to inline static extensions (e.g. operation_plus)
Status: CLOSED FIXED
Alias: None
Product: TMF
Classification: Modeling
Component: Xtext (show other bugs)
Version: 2.1.0   Edit
Hardware: PC Mac OS X - Carbon (unsup.)
: P3 enhancement (vote)
Target Milestone: M6   Edit
Assignee: Project Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-11-07 04:44 EST by Sebastian Zarnekow CLA
Modified: 2017-09-19 17:06 EDT (History)
2 users (show)

See Also:
sebastian.zarnekow: juno+


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Sebastian Zarnekow CLA 2011-11-07 04:44:31 EST
I think a very simple approach could be something along these lines:

public class StringExtensions {

  @Inline("%0s + %1s")
  public static String operator_plus(String a, String b) {
    return a + b;
  }

}
Comment 1 Sebastian Zarnekow CLA 2012-02-27 15:07:27 EST
Pushed to master.
Comment 2 Jan Koehnlein CLA 2012-02-28 05:10:48 EST
Cool, macros in Xbase :-)
Comment 3 Karsten Thoms CLA 2017-09-19 16:55:42 EDT
Closing all bugs that were set to RESOLVED before Neon.0
Comment 4 Karsten Thoms CLA 2017-09-19 17:06:35 EDT
Closing all bugs that were set to RESOLVED before Neon.0