Register | Login
Forum Index > Requests and Feedback > Procedure type in procedure parameters
Author Message
Pages: 1 2
0CodErr
Ziron Guru
(send private message)

Posts: 199
Topics: 37

Location:
[1543] Procedure type in procedure parameters - posted: 2015-01-29 17:50:42
We can do able to write like this:
Code:
procedure Proc1(procedure* SomeProc; function* SomeFunc){
  SomeProc();
  eax = SomeFunc();
}

procedure Proc2(){}
function Func1(){return true;}

Proc1(Proc2, Func1);

Maybe need define parameters like Code:
procedure* SomeProc(dword p1, p2)

Also should pay attention on different calling conventions.
It would be useable i think smile
Admin
Site Admin

avatar

(send private message)

Posts: 933
Topics: 55

Location:
OverHertz Studio
[1558] - posted: 2015-01-30 22:59:56
This is a good idea, I will add it to my list, but with lower priority for now until other items on my list are completed.

Download Ziron
Get free hosting for Ziron related fan-sites and Ziron projects, contact me in private message.
0CodErr
Ziron Guru
(send private message)

Posts: 199
Topics: 37

Location:
[1723] - posted: 2015-02-18 11:03:40
It a bit relevant to this topic:
Code:
program RAW_IMAGE 'test';

#set bits 32;

procedure TestA(pointer P) {
  procedure* MyProc(dword x, y, z); MyProc = P;
  MyProc(1, 2, 3);
}
procedure TestB(pointer P) {
  procedure* MyProc(dword x, y, z); MyProc = P;
  MyProc(1, 2, 3);
}
TestA(0); TestB(0);

Instruction usage is not supported!
Admin
Site Admin

avatar

(send private message)

Posts: 933
Topics: 55

Location:
OverHertz Studio
[1740] - posted: 2015-02-19 21:56:57
I have fixed this for next release, however, I will try to get around to declaring methods for local vars as soon as possible. (maybe using AS will be a good idea for now)

Download Ziron
Get free hosting for Ziron related fan-sites and Ziron projects, contact me in private message.
0CodErr
Ziron Guru
(send private message)

Posts: 199
Topics: 37

Location:
[1751] - posted: 2015-02-22 11:08:46
Code:
procedure TestA(pointer P) {
  procedure* MyProc(dword x, y, z); MyProc = P;
  MyProc(1, 2, 3);
}

Unexpected symbol ;
0CodErr
Ziron Guru
(send private message)

Posts: 199
Topics: 37

Location:
[1752] - posted: 2015-02-22 11:10:23
... if we change in code above 'procedure*' with 'function*'
0CodErr
Ziron Guru
(send private message)

Posts: 199
Topics: 37

Location:
[1753] - posted: 2015-02-22 11:16:21
Cannot compile even if we write Code:
[@MyProc] = P
Admin
Site Admin

avatar

(send private message)

Posts: 933
Topics: 55

Location:
OverHertz Studio
[1766] - posted: 2015-02-23 12:34:54
Unexpected symbol ;


Functions must have a return type declared.

Code:
  function* MyProc(dword x, y, z): DWord; MyProc = P;


Download Ziron
Get free hosting for Ziron related fan-sites and Ziron projects, contact me in private message.
Pages: 1 2
create new reply


Quick reply:

Message:



Currently Active Users:
There are currently 10 user(s) online. 0 member(s) and 10 guest(s)
Most users ever online was 1046, January 28, 2022, 2:08 pm.


Statistics:
Threads: 225 | Posts: 1848 | Members: 51 | Active Members: 51
Welcome to our newest member, yecate
const Copyright = '2011-2024 © OverHertz Ltd. All rights reserved.';
Web development by OverHertz Ltd