0
0
mirror of https://github.com/PostHog/posthog.git synced 2024-11-28 00:46:45 +01:00
posthog/hogvm/__tests__/functionVars.hog

40 lines
708 B
Plaintext
Raw Normal View History

2024-08-30 11:51:36 +02:00
fun execFunction() {
print('execFunction')
}
2024-08-30 11:51:36 +02:00
fun execFunctionNested() {
fun execFunction() {
print('execFunctionNew')
}
print('execFunctionNested')
execFunction()
}
execFunction()
execFunctionNested()
execFunction()
print('--------')
2024-08-30 11:51:36 +02:00
fun secondExecFunction() {
print('secondExecFunction')
}
2024-08-30 11:51:36 +02:00
fun secondExecFunctionNested() {
print('secondExecFunctionNested')
secondExecFunction()
}
secondExecFunction()
secondExecFunctionNested()
secondExecFunction()
print('--------')
let decode := () -> base64Decode
let sixtyFour := base64Encode
print(sixtyFour('http://www.google.com'))
print((decode())(sixtyFour('http://www.google.com')))
print(decode()(sixtyFour('http://www.google.com')))