forked from projectlombok/lombok
Fork of Lombok. Experiments with Operator Overloading and @inline for inlining methods
License
amelentev/lombok-oo
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
This is fork of projectlombok for experiments. Operator Overloading: branch operatorOverloading Implementation of (Scala-like) Operator Overloading for Java language. Works with javac and Eclipse IDE. Works partially with Netbeans on maven based projects. Example (See also: ./usage_examples/OperatorOverload_post.jpage): import java.math.BigInteger; public class Test { public static void main(String[] args) { BigInteger a = BigInteger.valueOf(1), b = BigInteger.valueOf(2), c = a + b*a; System.out.println(c); } } Here `a+b*a` will be transformed to `a.add(b.multiply(a))`. Map operator to method: binary: "+" - "add", "-" - "subtract", "*" - "multiply", "/" - "divide", "%" - "remainder", "&" - "and", "|" - "or", "^" - "xor", "<<" - "shiftLeft", ">>" - "shiftRight" unary: "-" - "negate" "~" - "not" compare: "<","<=",">",">=" - "compareTo" These methods exists in many java classes (ex:BigInteger) so you can use operators on them "out of the box". Methods inlining: branch inline outdated Original README: projectlombok makes java a spicier language by adding 'handlers' that know how to build and compile simple, boilerplate-free, not-quite-java code. See LICENSE for the project lombok license. To start, run: ant -projecthelp HINT: If you'd like to develop lombok in eclipse, run 'ant eclipse' first. It creates the necessary project infrastructure and downloads dependencies. Project Authors: Reinier Zwitserloot twitter: @surial home: http://zwitserloot.com/ Roel Spilker twitter: @rspilker
About
Fork of Lombok. Experiments with Operator Overloading and @inline for inlining methods
Resources
License
Stars
Watchers
Forks
Packages 0
No packages published
Languages
- Java 99.5%
- Other 0.5%