From a6170f5298daf42931877a2d9c98e6f2ad1985be Mon Sep 17 00:00:00 2001 From: Reinier Zwitserloot Date: Sat, 31 Jan 2015 04:52:24 +0100 Subject: updated some copyright headers and reverted a change to use a TreeMap to force a more deterministic order to file processing in order to aid debugging. Also updated changelog. --- src/core/lombok/javac/JavacResolution.java | 2 +- src/core/lombok/javac/apt/Processor.java | 17 +++-------------- src/core/lombok/javac/handlers/HandleVal.java | 2 +- src/utils/lombok/javac/Javac.java | 2 +- src/utils/lombok/javac/TreeMirrorMaker.java | 2 +- 5 files changed, 7 insertions(+), 18 deletions(-) (limited to 'src') diff --git a/src/core/lombok/javac/JavacResolution.java b/src/core/lombok/javac/JavacResolution.java index 294d4fea..8063d5e3 100644 --- a/src/core/lombok/javac/JavacResolution.java +++ b/src/core/lombok/javac/JavacResolution.java @@ -1,5 +1,5 @@ /* - * Copyright (C) 2011-2014 The Project Lombok Authors. + * Copyright (C) 2011-2015 The Project Lombok Authors. * * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/core/lombok/javac/apt/Processor.java b/src/core/lombok/javac/apt/Processor.java index 783cf6b4..9979a066 100644 --- a/src/core/lombok/javac/apt/Processor.java +++ b/src/core/lombok/javac/apt/Processor.java @@ -1,5 +1,5 @@ /* - * Copyright (C) 2009-2012 The Project Lombok Authors. + * Copyright (C) 2009-2015 The Project Lombok Authors. * * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -28,14 +28,13 @@ import java.lang.reflect.Field; import java.lang.reflect.Method; import java.net.URL; import java.util.ArrayList; -import java.util.Comparator; import java.util.Enumeration; import java.util.HashSet; +import java.util.IdentityHashMap; import java.util.List; import java.util.Map; import java.util.Set; import java.util.SortedSet; -import java.util.TreeMap; import javax.annotation.processing.AbstractProcessor; import javax.annotation.processing.Messager; @@ -218,17 +217,7 @@ public class Processor extends AbstractProcessor { } } - // DEBUG - We just blithely assume that there's always a sourcefile.getName() component, and that the performance impact of this is not relevant. - // - ... but mostly the 'just blithely assume there's a sourcefile' part means we shouldn't just roll this out. - private final Map roots = new TreeMap(new Comparator() { - @Override public int compare(JCCompilationUnit o1, JCCompilationUnit o2) { - if (o1 == o2) return 0; - - int c = o1.sourcefile.getName().compareTo(o2.sourcefile.getName()); - if (c != 0) return c; - return System.identityHashCode(o1) < System.identityHashCode(o2) ? -1 : +1; - } - }); + private final IdentityHashMap roots = new IdentityHashMap(); private long[] priorityLevels; private Set priorityLevelsRequiringResolutionReset; diff --git a/src/core/lombok/javac/handlers/HandleVal.java b/src/core/lombok/javac/handlers/HandleVal.java index ea0e38f5..9eadd750 100644 --- a/src/core/lombok/javac/handlers/HandleVal.java +++ b/src/core/lombok/javac/handlers/HandleVal.java @@ -1,5 +1,5 @@ /* - * Copyright (C) 2010-2014 The Project Lombok Authors. + * Copyright (C) 2010-2015 The Project Lombok Authors. * * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/utils/lombok/javac/Javac.java b/src/utils/lombok/javac/Javac.java index 5b4a4fb2..003281ad 100644 --- a/src/utils/lombok/javac/Javac.java +++ b/src/utils/lombok/javac/Javac.java @@ -1,5 +1,5 @@ /* - * Copyright (C) 2009-2013 The Project Lombok Authors. + * Copyright (C) 2009-2015 The Project Lombok Authors. * * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/utils/lombok/javac/TreeMirrorMaker.java b/src/utils/lombok/javac/TreeMirrorMaker.java index a31c6477..621e4e00 100644 --- a/src/utils/lombok/javac/TreeMirrorMaker.java +++ b/src/utils/lombok/javac/TreeMirrorMaker.java @@ -1,5 +1,5 @@ /* - * Copyright (C) 2010-2011 The Project Lombok Authors. + * Copyright (C) 2010-2015 The Project Lombok Authors. * * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal -- cgit