summaryrefslogtreecommitdiff
path: root/sources
diff options
context:
space:
mode:
authorpaltherr <paltherr@epfl.ch>2003-05-15 14:42:31 +0000
committerpaltherr <paltherr@epfl.ch>2003-05-15 14:42:31 +0000
commitbdc7125ab59e71ace676a2e2304783ea1b04edee (patch)
tree374cf49806db8723a30d1b6cc2ee34938724934e /sources
parent4686a2d6f69da3925e84a2f10410d3bab607d0b1 (diff)
downloadscala-bdc7125ab59e71ace676a2e2304783ea1b04edee.tar.gz
scala-bdc7125ab59e71ace676a2e2304783ea1b04edee.tar.bz2
scala-bdc7125ab59e71ace676a2e2304783ea1b04edee.zip
- Added some tests to avoid printing if there i...
- Added some tests to avoid printing if there is no printer
Diffstat (limited to 'sources')
-rw-r--r--sources/scala/runtime/InterpreterSupport.java6
1 files changed, 4 insertions, 2 deletions
diff --git a/sources/scala/runtime/InterpreterSupport.java b/sources/scala/runtime/InterpreterSupport.java
index 9388ec3814..9272583ca1 100644
--- a/sources/scala/runtime/InterpreterSupport.java
+++ b/sources/scala/runtime/InterpreterSupport.java
@@ -69,7 +69,8 @@ public class InterpreterSupport {
* @meta method (java.lang.String, scala.Any) scala.Unit;
*/
public static void showDefinition(String signature) {
- getDefinitionPrinter().showDefinition(signature);
+ DefinitionPrinter printer = getDefinitionPrinter();
+ if (printer != null) printer.showDefinition(signature);
}
/**
@@ -79,7 +80,8 @@ public class InterpreterSupport {
* @meta method (java.lang.String, scala.Any) scala.Unit;
*/
public static void showValueDefinition(String signature, Object value) {
- getDefinitionPrinter().showValueDefinition(signature, value);
+ DefinitionPrinter printer = getDefinitionPrinter();
+ if (printer != null) printer.showValueDefinition(signature, value);
}
/**