perfetto 0.1.2 → 0.1.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/example/example.rb +2 -0
- data/lib/perfetto/interceptor.rb +2 -1
- data/lib/perfetto/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 477238494f1ee984318147d893a338e51581ef6213cc8ff59463459a45db90c8
|
4
|
+
data.tar.gz: 80c30864e15aa47b948c5090fbe7e635e0479e58762a177150343f70f2e69509
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 6bd5ea8ddececb799f9d0dc2af6c74197e423f38993de563d6c413ea192d31b799a9f9e7e0c46643f2c65e1915ee5c0c12560cfc4872d226b453ddb23e38def0
|
7
|
+
data.tar.gz: 93136f43996f10bd68ccb472a0dcef3c42196f96dfa789a4ec3a2140ef554c3c917b56ac76d1c5f95c1487104549105cb68c724a2afca6958610c702aee85e19
|
data/example/example.rb
CHANGED
@@ -1,6 +1,7 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
|
3
3
|
# rubocop:disable Naming/MethodParameterName
|
4
|
+
# rubocop:disable Style/Documentation
|
4
5
|
|
5
6
|
require "perfetto"
|
6
7
|
|
@@ -62,3 +63,4 @@ end
|
|
62
63
|
Perfetto.stop_tracing "example.pftrace"
|
63
64
|
|
64
65
|
# rubocop:enable Naming/MethodParameterName
|
66
|
+
# rubocop:enable Style/Documentation
|
data/lib/perfetto/interceptor.rb
CHANGED
@@ -15,8 +15,9 @@ module Perfetto
|
|
15
15
|
alias_method "pftrace_#{method_name}", method_name
|
16
16
|
define_method(method_name) do |*args, **kwargs, &block|
|
17
17
|
Perfetto.trace_event_begin self.class.name, method_name.to_s
|
18
|
-
original_method.bind(self).call(*args, **kwargs, &block)
|
18
|
+
ret = original_method.bind(self).call(*args, **kwargs, &block)
|
19
19
|
Perfetto.trace_event_end self.class.name
|
20
|
+
ret
|
20
21
|
end
|
21
22
|
end
|
22
23
|
|
data/lib/perfetto/version.rb
CHANGED