473,406 Members | 2,713 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,406 software developers and data experts.

Procedure Function

The C Compiler uses procedure function. It allows the programmers to
define global variables and global functions. They attempt to test using
debuging tools and often bugs are harder to find. If you use namespace, it
would be helpful to isolate global variables and global functions in the
right group.
The C++ Compiler allows local variables and local functions to be bound
inside struct or class. It makes easier to define one object as class so
all variables and functions can be manipulated inside class.
The problem is that this object has a pointer. You define class inside
main() function. You decide to execute an object. The pointer is placed in
the register and then pointer gives the memory address to locate variables
and functions. The procedure function does not need to have pointer.
Without pointer, it improves performance.
Can you please explain? Why do you prefer to design your project by
focusing to isolate variables and functions inside object as class? Why
can't namespace be used? Procedure Functions and OOP allow to be reuseable
if you want to run more than one object at the same time.

--

Yours Truly,
Bryan Parkoff
Dec 27 '07 #1
1 1720
On 2007-12-27 22:45, Bryan Parkoff wrote:
The C Compiler uses procedure function. It allows the programmers to
define global variables and global functions. They attempt to test using
debuging tools and often bugs are harder to find. If you use namespace, it
would be helpful to isolate global variables and global functions in the
right group.
The C++ Compiler allows local variables and local functions to be bound
inside struct or class. It makes easier to define one object as class so
all variables and functions can be manipulated inside class.
The problem is that this object has a pointer. You define class inside
main() function. You decide to execute an object. The pointer is placed in
the register and then pointer gives the memory address to locate variables
and functions. The procedure function does not need to have pointer.
Without pointer, it improves performance.
Can you please explain? Why do you prefer to design your project by
focusing to isolate variables and functions inside object as class? Why
can't namespace be used? Procedure Functions and OOP allow to be reuseable
if you want to run more than one object at the same time.
Are you asking a question? Because it seems to me like you answer your
questions with the last sentence. Anyway, for questions about OOP in
general groups like comp.object are better suited.

--
Erik Wikström
Dec 27 '07 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: DB_2 | last post by:
Hello, I created the following stored procedure. (Please ignore the logic in it; at this point it is not complete and I am trying to get the basic structure working first.) CREATE PROCEDURE...
1
by: Private Pyle | last post by:
DB2 version 8, fixpack 5. Aix 5.1.0.0 Using C for AIX compiler. I'm having a problem where I can create stored procedures but I'm getting -444 when I call them. It's a new environment for...
5
by: Gustavo Randich | last post by:
Hello, I'm writing an automatic SQL parser and translator from Informix to DB2. Now I'm faced with one of the most difficult things to translate, the "foreach execute procedure" functionality...
6
by: Terentius Neo | last post by:
Is it possible to combine (in DB2 UDB 8.1) a stored procedure and a select statement? I mean something like this: Select c.number, call procedure( c.number ) as list from table c With best...
1
by: Mark Dicken | last post by:
Hi All I have found the following Microsoft Technet 'Q' Article :- Q210368 -ACC2000: How to Pass an Array as an Argument to a Procedure (I've also copied and pasted the whole contents into...
2
by: peteg | last post by:
I have created a procedure called TableFlattening(). When running it thru a macro, I call this procedure via a function Public Function DoFlatten() Call TableFlattening End Function. ...
9
by: serge | last post by:
/* Subject: How to build a procedure that returns different numbers of columns as a result based on a parameter. You can copy/paste this whole post in SQL Query Analyzer or Management Studio...
3
by: mnarewec | last post by:
Please assist me: This erorr message is produce when calling the stored procedure in vb.net Procedure AutomateMatterNumber has no parameters and arguments were supplied." MS SQL 2000stored...
0
by: SOI_0152 | last post by:
Hi all! Happy New Year 2008. Il hope it will bring you love and happyness I'm new on this forum. I wrote a stored procedure on mainframe using DB2 7.1.1 and IBM language c. Everything works...
7
by: jamesclose | last post by:
My problem is this (apologies if this is a little long ... hang in there): I can define a function in VB.NET with optional parameters that wraps a SQL procedure: Sub Test(Optional ByVal Arg1...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.