summaryrefslogtreecommitdiff
path: root/ext/dl/sample/getch.rb
diff options
context:
space:
mode:
authorttate <ttate@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2002-04-02 10:56:13 +0000
committerttate <ttate@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2002-04-02 10:56:13 +0000
commit7d711b817e62eb6c8dee01ea2283fcb1ad90f8ac (patch)
treeb1b54ab76217775071de4e3669674aa7887aa6b9 /ext/dl/sample/getch.rb
parent64b6406445e53f187d2982f87becff8065edd0cc (diff)
Add ruby-dl
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2324 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext/dl/sample/getch.rb')
-rw-r--r--ext/dl/sample/getch.rb5
1 files changed, 5 insertions, 0 deletions
diff --git a/ext/dl/sample/getch.rb b/ext/dl/sample/getch.rb
new file mode 100644
index 0000000000..3f7261c979
--- /dev/null
+++ b/ext/dl/sample/getch.rb
@@ -0,0 +1,5 @@
+require 'dl'
+
+crtdll = DL::dlopen("crtdll")
+getch = crtdll['_getch', 'L']
+print(getch.call, "\n")