Giter VIP home page Giter VIP logo

Comments (2)

cpyrgas avatar cpyrgas commented on August 22, 2024

Original sample, compile with /lb /memvar /vo7

FUNCTION Start() AS VOID STRICT
PRIVATE oa
PRIVATE ca
PRIVATE cb
PRIVATE cc

LOCAL cCmd	AS STRING

TRY

	oa := a{}

	? "Direct call 2 parameters:"	
	ca	:= ""
	cb	:= NULL_DATE
	oa:CallByRef2(@ca,@cb,@cc)
	? ca
	? cb
	?

	? "Direct call 3 parameters:"	
	ca	:= ""
	cb	:= NULL_DATE
	cc	:= NULL_DATE
	oa:CallByRef3(@ca,@cb,@cc)
	? ca
	? cb
	? cc
	?

	? "Indirect call 2 parameters:"	
	ca	:= ""
	cb	:= NULL_DATE
	cCmd := "oa:CallByRef2(@ca,@cb)"
	Eval(&("{||"+cCmd+"}"))
	? ca
	? cb
	?
	
	? "Indirect call 3 parameters, third by value:"	
	ca	:= ""
	cb	:= NULL_DATE
	cc	:= NULL_DATE
	cCmd := "oa:CallByRef3a(@ca,@cb,cc)"
	Eval(&("{||"+cCmd+"}"))
	? ca
	? cb
	? cc
	?
	
	? "Indirect call 3 parameters, third by ref:"	
	ca	:= ""
	cb	:= NULL_DATE
	cc	:= NULL_DATE
	cCmd := "oa:CallByRef3(@ca,@cb,@cc)"
	Eval(&("{||"+cCmd+"}"))
	? ca
	? cb
	? cc
	?
	
CATCH e AS exception
	? e:Message
END TRY

WAIT

RETURN

CLASS a

METHOD CallByRef2(a REF STRING,b REF DATE) AS LOGIC
LOCAL lOk	AS LOGIC

a := "OK"
b	:= Today()
lOk := TRUE

RETURN lOk

METHOD CallByRef3(a REF STRING,b REF DATE,c REF DATE) AS LOGIC
LOCAL lOk	AS LOGIC

a := "OK"
b	:= Today()
c := Today()+1
lOk := TRUE

RETURN lOk

METHOD CallByRef3a(a REF STRING,b REF DATE,c AS DATE) AS LOGIC
LOCAL lOk	AS LOGIC

a := "OK"
b	:= Today()
c := Today()+1
lOk := TRUE

RETURN lOk

END CLASS

from xsharppublic.

cpyrgas avatar cpyrgas commented on August 22, 2024

Confirmed fixed

from xsharppublic.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.