help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

File Global Variables in oct Files


From: Thomas D. Dean
Subject: File Global Variables in oct Files
Date: Tue, 12 Mar 2013 11:20:49 -0700
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130221 Thunderbird/17.0.3

I have an application that has several files.

Most of the functions in these files reference variables declared in one file.

file1.cc
int xxx;
void file1(...)
  xxx = 3;
  file2(...);
...
)

file2.cc
extern int xxx
void file2(..._
  if (xxx == 3) xxx++;
...
}

etc.

Is this a problem in oct files?

I plan to change the header in file1 to an octfile and

mkoctfile file1.cc file2.cc ...

Will global variables in c++ code, like xxx, cause a problem?

Tom Dean


reply via email to

[Prev in Thread] Current Thread [Next in Thread]