It is currently Sun Jul 21, 2019 8:18 pm

All times are UTC + 1 hour




Post new topic Reply to topic  [ 54 posts ]  Go to page Previous  1, 2, 3, 4
Author Message
 Post subject:
PostPosted: Sat Sep 27, 2008 6:21 pm 
Offline
Enthusiast
Enthusiast
User avatar

Joined: Mon Sep 17, 2007 10:28 am
Posts: 141
Location: P.O.P
Welcome back! :D

_________________
POiNT.OF.PRESENCE group


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Thu Oct 09, 2008 7:19 pm 
Offline
Addict
Addict
User avatar

Joined: Fri May 12, 2006 6:51 pm
Posts: 1769
Location: Germany
Thanks :wink:

many to do in my job.


Have anyone tested my precompiler under X64 compiler? It´s ok?

GT 8)

_________________
My Projects ThreadToGUI / OOP-BaseClass / OOP-BaseClassDispatch / Event-Designer
PB v3.30 / v5.70 - OS Mac Mini OSX 10.xx - VM Window Pro / Linux Ubuntu
Downloads on my Webspace


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Wed Dec 24, 2008 6:15 pm 
Offline
Addict
Addict
User avatar

Joined: Fri May 12, 2006 6:51 pm
Posts: 1769
Location: Germany
Update v0.42

Now two precompiler for X86 and X64
Precompiler X64 for 32 and 64 Bit for PB version 4.30

I can´t testing X64 mode!

GT :wink:

_________________
My Projects ThreadToGUI / OOP-BaseClass / OOP-BaseClassDispatch / Event-Designer
PB v3.30 / v5.70 - OS Mac Mini OSX 10.xx - VM Window Pro / Linux Ubuntu
Downloads on my Webspace


Last edited by mk-soft on Sun Jun 21, 2009 9:11 pm, edited 1 time in total.

Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Thu Dec 25, 2008 3:43 pm 
Offline
Addict
Addict
User avatar

Joined: Fri May 12, 2006 6:51 pm
Posts: 1769
Location: Germany
Update v0.43

NEW
- Method DestroyObject

Example
Code:
; Example - avoidance of memory leak with method InitObject and DestroyObject

Class(MemClass)
  *mem1
  *mem2
EndClass

; Init memory
Method MemClass_InitObject(*this.MemClass) ; <- NewObject calling InitObject
  With *this
    Debug "InitObject: AllocateMemory."
    \mem1 = AllocateMemory(10*1024)
    \mem2 = AllocateMemory(20*1024)
  EndWith
EndMethod

Method MemClass_GetMemPointer(*this.MemClass, number.l)
  Select number
    Case 1 : ProcedureReturn *this\mem1
    Case 2 : ProcedureReturn *this\mem2
    Default : ProcedureReturn 0
  EndSelect
EndMethod

Method MemClass_DestroyObject(*this.MemClass) ; <- DeleteObject or Release calling DestroyObject
 
  Debug "DestroyObject: Free Memory."
  FreeMemory(*this\mem1)
  FreeMemory(*this\mem2)
 
EndMethod

; Test Part 3
Debug "Test Part 3"
Debug ""
Debug "Mem Test 1"
*mem.IMemClass = NewObject(MemClass)
Debug "Address of Obj : " + Str(*mem)
Debug "Address of mem1: " + Str(*mem\GetMemPointer(1))
Debug "Address of mem2: " + Str(*mem\GetMemPointer(2))
*mem\Release()
Debug ""

Debug "Mem Test 2"
*mem.IMemClass = NewObject(MemClass)
Debug "Address of Obj : " + Str(*mem)
Debug "Address of mem1: " + Str(*mem\GetMemPointer(1))
Debug "Address of mem2: " + Str(*mem\GetMemPointer(2))
DeleteObject(*mem)
Debug ""

Debug "Mem Test 3"
*mem.IMemClass = NewObject(MemClass)
Debug "Address of Obj : " + Str(*mem)
Debug "Address of mem1: " + Str(*mem\GetMemPointer(1))
Debug "Address of mem2: " + Str(*mem\GetMemPointer(2))
*mem\Release()
Debug ""


GT :wink:

_________________
My Projects ThreadToGUI / OOP-BaseClass / OOP-BaseClassDispatch / Event-Designer
PB v3.30 / v5.70 - OS Mac Mini OSX 10.xx - VM Window Pro / Linux Ubuntu
Downloads on my Webspace


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Fri Dec 26, 2008 7:37 am 
Offline
User
User

Joined: Thu Jul 17, 2008 1:44 pm
Posts: 21
Location: germany
hi,
i see this for the first time. it nead. is there any chance that the methods be in the class? ex.:

Code:
Class(MemClass)
  *mem1
  *mem2
; Init memory

Method InitObject() ; <- NewObject calling InitObject
  With *this
    Debug "InitObject: AllocateMemory."
    \mem1 = AllocateMemory(10*1024)
    \mem2 = AllocateMemory(20*1024)
  EndWith
EndMethod
EndClass


would give the added effect to be able to drop the "MemClass_" and the "*this.MemClass".javascript:emoticon(':P')
it would not be needed then

it would be neat to have class methods with the same name, but a different signature:

Code:
Method xxx(somevar.s) ; <- NewObject calling

Code:
Method xxx(somevar.i) ; <- NewObject calling


it would be neat to have get some syntactic sugar for getters and setter like in c# or other languages.

maybe some of it is possible - it would make thinks easier to read and to maintain. thanks for nice tool

rko


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Sat Dec 27, 2008 4:54 am 
Offline
Addict
Addict
User avatar

Joined: Fri May 12, 2006 6:51 pm
Posts: 1769
Location: Germany
Update v0.43 ref 14240

-Bugfix DestroyObject

GT

P.S.

The methods within Class to programming for to a substantial larger expenditure in the case of the translation Main and all Inc. charge files. Thus even to larger sources of error. With the structure which I need I did not select the Scourecode to change and all necessities can with macros and as soon as additional Inc. charge files, which are merged clean, to cover. Thus the error tracing functions with PB as used.

_________________
My Projects ThreadToGUI / OOP-BaseClass / OOP-BaseClassDispatch / Event-Designer
PB v3.30 / v5.70 - OS Mac Mini OSX 10.xx - VM Window Pro / Linux Ubuntu
Downloads on my Webspace


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Sun Jun 21, 2009 5:32 pm 
Offline
Addict
Addict
User avatar

Joined: Fri May 12, 2006 6:51 pm
Posts: 1769
Location: Germany
Update v0.44

New:
Method Class_InitObject(...) now with parameters.
When InitObject() without parameters can calling NewObject(ClassName) for compatible old projects, but using parameters calling NewClassName(para1, etc)
sorry for my english
example
Code:

; Example Part 3 - avoidance of memory leak with method InitObject and DestroyObject

Class(MemClass)
  *mem1
  *mem2
EndClass

; Init memory
Method MemClass_InitObject(*this.MemClass, size.i) ; <- NewMemClass calling InitObject
  With *this
    Debug "InitObject: AllocateMemory."
    \mem1 = AllocateMemory(size*1024)
    \mem2 = AllocateMemory(size*1024)
  EndWith
EndMethod

Method MemClass_GetMemPointer(*this.MemClass, number.l)
  Select number
    Case 1 : ProcedureReturn *this\mem1
    Case 2 : ProcedureReturn *this\mem2
    Default : ProcedureReturn 0
  EndSelect
EndMethod

Method MemClass_DestroyObject(*this.MemClass) ; <- DeleteObject or Release calling DestroyObject
 
  Debug "DestroyObject: Free Memory."
  FreeMemory(*this\mem1)
  FreeMemory(*this\mem2)
 
EndMethod

; Test Part 3
Debug "Test Part 3"
Debug ""
Debug "Mem Test 1"
*mem.IMemClass = NewMemClass(10)
Debug "Address of Obj : " + Str(*mem)
Debug "Address of mem1: " + Str(*mem\GetMemPointer(1))
Debug "Address of mem2: " + Str(*mem\GetMemPointer(2))
DeleteObject(*mem)
;*mem\Release()
Debug ""

Debug "Mem Test 2"
*mem.IMemClass = NewMemClass(10)
Debug "Address of Obj : " + Str(*mem)
Debug "Address of mem1: " + Str(*mem\GetMemPointer(1))
Debug "Address of mem2: " + Str(*mem\GetMemPointer(2))
DeleteObject(*mem)
;*mem\Release()
Debug ""

Debug "Mem Test 3"
*mem.IMemClass = NewMemClass(10)
Debug "Address of Obj : " + Str(*mem)
Debug "Address of mem1: " + Str(*mem\GetMemPointer(1))
Debug "Address of mem2: " + Str(*mem\GetMemPointer(2))
DeleteObject(*mem)
;*mem\Release()
Debug ""

Debug "Mem Test 4"
*mem.IMemClass = NewMemClass(10)
Debug "Address of Obj : " + Str(*mem)
Debug "Address of mem1: " + Str(*mem\GetMemPointer(1))
Debug "Address of mem2: " + Str(*mem\GetMemPointer(2))
DeleteObject(*mem)
;*mem\Release()
Debug ""


GT :wink:

_________________
My Projects ThreadToGUI / OOP-BaseClass / OOP-BaseClassDispatch / Event-Designer
PB v3.30 / v5.70 - OS Mac Mini OSX 10.xx - VM Window Pro / Linux Ubuntu
Downloads on my Webspace


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Wed Jun 24, 2009 11:14 pm 
Offline
Addict
Addict
User avatar

Joined: Fri May 12, 2006 6:51 pm
Posts: 1769
Location: Germany
Update v0.45

Bugfix:
- Memory manager

Sorry... Big Bug at version 0.44

_________________
My Projects ThreadToGUI / OOP-BaseClass / OOP-BaseClassDispatch / Event-Designer
PB v3.30 / v5.70 - OS Mac Mini OSX 10.xx - VM Window Pro / Linux Ubuntu
Downloads on my Webspace


Top
 Profile  
Reply with quote  
 Post subject: Re: Another OOP PreCompiler
PostPosted: Mon Sep 14, 2009 12:40 am 
Offline
User
User

Joined: Sun Apr 02, 2006 7:41 am
Posts: 31
WOW!!!! THANK YOU!!!!


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 54 posts ]  Go to page Previous  1, 2, 3, 4

All times are UTC + 1 hour


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  

 


Powered by phpBB © 2008 phpBB Group
subSilver+ theme by Canver Software, sponsor Sanal Modifiye