Re: I need helping understanding a pointer example

2019-12-30 Thread Veesh Goldman
Method declares a method as opposed to a function. The difference is that in a method, the first argument passed to the function is bound to `self`, which represents the object the call was made on. In traditional perl style, when you call a method on an object `your.face('scrambled eggs')`, it ac

Re: My Native Call notes

2019-12-30 Thread Todd Chester via perl6-users
On 2019-12-29 17:05, ToddAndMargo via perl6-users wrote: Native Call is tack the chr(0) at the end for you, most of the time Mistake on my part. No it won't. You have to add it yourself.

I need helping understanding a pointer example

2019-12-30 Thread Todd Chester via perl6-users
Hi All, Over at https://docs.raku.org/language/nativecall.html#Basic_use_of_pointers There is an example: useNativeCall; classFooHandleisrepr('CPointer') { # Here are the actual NativeCall functions. subFoo_init() returnsFooHandleisnative("foo") {*} subFoo_free(FooHandle) isnati

NativeCall Doc booboo

2019-12-30 Thread Todd Chester via perl6-users
Hi All, https://docs.raku.org/language/nativecall.html#Passing_and_returning_values Did anyone else discover the mistake, hopefully not the hard way like I did.  Anyone get weird gibberish printed out like I did? my$string="FOO"; # The lifetime of this variable must be equal to the requir

What is aLPCVOID, LPTSTR and a va_list *Arguments?

2019-12-30 Thread ToddAndMargo via perl6-users
Hi All, In the following C code DWORD FormatMessageW( DWORD dwFlags, LPCVOID lpSource, DWORD dwMessageId, DWORD dwLanguageId, LPTSTR lpBuffer, DWORD nSize, va_list *Arguments What do I tell Native Call the follow are? L