Search found 409 matches
- 25 Apr 2024, 08:28
- Forum: Bug Reports
- Topic: Closure memory leak
- Replies: 0
- Views: 147
Closure memory leak
Closure.Prototype.__Delete := this => OutputDebug('closure dctor: ' ObjPtr(this) '`n') ff() { a := 0 b := f2 OutputDebug('f1: ' ObjPtr(f1) '`n') OutputDebug('f2: ' ObjPtr(f2) '`n') f1() ; b := 0 ; Free variables was not released during closure destruction. f1() { b() } f2() { a := 1 } } ff()
- 20 Apr 2024, 00:50
- Forum: Ask for Help (v2)
- Topic: JSON.ahk error
- Replies: 2
- Views: 124
Re: JSON.ahk error
I fixed it yesterday.
- 31 Mar 2024, 07:24
- Forum: AutoHotkey_H
- Topic: RegRead? Seems to not work the same as _L
- Replies: 5
- Views: 254
Re: RegRead? Seems to not work the same as _L
The downloaded zip package contains both 32 and 64 bits, doesn't yours?
- 31 Mar 2024, 00:03
- Forum: AutoHotkey_H
- Topic: RegRead? Seems to not work the same as _L
- Replies: 5
- Views: 254
Re: RegRead? Seems to not work the same as _L
The registry has different views in 64-bit and 32-bit, and if you run this code with AHk_l 32-bit, you'll get the same error.
- 30 Mar 2024, 20:41
- Forum: Ask for Help
- Topic: can't compile with ahk2exe_h but works fine with normal
- Replies: 17
- Views: 347
Re: can't compile with ahk2exe_h but works fine with normal
@TAC109
In my tests, ScriptGuard2 also works for ahk_h.
In my tests, ScriptGuard2 also works for ahk_h.
- 30 Mar 2024, 01:20
- Forum: AutoHotkey_H
- Topic: RegRead? Seems to not work the same as _L
- Replies: 5
- Views: 254
Re: RegRead? Seems to not work the same as _L
No, it is same as ahk_l.
- 29 Mar 2024, 06:47
- Forum: Ask for Help
- Topic: can't compile with ahk2exe_h but works fine with normal
- Replies: 17
- Views: 347
Re: can't compile with ahk2exe_h but works fine with normal
There are only a handful of conflicts, and I don't think a lot of code needs to be rewritten.
- 29 Mar 2024, 06:32
- Forum: Ask for Help
- Topic: can't compile with ahk2exe_h but works fine with normal
- Replies: 17
- Views: 347
Re: can't compile with ahk2exe_h but works fine with normal
ahk_h has additional classes and class methods, and in this respect conflicts with some ahk_l scripts, which is unavoidable.
- 29 Mar 2024, 06:10
- Forum: Ask for Help
- Topic: can't compile with ahk2exe_h but works fine with normal
- Replies: 17
- Views: 347
Re: can't compile with ahk2exe_h but works fine with normal
Why compile with ahk_h when you have been using ahk_l all along?
- 29 Mar 2024, 04:48
- Forum: Ask for Help
- Topic: can't compile with ahk2exe_h but works fine with normal
- Replies: 17
- Views: 347
Re: can't compile with ahk2exe_h but works fine with normal
The library you are trying to include conflicts with the built-in JSON class in ahk_h. If there are no special requirements, the JSON library can be removed.
- 28 Mar 2024, 21:33
- Forum: Ask for Help
- Topic: can't compile with ahk2exe_h but works fine with normal
- Replies: 17
- Views: 347
Re: can't compile with ahk2exe_h but works fine with normal
You may need to update ahk2exe.
download/file.php?id=25410
download/file.php?id=25410
- 28 Mar 2024, 09:03
- Forum: AutoHotkey Development
- Topic: Typed properties - experimental build available
- Replies: 68
- Views: 11567
Re: Typed properties - experimental build available
You can just add an __Item property to the prototype of the class you pass to StructFromPtr (explicitly or via class definition). For now, you also have the option of adding properties to the object returned by StructFromPtr. Yes, it can be done that way. The first option is more convenient to use,...
- 27 Mar 2024, 09:39
- Forum: AutoHotkey Development
- Topic: Typed properties - experimental build available
- Replies: 68
- Views: 11567
Re: Typed properties - experimental build available
Code: Select all
fn() {
static RECT := () {
obj := Class(Object)
for k in ['x', 'y', 'w', 'h']
obj.Prototype.DefineProp(k, { type: 'i32' })
return obj
}()
DllCall(..., RECT, ...)
}
- 27 Mar 2024, 06:29
- Forum: AutoHotkey Development
- Topic: Typed properties - experimental build available
- Replies: 68
- Views: 11567
Re: Typed properties - experimental build available
If __value returns 0 for a null pointer, there will be ambiguity when the type is int*.
The current solution also makes it impossible for pointer types to be used as arrays, like p[0], p[1].
The current solution also makes it impossible for pointer types to be used as arrays, like p[0], p[1].
- 26 Mar 2024, 06:18
- Forum: AutoHotkey Development
- Topic: Typed properties - experimental build available
- Replies: 68
- Views: 11567
Re: Typed properties - experimental build available
Should the __value.get of the pointer class be removed, so that null pointers can be retrieved?
- 20 Mar 2024, 05:36
- Forum: Visual Studio Code
- Topic: Why does it show this syntax as an error?
- Replies: 2
- Views: 115
Re: Why does it show this syntax as an error?
Fixed in the next version.
- 20 Mar 2024, 05:03
- Forum: Ask for Help (v2)
- Topic: [Q] Enumerator - Why is cloned class different from original? Topic is solved
- Replies: 4
- Views: 165
Re: [Q] Enumerator - Why is cloned class is different from original? Topic is solved
This should be a bug that clones non-value properties.
https://www.autohotkey.com/docs/v2/lib/Object.htm#OwnProps wrote: If two variables were specified, the enumerator attempts to call the property's getter to retrieve the value.
If the getter requires parameters, the property is skipped.
If Obj itself does not define a getter for this property, it is skipped.
- 15 Mar 2024, 22:44
- Forum: Bug Reports
- Topic: V2: \ is shown as ¥ in some situation perhaps due to font problem
- Replies: 10
- Views: 958
Re: V2: \ is shown as ¥ in some situation perhaps due to font problem
On my computer, ¥ can be used as the NTFS file name. Is it backslash \ that appears as ¥ in a specific font?lexikos wrote: So ¥ can't appear in an NTFS filename, and must only be a path separator (or invalid).
- 14 Mar 2024, 20:01
- Forum: AutoHotkey Development
- Topic: Typed properties - experimental build available
- Replies: 68
- Views: 11567
Re: Typed properties - experimental build available
Code: Select all
MsgBox(ObjGetDataPtr(obj := Object())) ; Nonzero value
Is it necessary for a class to allocate memory when it has no typed properties?
- 11 Mar 2024, 11:32
- Forum: Visual Studio Code
- Topic: Debugging in VSCode
- Replies: 9
- Views: 455
Re: Debugging in VSCode
Using OutputDebug in debugging.
Output to stdout FileAppend(str '`n', '*') at any time.
Output to stdout FileAppend(str '`n', '*') at any time.