summaryrefslogtreecommitdiff
path: root/object.c
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2012-11-16 17:02:39 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2012-11-16 17:02:39 +0000
commit7bd638b7a4062d774da7c96d3e926733b6a103ad (patch)
treeeb6ae831d53fa500bbaa87ee759bad7c3c990c4d /object.c
parented86cd0536fd1e77a17d69bf30fe5ef531e182ca (diff)
object.c: suppress warning
* object.c (rb_obj_alloc): suppress unused variable warning. * tool/gen_dummy_probes.rb: define dtrace disabling macro. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@37691 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'object.c')
-rw-r--r--object.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/object.c b/object.c
index 0b7c1bc441..f515d48ac6 100644
--- a/object.c
+++ b/object.c
@@ -1686,12 +1686,14 @@ rb_obj_alloc(VALUE klass)
klass);
}
+#if !defined(DTRACE_PROBES_DISABLED) || !DTRACE_PROBES_DISABLED
if (RUBY_DTRACE_OBJECT_CREATE_ENABLED()) {
const char * file = rb_sourcefile();
RUBY_DTRACE_OBJECT_CREATE(rb_class2name(klass),
file ? file : "",
rb_sourceline());
}
+#endif
obj = (*allocator)(klass);