Skip to content

Commit df21b83

Browse files
committed
README: Use PyCall.import_module instead of PyCall::Import
1 parent b5f4275 commit df21b83

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

README.md

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -53,9 +53,8 @@ Or install it yourself as:
5353
Here is a simple example to call Python's `math.sin` function and compare it to
5454
the `Math.sin` in Ruby:
5555

56-
require 'pycall/import'
57-
include PyCall::Import
58-
pyimport :math
56+
require 'pycall'
57+
math = PyCall.import_module("math")
5958
math.sin(math.pi / 4) - Math.sin(Math::PI / 4) # => 0.0
6059

6160
Type conversions from Ruby to Python are automatically performed for numeric,

0 commit comments

Comments
 (0)