You cannot post messages because only members can post, and you are not currently a member.
Description:
The main forum for questions and discussions about the Scala programming. In particular, the following should go to this list:
newbie questions.
programming experiences and questions.
|
|
|
Update/Reminder: Scala Community Code of Conduct
|
| |
Hello Everyone,
While the Mailing list code of conduct has always been available in the
welcome message of each google group, we've decided to centralize and flesh
out what our core values/philosphy are in the Scala community. We've
developed a Code of Conduct based on those found in other OSS projects,... more »
|
|
hmm, exceptions...
|
| |
Seems like scala people use to look down at exceptions... but see. The
difference between an error message and an exception is that an exception
tells you where the error happened. I actually use it in pretty unusual
places, like this:
*def jsREPL(implicit prompt:String = "type your js") {*
* val here = Thread.currentThread.getStackT race()(3)*... more »
|
|
2.9.x type inference bug workaround
|
| |
The following breaks on Scala 2.9.x, but works on 2.10+:
scala> def foo[A, C <: Traversable[A]](*c: C*) { println(c) }
scala> foo(Map.empty[String, Int])
<console>:9: error: inferred type arguments
[Nothing,scala.collection.immu table.Map[String,Int]] do not conform to
method foo's type parameter bounds [A,C <: Traversable[A]]... more »
|
|
Collection operators
|
| |
I know collection operators have been discussed at length, but this is an
unfortunate problem in a "typesafe" language.
scala> Set("foo") ++ Set("bar") + "baz"
res2: scala.collection.immutable.Set [java.lang.String] = Set(foo, bar, baz)
scala> Seq("foo") ++ Seq("bar") + "baz"
res3: java.lang.String = List(foo, bar)baz... more »
|
|
Future and nondeterministic dataflow
|
| |
From Future#isCompleted scaladoc: *Note: using this method yields nondeterministic dataflow programs.* What does it exactly - *in terms of a code* - mean?
|
|
new warnings in 2.10 for enumerations
|
| |
I just upgraded from 2.9.2 to 2.10.1, and I am getting warnings that I did not get before. Here's the relevant code: sealed trait ManeuverType object ManeuverType { // enumeration of maneuver types case object alt extends ManeuverType // altitude maneuver case object vec extends ManeuverType // horizontal "vector" maneuver... more »
|
|
Variable-length tuple?
|
| |
I've started an open-source project (SNMP4S<[link]>if you're interested), and I've run into a snag trying to accomplish my type-safety goals. I *think* what I need is some kind of variable-length tuple. A list won't work because the type of the contents are parameterized with different. A tuple accomplishes what I need, but I have... more »
|
|
Scala 2.11 compiler response speed improved?
|
| |
Hi all,
it seems to me that ScalaLab based on the latest 2.11 build has improved
response ("startup") time.
Does compiler improvements introduced recently (after 2.11 M2) in 2.11?
Stergios
|
|
mysql-async and postgresql-async 0.2.2 released
|
| |
I have just released a newer version of the postgresql-async project,
an async database connector for PostgreSQL written in Scala and I'm
happy to announce that now there is also a mysql-async project that
also offers an async connector for MySQL. Both projects use Netty as
their network communication framework.... more »
|
|
help with regex, forward slash is skipped
|
| |
Hello, I'm trying to parse ftp URI using scala regular expressions. My URI looks like this: val uri="[link]" My regex looks like this (according to URI spec): val Regex = """^ftp://(.*):(.*)@(.*)/(.*)" "".r However when I match by this regex URI is not parsed correctly:... more »
|
|
|