| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
| |
The paradigm is `def add(x: X): Unit = listBuffer += x`.
The value that is discarded is not new information.
Also cleans up the recent tweaks to help messaging.
Adds newlines in case they ask for multiple helps.
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
This is pretty easy, since a ValueSet is a BitSet.
When the setting is updated, recompute the current
set of values, which is cheap and succinct.
Checking a flag is also easy and fast.
Choices in MultiChoiceSettings may enable other choices.
|
|
|
|
|
|
| |
Clean-up code review comments.
MultiChoice takes a helper function for outputting help text.
|
|
|
|
|
|
| |
Enables -Xlint:help and -language:help.
The Settings API makes it difficult to innovate.
|
|
|
|
|
|
|
|
|
|
|
| |
And the Scala runner exits with 0 for info settings.
Producing the version string is consolidated.
The compiler driver uses the default settings hook to
short-circuit on -version. That's to avoid creating
the compiler; really it should check shouldStopWithInfo
first, as the runner does.
|
|
|
|
|
|
|
|
| |
-Xgenerate-phase-graph is comparable to -Xshow-phases.
The knowledge about what is an info-only option is refactored
to Settings, which also knows which group of options comprise
the optimiser set.
|
|
|
|
|
|
|
|
|
|
| |
What would you prefer?
adaptToMemberWithArgs(tree, qual, name, mode, false, false)
Or:
adaptToMemberWithArgs(tree, qual, name, mode, reportAmbiguous = false, saveErrors = false)
|
|
|
|
|
| |
All those old-timey methods whose melodies have become
unfashionable.
|
|
|
|
| |
This reverts commit 951fc3a486.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
I want to get this commit into the history because
the tests pass here, which demonstrates that every commented
out method is not only unnecessary internally but has zero
test coverage. Since I know (based on the occasional source
code comment, or more often based on knowing something about
other source bases) that some of these can't be removed
without breaking other things, I want to at least record
a snapshot of the identities of all these unused and
untested methods.
This commit will be reverted; then there will be another
commit which removes the subset of these methods which I
believe to be removable. The remainder are in great need of
tests which exercise the interfaces upon which other
repositories depend.
|
|
|
|
|
|
|
|
|
| |
A dizzying number of unused imports, limited to files
in src/compiler. I especially like that the unused import
option (not quite ready for checkin itself) finds places
where feature implicits have been imported which are no
longer necessary, e.g. this commit includes half a dozen
removals of "import scala.language.implicitConversions".
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
These are the regexp replacements performed:
Sxcala
-> Scala
Copyright (\d*) LAMP/EPFL
-> Copyright $1-2012 LAMP/EPFL
Copyright (\d*)-(\d*)(,?) LAMP/EPFL
-> Copyright $1-2012 LAMP/EPFL
Copyright (\d*)-(\d*) Scala Solutions and LAMP/EPFL
-> Copyright $1-2012 Scala Solutions and LAMP/EPFL
\(C\) (\d*)-(\d*) LAMP/EPFL
-> (C) $1-2012 LAMP/EPFL
Copyright \(c\) (\d*)-(\d*)(.*?)EPFL
-> Copyright (c) $1-2012$3EPFL
The last one was needed for two HTML-ified copyright notices.
Here's the summarized diff:
Created using
```
git diff -w | grep ^- | sort | uniq | mate
git diff -w | grep ^+ | sort | uniq | mate
```
```
- <div id="footer">Scala programming documentation. Copyright (c) 2003-2011 <a href="http://www.epfl.ch" target="_top">EPFL</a>, with contributions from <a href="http://typesafe.com" target="_top">Typesafe</a>.</div>
- copyright.string=Copyright 2002-2011, LAMP/EPFL
- <meta name="Copyright" content="(C) 2002-2011 LAMP/EPFL"/>
- * Copyright 2002-2011 LAMP/EPFL
- * Copyright 2004-2011 LAMP/EPFL
- * Copyright 2005 LAMP/EPFL
- * Copyright 2005-2011 LAMP/EPFL
- * Copyright 2006-2011 LAMP/EPFL
- * Copyright 2007 LAMP/EPFL
- * Copyright 2007-2011 LAMP/EPFL
- * Copyright 2009-2011 Scala Solutions and LAMP/EPFL
- * Copyright 2009-2011 Scxala Solutions and LAMP/EPFL
- * Copyright 2010-2011 LAMP/EPFL
- * Copyright 2012 LAMP/EPFL
-# Copyright 2002-2011, LAMP/EPFL
-* Copyright 2005-2011 LAMP/EPFL
-/* NSC -- new Scala compiler -- Copyright 2007-2011 LAMP/EPFL */
-rem # Copyright 2002-2011, LAMP/EPFL
```
```
+ <div id="footer">Scala programming documentation. Copyright (c) 2003-2012 <a href="http://www.epfl.ch" target="_top">EPFL</a>, with contributions from <a href="http://typesafe.com" target="_top">Typesafe</a>.</div>
+ copyright.string=Copyright 2002-2012 LAMP/EPFL
+ <meta name="Copyright" content="(C) 2002-2012 LAMP/EPFL"/>
+ * Copyright 2002-2012 LAMP/EPFL
+ * Copyright 2004-2012 LAMP/EPFL
+ * Copyright 2005-2012 LAMP/EPFL
+ * Copyright 2006-2012 LAMP/EPFL
+ * Copyright 2007-2012 LAMP/EPFL
+ * Copyright 2009-2012 Scala Solutions and LAMP/EPFL
+ * Copyright 2010-2012 LAMP/EPFL
+ * Copyright 2011-2012 LAMP/EPFL
+# Copyright 2002-2012 LAMP/EPFL
+* Copyright 2005-2012 LAMP/EPFL
+/* NSC -- new Scala compiler -- Copyright 2007-2012 LAMP/EPFL */
+rem # Copyright 2002-2012 LAMP/EPFL
```
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
Reflection toolboxes now respect settings that are provided to them.
Before the fix CompilerCommand lacked the (args, settings, errorFn)
ctor. I added it and provided means to augment passed settings with
custom errorFn.
Closes SI-5239. Review by odersky.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Created infrastructure for testing icode + settings/partest yak shaving.
See enclosed test files/run/inline-ex-handlers.scala. To compare
optimized and unoptimized icode after a given phase, all you need in a
partest source file is this:
import scala.tools.partest.IcodeTest
object Test extends IcodeTest {
override def printIcodeAfterPhase = "inlineExceptionHandlers"
}
Other things can be done, see IcodeTest.scala. Review by ureche.
|
|
|
|
|
|
|
| |
Documented what I could figure out about late flags and anti-flags.
Eliminated some indirection in flag usage. Made -Xshow-phases print out
more info about flags if -Ydebug is also given. No review.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Wanting to deprecate -make, first I had to write a way to deprecate
-make. So there's that, now you can do
val s = SomeSetting(...) withDeprecationMessage "don't use this"
And it will do the usual deprecation things. And, deprecated -make. And
couldn't resist fixing a bug in -make, it would crash if you gave it its
own default option (i.e. -make:all.) Let's deprecate more!
I also did further cleaning up of our help outputs. Do I smell a
pulitzer in the making? No review.
|
|
|
|
|
|
| |
A paltry 570 cases failing in -Xcheckinit due to some uninitialized val
or other. It is but a trifle! No review.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Trying to get fsc doing the right thing with respect to absolute and
relative paths. My knowledge of the problem had heretofore been second
hand, and my understanding of it incomplete. The real problem I have
determined is that there are a bunch of different things which go wrong
if relative paths start being resolved from a different base, each of
which needs custom handling.
classpath-style options, e.g. fsc -cp ../foo.jar
path-style options, e.g. fsc -d ../mydir
file arguments, e.g. fsc ../foo.scala
So it was more work than I had realized, or I probably wouldn't have
even touched it. But now it seems to be working as one would want. I
also poured some readability onto the fsc help output.
Closes #4395, no review, but community input would be great.
|
|
|
|
|
|
| |
Improved the error message when one gives invalid options to scala.
Similar improvements for scalac/fsc/etc has to wait. No review.
|
|
|
|
|
|
| |
Eliminating duplication and trying to outrun obsolescence in the
exciting world of fsc. No review.
|
| |
|
|
|
|
|
|
|
|
|
|
| |
Investigating what can be done about our 2000 or so closures created
via by-name calls takes me through uncurry with a mop. Sifting through
compiler generated classfiles I am horrified at one example of decadent
closure creation perpetrated by a certain extempore. CompilerCommand
goes from 28 classfiles to 16 and manages to get smaller anyway anyway.
Some people just can't be trusted with closures. No review.
|
|
|
|
|
|
|
|
| |
Cleaned up and brought up to date the help text for -X and -Y options.
Made some enhancements to PhasesSetting, which are documented if you
run scalac -X or -Y. (Try it!) Disabled some dead settings and renamed
others to reflect their current purpose. No review.
|
|
|
|
|
| |
Removed more than 3400 svn '$Id' keywords and related junk.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
While working on partest discovered that CompilerCommand ignores half
its constructor arguments and a couple dozen places blithely pass it
those arguments as if they're being used. Then there were setups like
this:
class OfflineCompilerCommand(
arguments: List[String],
settings: Settings,
error: String => Unit,
interactive: Boolean)
extends CompilerCommand(arguments, new Settings(error), error, false)
Hey offline compiler command, why throw away the perfectly good settings
you were given? Ever heard 'reduce, reuse, recycle'? How did you ever
work... or do you? No review.
|
|
|
|
|
|
| |
Removed ArgumentsExpander in favor of having all arguments parsed the
same way. No review.
|
|
|
|
|
|
|
|
|
| |
One minute too many trying to figure out where some partest classpath
mutation was disappearing on me, and I snapped and started the process
of creating an immutable Settings. This commit is for the most part
infrastructure to enable its smooth and uneventful entrance. Review by
community.
|
|
|
|
|
|
|
|
|
| |
Some much needed housecleaning regarding system properties. If you can
possibly resist the temptation, it'd be great if people could try to
go through the properties classes to get and set them, and also to set
property values somewhere fixed rather than using strings directly.
Review by community.
|
|
|
|
|
|
| |
More laboring on Settings, ClassPaths, Ant Tasks, Partest, and similar
epicenters of thrilldom. No review.
|
|
|
|
|
|
|
|
|
| |
which we must have no test cases at all. In the short term there
will probably be a few more minor disruptions since with classpaths
constructed a half dozen different ways, achieving consistency requires
flushing out the undocumented accidents upon which any given island
might depend. Review by community.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
at https://lampsvn.epfl.ch/trac/scala/wiki/Classpath modulo some minor
details which remain to be investigated. It is not entirely integrated,
and should not involve any behavioral changes. The patch also contains a
number of small improvements targetting widely duplicated code.
PathResolver offers a main method. If run with no arguments it will
output a pile of information about classpath relevant environment vars
and properties. If given arguments, it will output the classpath info
that any scala runner script would use if given the same args. There is
a wrapper in the tools directory. Example:
tools/pathResolver -extdirs /foo -sourcepath /bar | egrep
"sourcePath|scalaExtDirs"
scalaExtDirs = /foo
sourcePath = /bar
There is also a (probably temporary) command line option -Ylog-classpath
which will print out the settings.classpath value anytime it changes.
Review by community.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Digging into why the repl is so slow, discovered that fsc is once again
never reusing compiler instances (but for a different reason than
#1683.) Small changes break equality and the little troopers are so darn
quiet about it. Steady state, hot fsc repl startup times before this
patch:
0m1.747s 0m1.789s 0m1.842s 0m1.690s
After this patch:
0m1.139s 0m1.148s 0m1.090s 0m1.091s
No review. Could use a test case but I have trouble coaxing partest this
far outside the box.
|
| |
|
| |
|
| |
|
|
|
|
|
| |
Various cleanups and redundancy-removal related to properties.
|
| |
|
|
|
|
|
|
|
| |
manage existing settings and add new ones. It's paving the way for
low-fuss scalac preferences so we can exert fine grained config file
based control over compiler behavior.
|
|
|
|
|
| |
removed deprecated warning, updated svn props, cleaned up code
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
The handling of informative messages in CompileServer and in Main was
duplicated, and the two copies slowly diverged over time. The code has
now been refactored, cleaned up, and made more general.
The FakePos(fsc) message was due to a missing override def toString.
Both problems are fixed.
|
|
|
|
|
|
|
| |
1) Fix in backend to print meaningful filenames (previously it was
"[wrote DataOutputStream@6747]" 2) Treat java varargs as Scala varargs
3) Allow parsing of Java source files
|
|
|
|
|
|
|
|
|
|
|
| |
of Settings. All doc related settings have been commented out of
Settings (soon to be removed) and are now found in doc.Settings.
-Ydoc is no more.
I believe I have updated the scaladoc Ant task correctly, but it is not
clear how to test it.
|