Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

「Javaとの相互運用」の練習問題の解答例を追加 #91

Merged
merged 1 commit into from
Apr 25, 2016
Merged

「Javaとの相互運用」の練習問題の解答例を追加 #91

merged 1 commit into from
Apr 25, 2016

Conversation

kmizu
Copy link
Contributor

@kmizu kmizu commented Apr 25, 2016

No description provided.

System.exit(0)
```

実行中のScalaプログラム(プロセス)が終了する。
Copy link
Contributor

@xuwei-k xuwei-k Apr 25, 2016

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

sbtのconsoleだと以下のようになって死なない、みたいな罠(?)あるけど、まぁ説明面倒だしひとまず書かなくてもいいか・・・

Welcome to Scala version 2.10.5 (Java HotSpot(TM) 64-Bit Server VM, Java 1.8.0_77).
Type in expressions to have them evaluated.
Type :help for more information.

scala> System.exit(0)

Exception: sbt.TrapExitSecurityException thrown from the UncaughtExceptionHandler in thread "run-main-0"

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

sbt consleでSystem.exit()試したことなかったので、それに対するガードがかかっているとは知らなかった…。

@kmizu kmizu merged commit 71de048 into scala-text:master Apr 25, 2016
@kmizu kmizu deleted the add-answers branch April 25, 2016 08:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants