473,386 Members | 1,958 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,386 software developers and data experts.

regarding the buffer

I have written a code in which i included a header file
#include "buffer.h"

buffer_item buffer[buffer_size];
But while compiling it showing error
syntax error before 'buffer'
'buffer_item' undeclared (first use in this function)
Can u plz help me with this.
Thanks in advance
Feb 13 '10 #1
2 1419
lzndcb
3
buffer_item buffer[buffer_size]; //it's error
buffer buffer_item[buffer_size]; //it's true
Feb 13 '10 #2
weaknessforcats
9,208 Expert Mod 8TB
You are using buffer_item as a type before you have declared the type:

Expand|Select|Wrap|Line Numbers
  1. buffer_item buffer[buffer_size];
Look in your buffer.h and you will not find buffer_item declared as a type.
Feb 13 '10 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

0
by: msnews.microsoft.com | last post by:
Hello I am using ASP:XML with a web control... which in turns pulls XML from SQL server and later does the transformation... /***/ this.l__obj__XML.Document = // XML result set from SQL...
1
by: abbu | last post by:
Hi friends, Iam working on a C++ GUI. Gui is opening properly , but when i close it core dump happens i did a mdb on the file and got the below result. > $c...
8
by: AG | last post by:
Hello, This is my first post to this group, and on top of that I am a beginner. So please direct me to another group if this post seems out of place.... I have recently written a program which...
3
by: zvirack | last post by:
Hi, I am trying to create a class that can write any type of object to a file. I would like to use a template function which is a member of the class. Something like: class MyWriter {...
38
by: edu.mvk | last post by:
Hi I am using strcpy() in my code for copying a string to another string. i am using static char arrays. for the first time it is exected correctly but the second time the control reaches...
42
by: mellyshum123 | last post by:
I need to read in a comma separated file, and for this I was going to use fgets. I was reading about it at http://www.cplusplus.com/ref/ and I noticed that the document said: "Reads characters...
8
by: somenath | last post by:
Hi All, I have a doubt regarding the pointer assignment . Please have a look at the following program . #include<stdio.h> #include<stdlib.h> #define NAMESIZE 10 #define SAFE_FREE(t) if(t)\...
14
by: somenath | last post by:
Hi All, I am trying to understand the behavior of the memcpy and memmove. While doing so I wrote a program as mentioned bellow . #include<stdio.h> #include<stdlib.h> #include<string.h> ...
0
by: arvindchaubey | last post by:
hi everyone ,please help me.. I want to implement the code of rtp but havn't get success. I hav implemented the socket programming part but now want to attach the headers of rtp with any file of the...
3
by: Michel Esber | last post by:
Hi all, DB2 V8 LUW FP 15 There is a table T (ID varchar (24), ABC timestamp). ID is PK. Our application needs to frequently update T with a new value for ABC. update T set ABC=? where ID...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
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: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
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,...

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.