summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* SI-8627 make Stream.filterNot non-eagerLukas Rytz2014-08-276-13/+139
| | | | | | | | | | | | | | | | The obvious fix, overriding `filterNot` in Stream, is not binary compatible, see https://github.com/scala/scala/pull/3925 Instead, this makes `filterImpl` in TaversableLike private[scala], which allows overriding it in Stream. The corresponding mima-failures can be whitelisted, as the changes are only to private[scala]. In 2.12.x we can remove the override of `filter` in Stream, but in 2.11.x this is not binary compatible. Eventually we'd also like to make filter / filterNot in TraversableLike final, but that's not source compatible, so it cannot be done in 2.12.x.
* Merge pull request #3909 from som-snytt/issue/8512Grzegorz Kossakowski2014-08-196-4/+40
|\ | | | | SI-8512 Infer a type for f"$args"
| * SI-8512 Infer Any for the qSom Snytt2014-08-123-2/+25
| | | | | | | | | | | | | | | | | | Avoid the widening bug for q. This resolution also suffers from the inference of Any, which can trigger a warning and an anxiety attack. But that's still better than doing the wrong thing. Right?
| * SI-8512 Infer a type for f"$args"Som Snytt2014-08-123-2/+15
|/ | | | | | | | | | | | The f-interpolator gets a type param that better be Any to avoid unfortunate widenings. Hey, it worked! Unfortunately, when `Any` is inferred, `-Xlint:infer-any` takes notice. This is probably a greater problem for the f-interpolator than for quasiquotes, which are a more specialized tool.
* Merge pull request #3927 from lrytz/innerClassesTestLukas Rytz2014-08-123-0/+310
|\ | | | | test for InnerClass and EnclosingMethod attributes
| * test for InnerClass and EnclosingMethod attributesLukas Rytz2014-08-123-0/+310
| | | | | | | | | | | | Some parts of the test assert (current) buggy behavior. This is marked in the test file with TODO. It will be fixed in later work on the backend.
* | Merge pull request #3907 from gourlaysama/wip/proxyLukas Rytz2014-08-124-0/+4
|\ \ | | | | | | a few missing deprecations in proxy collections.
| * | a few missing deprecations in proxy collections.Antoine Gourlay2014-07-314-0/+4
| | | | | | | | | | | | | | | | | | SeqProxy was properly deprecated, so were the CollProxyLike classes, and the ones in collection.immutable, but these four somehow survived the Big Proxy Deprecation (tm).
* | | Merge pull request #3902 from gourlaysama/wip/t4563Lukas Rytz2014-08-1280-81/+89
|\ \ \ | | | | | | | | SI-4563 friendlier behavior for Ctrl+D in the REPL
| * | | SI-4563 friendlier behavior for Ctrl+D in the REPLAntoine Gourlay2014-07-2980-81/+89
| |/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Closing the REPL with Ctrl+D does not issue a newline, so the user's prompt displays on the same line as the `scala>` prompt. This is bad. We now force a newline before closing the interpreter, and display `:quit` while we're at it so that people know how to exit the REPL (since `exit` doesn't exist anymore). The tricky part was to only add a newline when the console is interrupted, and *not* when it is closed by a command (like `:quit`), since commands are processed after their text (including newline) has been sent to the console.
* | | Merge pull request #3889 from som-snytt/issue/6476-altLukas Rytz2014-08-126-77/+75
|\ \ \ | |_|/ |/| | SI-6476 Improve error on escapement
| * | SI-6476 Unitize ALL the procedures!Som Snytt2014-07-192-27/+26
| | |
| * | SI-6476 Unitize procedures, readabilitySom Snytt2014-07-192-28/+24
| | | | | | | | | | | | | | | | | | | | | | | | Strictly trivial updates for readability. I used to prefer procedure syntax, but since it was scheduled for removal, I can't scan a def without an equals sign.
| * | SI-6476 DocumentationSom Snytt2014-07-183-18/+16
| | | | | | | | | | | | And adjust the test.
| * | SI-6476 Improve error on escapementSom Snytt2014-07-182-4/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Behavior of escape processing under string interpolation can be confusing. This commit improves the exception message so you know at least what sort of escapes are handled. This came up on SO in the form `s"\d".r`, where it may not be obvious what is throwing and how to work around it. ``` scala> s"\d".r scala.StringContext$InvalidEscapeException: invalid escape '\d' not one of [\b, \t, \n, \f, \r, \\, \", \'] at index 0 in "\d". Use \\ for literal \. scala> s"a\" scala.StringContext$InvalidEscapeException: invalid escape at terminal index 1 in "a\". Use \\ for literal \. ``` Referencing SI-6476 because that has become the magnet ticket for "escape processing under string interpolation, huh?" This doesn't address `$"` and doesn't handle the more interesting parse error `s"a\"b"`.
* | | Merge pull request #3914 from som-snytt/issue/orphan-checkGrzegorz Kossakowski2014-08-071-1/+0
|\ \ \ | | | | | | | | Orphan check file
| * | | Orphan check fileSom Snytt2014-08-031-1/+0
| | |/ | |/| | | | | | | | | | | | | Orphaned by the override check reversion that deleted the test source. 2524fdde3edc7b668fdb4bf68e990141d3ec18d6
* | | Merge pull request #3921 from gourlaysama/goodbye-jlineGrzegorz Kossakowski2014-08-0754-7654/+0
|\ \ \ | | | | | | | | remove jline sources from src/ now that we use a released jline.
| * | | remove jline sources from src/ now that we use a released jline.Antoine Gourlay2014-08-0754-7654/+0
| |/ / | | | | | | | | | | | | | | | We don't need those, right? We don't even build that folder anymore (since 1b0fa91), it is just dead code.
* | | Merge pull request #3916 from retronym/ticket/8781Grzegorz Kossakowski2014-08-074-1/+23
|\ \ \ | |/ / |/| | SI-8781 Avoid double-expansion under -Ymacro-expand:discard
| * | SI-8781 Avoid double-expansion under -Ymacro-expand:discardJason Zaugg2014-08-064-1/+23
|/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This mode of macro expansion is used by the presentation compiler to leave the original macro applications ("expandees") in the type checked trees, annotated with the types of the expansions. However, under some circumstances involving implicits, we would re-expand the macro. If the macro wasn't stable, this could lead to a type mismatch. The originally reported problem was with the shapeless `mkSingletonOps` macro. Its expansion had the type of a freshly-named class local to the expansion. Upon the re-expansion, a new class was generated, which lead to errors like: client/Client.scala:4: error: type mismatch; found : fresh$macro$2 required: fresh$macro$1 This commit suppressed re-expansion of the expandee by use of the existing, tree attachment driven mechanism.
* | Merge pull request #3895 from lrytz/jline-updateGrzegorz Kossakowski2014-07-251-0/+2
|\ \ | | | | | | Also update jline.version when update.versions is set during build
| * | Also update jline.version when update.versions is set during buildLukas Rytz2014-07-221-0/+2
| | |
* | | Merge pull request #3894 from adriaanm/depmsgGrzegorz Kossakowski2014-07-256-21/+25
|\ \ \ | | | | | | | | Better error message than 'bad symbolic reference'.
| * | | Better error message than 'bad symbolic reference'.Adriaan Moors2014-07-226-21/+25
| |/ / | | | | | | | | | | | | | | | Let's not scare people, and try to give them some advice. PS: we should really come up with a better mechanism for testing errors/warnings
* | | Merge pull request #3897 from lrytz/2.11.2-bumpGrzegorz Kossakowski2014-07-252-7/+7
|\ \ \ | | | | | | | | Bump versions for Scala 2.11.2
| * | | Bump versions for Scala 2.11.2Lukas Rytz2014-07-232-7/+7
| |/ /
* | | Merge pull request #3890 from dhgarrette/2.11.xGrzegorz Kossakowski2014-07-251-3/+1
|\ \ \ | | | | | | | | Remove "throws InvalidEscapeException" from StringContext.raw doc
| * | | Fixed incorrect example in StringContext.raw docDan Garrette2014-07-211-1/+1
| | | | | | | | | | | | As pointed out by @som-snytt, \u0023 is #, not \u0025.
| * | | Remove "throws InvalidEscapeException" from StringContext.raw docDan Garrette2014-07-211-2/+0
| |/ / | | | | | | Since StringContext.raw doesn't escape its input, it does not call `treatEscapes` and cannot throw the InvalidEscapeException.
* | | Merge pull request #3884 from mpociecha/remove-invalidation-from-globalGrzegorz Kossakowski2014-07-252-238/+0
|\ \ \ | | | | | | | | Remove invalidation from Global.scala
| * | | Remove invalidation from Global.scalampociecha2014-07-172-238/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The invalidation has been introduced in these commits: https://github.com/scala/scala/commit/167309afd10f9b65b35e6874a30ea6340a1ddc44 https://github.com/scala/scala/commit/ace051ff0abe112b767c3912f846eb4d50e52cf5 https://github.com/scala/scala/commit/e156d4a7cf4afdab91b7c281a0e8ae6e4743cc4a It's safe to remove this functionality. It was added originally to support an experiment with resident compilation. The experiment was performed in sbt and dropped in https://github.com/sbt/sbt/commit/6def08e029e474dc35af04b7403a2aeaddd0dec6 Since then Scala team concluded to not work on resident compilation so it's safe to delete unused code.
* | | | Merge pull request #3826 from lrytz/opt/refactorTrackedGrzegorz Kossakowski2014-07-2515-89/+481
|\ \ \ \ | | | | | | | | | | Assortiment of cleanups and comments around the backend
| * | | | Documentation for isModuleClassLukas Rytz2014-07-081-0/+3
| | | | |
| * | | | Support writing classfile of version 52Lukas Rytz2014-07-083-1/+3
| | | | |
| * | | | Clean up and document some usages of flags in the backendLukas Rytz2014-07-089-44/+154
| | | | |
| * | | | Pattern matching on ClassBType extracts the inernalNameLukas Rytz2014-07-081-22/+27
| | | | |
| * | | | Remove unnessecary check when computing InnerClass attribute flagsLukas Rytz2014-07-081-2/+13
| | | | | | | | | | | | | | | | | | | | The final flag is computed correctly by javaFlags.
| * | | | Comment summarizing the JVM spec for InnerClass / EnclosingMethodLukas Rytz2014-07-081-0/+199
| | | | |
| * | | | Minor cleanups and comments in GenBCodeLukas Rytz2014-07-086-21/+83
| | | | |
* | | | | Merge pull request #3896 from retronym/ticket/8743Grzegorz Kossakowski2014-07-256-34/+35
|\ \ \ \ \ | |_|_|/ / |/| | | | SI-8743 Fix crasher with poly-methods annotated with @varargs
| * | | | SI-8743 Fix crasher with poly-methods annotated with @varargsJason Zaugg2014-07-236-34/+35
|/ / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The code that generated the Java varargs forwarder was basing things on the `ValDef-s` of the parameters of the source method. But, their types refer to a type parameter skolems of the enclosing method, which led to a type mismatch when typechecking the forwarder. Instead, I've reworked the code to simply use the `DefDef`-s symbol's info, which *doesn't* refer to skolems. This actually simplifies the surrounding code somewhat; rather than repeated symbols in a map we can just time travel the pre-uncurry method signatures to figure out which params are releated.
* | | | Merge pull request #3888 from som-snytt/issue/8736v2.11.2Lukas Rytz2014-07-2110-9/+54
|\ \ \ \ | | | | | | | | | | SI-8736 Restore -language to former glory
| * | | | SI-8736 Error if no arg and no defaultSom Snytt2014-07-201-6/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Now `-language` with no option will emit an error: ``` $ skalac -feature -language unused.scala scalac error: '-language' requires an option. See '-language:help'. scalac -help gives more information ```
| * | | | SI-8736 Restore -language to former glorySom Snytt2014-07-2010-8/+50
| | |_|/ | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | MultiChoice allows -language to work like -Xlint. The bug as described was that the setting value was set instead of updated (++=) with additional flags. The unreported bug was that `_` no longer set all settings. The corrected behavior is that "contains" means "it was enabled, or _ was set and it was not disabled explicitly." That is the behavior of `-Xlint` but with a different mechanism, since each lint option is a Setting. A semantic difference is that -Xlint enables all the lint options, but -language does not enable all the language features. `scalac -X` does not explain this additional behavior of the `-Xlint` flag. Also worth noting that `scalac -feature -language unused.scala` failed in 2.11.1 but succeeds silently now.
* | | | Merge pull request #3887 from Ichoran/issue/8738Lukas Rytz2014-07-202-9/+26
|\ \ \ \ | |/ / / |/| | | SI-8738 Regression in range equality
| * | | SI-8738 Regression in range equalityRex Kerr2014-07-202-9/+26
|/ / / | | | | | | | | | | | | | | | Missed the case of comparing a non-empty range to an empty one. Fixed by checking nonEmpty/isEmpty on other collection. Added a test to verify the behavior.
* | | Merge pull request #3885 from som-snytt/issue/8525-cleanupLukas Rytz2014-07-189-110/+133
|\ \ \ | | | | | | | | SI-8525 Clarify usage of -Xlint:_,flag
| * | | SI-8525 MultiChoice takes a helper functionSom Snytt2014-07-185-20/+40
| | | | | | | | | | | | | | | | | | | | | | | | Clean-up code review comments. MultiChoice takes a helper function for outputting help text.
| * | | SI-8525 Multichoice helpSom Snytt2014-07-174-14/+38
| | | | | | | | | | | | | | | | | | | | | | | | Enables -Xlint:help and -language:help. The Settings API makes it difficult to innovate.