The following warnings occurred:
Warning [2] Use of undefined constant SAPI_NAME - assumed 'SAPI_NAME' (this will throw an Error in a future version of PHP) - Line: 3388 - File: inc/functions.php PHP 7.4.33-nmm7 (Linux)
File Line Function
/inc/functions.php 3388 errorHandler->error
/showthread.php 116 build_archive_link
Warning [2] Use of undefined constant IN_ARCHIVE - assumed 'IN_ARCHIVE' (this will throw an Error in a future version of PHP) - Line: 3331 - File: inc/functions.php PHP 7.4.33-nmm7 (Linux)
File Line Function
/inc/functions.php 3331 errorHandler->error
/inc/functions.php 3324 build_forum_breadcrumb
/showthread.php 195 build_forum_breadcrumb
Warning [2] Use of undefined constant IN_ARCHIVE - assumed 'IN_ARCHIVE' (this will throw an Error in a future version of PHP) - Line: 3331 - File: inc/functions.php PHP 7.4.33-nmm7 (Linux)
File Line Function
/inc/functions.php 3331 errorHandler->error
/showthread.php 195 build_forum_breadcrumb






Post Reply 
 
Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
problems with <call functionname>
Author Message
wuffel
Apprentice
*

Posts: 28
Likes Given: 0
Likes Received: 4 in 2 posts
Joined: Mar 2012
Reputation: 1



Post: #1
problems with <call functionname>
Hello!

For a few days i'm working on the upgrade from 055 to the latest 0.56 linux build. I'm not sure if its a bug, or i'm just dumb, but..

"if <call f_languages_intercept <local.text>>" bringing this error up.
Can't resolve <call f_languages_intercept This is a test.>

Also stuff like this:
local.foo=<call f_languages_intercept <local.text>> isn't working anymore.

The functionname doesnt matter, and its only an example. A normal "call functionname" does its job. But when i'm starting to concatenate if-clauses with <call functionname> or variables.. its always a cant-resolve case. Can someone figuring out my mistake?
(This post was last modified: 08-28-2013 12:16 AM by wuffel.)
08-28-2013 12:15 AM
Find all posts by this user Like Post Quote this message in a reply
darksun84
Sir Spamalot
****

Posts: 1,687
Likes Given: 245
Likes Received: 162 in 151 posts
Joined: Mar 2012
Reputation: 35



Post: #2
RE: problems with <call functionname>
Yup looks like it's broken :\
08-28-2013 01:00 AM
Find all posts by this user Like Post Quote this message in a reply
Mordaunt
Super Moderator
****

Posts: 1,237
Likes Given: 26
Likes Received: 55 in 43 posts
Joined: Mar 2012
Reputation: 35



Post: #3
RE: problems with <call functionname>
Can't say that I have ever used it like that, but

call function_name <local.whatever>

is working

[Image: 2nis46r.jpg]
(This post was last modified: 08-28-2013 01:12 AM by Mordaunt.)
08-28-2013 01:11 AM
Visit this user's website Find all posts by this user Like Post Quote this message in a reply
wuffel
Apprentice
*

Posts: 28
Likes Given: 0
Likes Received: 4 in 2 posts
Joined: Mar 2012
Reputation: 1



Post: #4
RE: problems with <call functionname>
Yepp.
The normal "call functionname" works. But the difference between a
"if <call functionname>"
and
"if <functionname>"
can be huge. Actually i have two choices now:

First:
if <call functionname <args>>
is going to:
call functionname <args>
if <functionname <args>
I have to do many adjustments in this case.

Second:
if <functionname <holy-shit-a-big-amount-of-locals>>


I need the defined locals from the invoking function, and the returns in the invoked function are well placed. ^^
(This post was last modified: 08-28-2013 01:25 AM by wuffel.)
08-28-2013 01:24 AM
Find all posts by this user Like Post Quote this message in a reply
admin phoenix
Master
**

Posts: 354
Likes Given: 1
Likes Received: 23 in 13 posts
Joined: Mar 2012
Reputation: 3



Post: #5
RE: problems with <call functionname>
why you use call?
you donĀ“t Need it since some dev coded it new.
check the Revision text
08-28-2013 01:43 AM
Find all posts by this user Like Post Quote this message in a reply
wuffel
Apprentice
*

Posts: 28
Likes Given: 0
Likes Received: 4 in 2 posts
Joined: Mar 2012
Reputation: 1



Post: #6
RE: problems with <call functionname>
since i already checked the revision changelog more than once: can you please copy'n'paste me the part where they made call obsolete?
08-28-2013 02:25 AM
Find all posts by this user Like Post Quote this message in a reply
Coruja
Sphere Developer
*****

Posts: 987
Likes Given: 5
Likes Received: 226 in 187 posts
Joined: Jul 2012
Reputation: 7

Dimension Shard

Post: #7
RE: problems with <call functionname>
CALL is not a function, it cant be used inside <>

Code:
LOCAL.X=666
CALL something

[FUNCTION something]
SAY <LOCAL.X>
this already preserves LOCAL.X
but I think it would be better if you copy/paste here this part of the script to ppl understand it better
(This post was last modified: 08-28-2013 03:48 AM by Coruja.)
08-28-2013 03:47 AM
Find all posts by this user Like Post Quote this message in a reply
darksun84
Sir Spamalot
****

Posts: 1,687
Likes Given: 245
Likes Received: 162 in 151 posts
Joined: Mar 2012
Reputation: 35



Post: #8
RE: problems with <call functionname>
By looking at the revision, it was possible :

This can also be used as <CALL Function ...>, faster without arguments, slower with


Now i don't know, maybe it was changed Shock
08-28-2013 03:59 AM
Find all posts by this user Like Post Quote this message in a reply
wuffel
Apprentice
*

Posts: 28
Likes Given: 0
Likes Received: 4 in 2 posts
Joined: Mar 2012
Reputation: 1



Post: #9
RE: problems with <call functionname>
doesnt matter. posted a bug-report since it should work due to the revision changelog. as long as a function has a "return"-value the assignment of a value - even with a function - should work.

either local.value=<call functionname> nor if <call functionname> works.
09-01-2013 05:39 AM
Find all posts by this user Like Post Quote this message in a reply
admin phoenix
Master
**

Posts: 354
Likes Given: 1
Likes Received: 23 in 13 posts
Joined: Mar 2012
Reputation: 3



Post: #10
RE: problems with <call functionname>
I am using the function code very often
local.bla=<f_example <src.uid>>

[Function f_example]
local.uid=<args>
RETURN <local.uid>

or if you have more than one argument

[FUNCTION f_example]
RETURN <argv[0]>
09-06-2013 10:00 PM
Find all posts by this user Like Post Quote this message in a reply
Post Reply 


Forum Jump:


User(s) browsing this thread: 9 Guest(s)