Re: The Scala REPL output is confusing

Oliver Ruebenacker <[email protected]> Mon, 31 Oct 2016 16:55:08 -0400
Newsgroups gmane.comp.lang.scala
Message-ID <CAA=X4OBxFY1RJccD+RjdFZ3UPOX-vmWZL6e0jVsH9DfGA2mKBg@mail.gmail.com>
--001a113f49e4527dc205402f6c9b
Content-Type: text/plain; charset=UTF-8

     Hello,

  That would add unnecessary clutter. Whoever entered the line knows they
used def.

     Best, Oliver

On Mon, Oct 31, 2016 at 4:51 PM, Raphael Bosshard <
[email protected]> wrote:

> Hi all,
>
> have you ever noticed how confusing the Scala REPL output it?
>
> scala> def foo(in: String): Int = ???
> foo: (in: String)Int
>
> I have learned what this "foo: (in: String)Int) is supposed to mean. But
> from a beginner's perspective I find it puzzling. Instead it should display
> something like this:
>
> method created: foo(in: String): Int
>
> Would someone support/guide me in fixing this?
>
> Cheers,
> Raphael
>
>
>
> --
> You received this message because you are subscribed to the Google Groups
> "scala-language" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> For more options, visit https://groups.google.com/d/optout.
>



-- 
Oliver Ruebenacker
Senior Software Engineer, Diabetes Portal
<http://www.type2diabetesgenetics.org/>, Broad Institute
<http://www.broadinstitute.org/>

-- 
You received this message because you are subscribed to the Google Groups "scala-language" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [email protected].
For more options, visit https://groups.google.com/d/optout.

--001a113f49e4527dc205402f6c9b
Content-Type: text/html; charset=UTF-8
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr"><div><div><div><br></div>=C2=A0=C2=A0=C2=A0=C2=A0 Hello,<b=
r><br></div>=C2=A0 That would add unnecessary clutter. Whoever entered the =
line knows they used def. <br><br></div>=C2=A0=C2=A0=C2=A0=C2=A0 Best, Oliv=
er<br></div><div class=3D"gmail_extra"><br><div class=3D"gmail_quote">On Mo=
n, Oct 31, 2016 at 4:51 PM, Raphael Bosshard <span dir=3D"ltr">&lt;<a href=
=3D"mailto:[email protected]" target=3D"_blank">raphael.bosshard@g=
mail.com</a>&gt;</span> wrote:<br><blockquote class=3D"gmail_quote" style=
=3D"margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir=
=3D"ltr">Hi all,<br><br>have you ever noticed how confusing the Scala REPL =
output it?<br><br><div style=3D"background-color:rgb(250,250,250);border-co=
lor:rgb(187,187,187);border-style:solid;border-width:1px" class=3D"m_749086=
6102373541101prettyprint"><code class=3D"m_7490866102373541101prettyprint">=
<div class=3D"m_7490866102373541101subprettyprint"><span style=3D"color:#00=
0" class=3D"m_7490866102373541101styled-by-prettify">scala</span><span styl=
e=3D"color:#660" class=3D"m_7490866102373541101styled-by-prettify">&gt;</sp=
an><span style=3D"color:#000" class=3D"m_7490866102373541101styled-by-prett=
ify"> </span><span style=3D"color:#008" class=3D"m_7490866102373541101style=
d-by-prettify">def</span><span style=3D"color:#000" class=3D"m_749086610237=
3541101styled-by-prettify"> foo</span><span style=3D"color:#660" class=3D"m=
_7490866102373541101styled-by-prettify">(</span><span style=3D"color:#008" =
class=3D"m_7490866102373541101styled-by-prettify">in</span><span style=3D"c=
olor:#660" class=3D"m_7490866102373541101styled-by-prettify">:</span><span =
style=3D"color:#000" class=3D"m_7490866102373541101styled-by-prettify"> </s=
pan><span style=3D"color:#606" class=3D"m_7490866102373541101styled-by-pret=
tify">String</span><span style=3D"color:#660" class=3D"m_749086610237354110=
1styled-by-prettify">):</span><span style=3D"color:#000" class=3D"m_7490866=
102373541101styled-by-prettify"> </span><span style=3D"color:#606" class=3D=
"m_7490866102373541101styled-by-prettify">Int</span><span style=3D"color:#0=
00" class=3D"m_7490866102373541101styled-by-prettify"> </span><span style=
=3D"color:#660" class=3D"m_7490866102373541101styled-by-prettify">=3D</span=
><span style=3D"color:#000" class=3D"m_7490866102373541101styled-by-prettif=
y"> </span><span style=3D"color:#660" class=3D"m_7490866102373541101styled-=
by-prettify">???</span><span style=3D"color:#000" class=3D"m_74908661023735=
41101styled-by-prettify"><br>foo</span><span style=3D"color:#660" class=3D"=
m_7490866102373541101styled-by-prettify">:</span><span style=3D"color:#000"=
 class=3D"m_7490866102373541101styled-by-prettify"> </span><span style=3D"c=
olor:#660" class=3D"m_7490866102373541101styled-by-prettify">(</span><span =
style=3D"color:#008" class=3D"m_7490866102373541101styled-by-prettify">in</=
span><span style=3D"color:#660" class=3D"m_7490866102373541101styled-by-pre=
ttify">:</span><span style=3D"color:#000" class=3D"m_7490866102373541101sty=
led-by-prettify"> </span><span style=3D"color:#606" class=3D"m_749086610237=
3541101styled-by-prettify">String</span><span style=3D"color:#660" class=3D=
"m_7490866102373541101styled-by-prettify">)</span><span style=3D"color:#606=
" class=3D"m_7490866102373541101styled-by-prettify">Int</span><span style=
=3D"color:#000" class=3D"m_7490866102373541101styled-by-prettify"><br></spa=
n></div></code></div><br>I have learned what this &quot;foo: (in: String)In=
t) is supposed to mean. But from a beginner&#39;s perspective I find it puz=
zling. Instead it should display something like this:<br><span style=3D"col=
or:#000" class=3D"m_7490866102373541101styled-by-prettify"></span><br><span=
 style=3D"color:#000" class=3D"m_7490866102373541101styled-by-prettify"></s=
pan><div style=3D"background-color:rgb(250,250,250);border-color:rgb(187,18=
7,187);border-style:solid;border-width:1px" class=3D"m_7490866102373541101p=
rettyprint"><code class=3D"m_7490866102373541101prettyprint"><div class=3D"=
m_7490866102373541101subprettyprint"><span style=3D"color:#000" class=3D"m_=
7490866102373541101styled-by-prettify">method created</span><span style=3D"=
color:#660" class=3D"m_7490866102373541101styled-by-prettify">:</span><span=
 style=3D"color:#000" class=3D"m_7490866102373541101styled-by-prettify"> fo=
o</span><span style=3D"color:#660" class=3D"m_7490866102373541101styled-by-=
prettify">(</span><span style=3D"color:#008" class=3D"m_7490866102373541101=
styled-by-prettify">in</span><span style=3D"color:#660" class=3D"m_74908661=
02373541101styled-by-prettify">:</span><span style=3D"color:#000" class=3D"=
m_7490866102373541101styled-by-prettify"> </span><span style=3D"color:#606"=
 class=3D"m_7490866102373541101styled-by-prettify">String</span><span style=
=3D"color:#660" class=3D"m_7490866102373541101styled-by-prettify">):</span>=
<span style=3D"color:#000" class=3D"m_7490866102373541101styled-by-prettify=
"> </span><span style=3D"color:#606" class=3D"m_7490866102373541101styled-b=
y-prettify">Int</span><span style=3D"color:#000" class=3D"m_749086610237354=
1101styled-by-prettify"> <br></span></div></code></div><code class=3D"m_749=
0866102373541101prettyprint"></code><br><code class=3D"m_749086610237354110=
1prettyprint"><div class=3D"m_7490866102373541101subprettyprint"><span styl=
e=3D"color:#000" class=3D"m_7490866102373541101styled-by-prettify"></span><=
/div></code>Would someone support/guide me in fixing this?<br><br>Cheers,<b=
r>Raphael<span class=3D"HOEnZb"><font color=3D"#888888"><br><br><br><br></f=
ont></span></div><span class=3D"HOEnZb"><font color=3D"#888888">

<p></p>

-- <br>
You received this message because you are subscribed to the Google Groups &=
quot;scala-language&quot; group.<br>
To unsubscribe from this group and stop receiving emails from it, send an e=
mail to <a href=3D"mailto:[email protected]" targ=
et=3D"_blank">scala-language+unsubscribe@<wbr>googlegroups.com</a>.<br>
For more options, visit <a href=3D"https://groups.google.com/d/optout" targ=
et=3D"_blank">https://groups.google.com/d/<wbr>optout</a>.<br>
</font></span></blockquote></div><br><br clear=3D"all"><br>-- <br><div clas=
s=3D"gmail_signature" data-smartmail=3D"gmail_signature"><div dir=3D"ltr"><=
div><div dir=3D"ltr"><div><div dir=3D"ltr"><div><div dir=3D"ltr"><div>Olive=
r Ruebenacker<br></div><div>Senior Software Engineer, <a href=3D"http://www=
.type2diabetesgenetics.org/" target=3D"_blank">Diabetes Portal</a>, <a href=
=3D"http://www.broadinstitute.org/" target=3D"_blank">Broad Institute</a><b=
r></div><br></div></div></div></div></div></div></div></div>
</div>

<p></p>

-- <br />
You received this message because you are subscribed to the Google Groups &=
quot;scala-language&quot; group.<br />
To unsubscribe from this group and stop receiving emails from it, send an e=
mail to <a href=3D"mailto:[email protected]">scal=
[email protected]</a>.<br />
For more options, visit <a href=3D"https://groups.google.com/d/optout">http=
s://groups.google.com/d/optout</a>.<br />

--001a113f49e4527dc205402f6c9b--