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

std::size_t Which header file?


I'm writing a ".cpp" and ".hpp" combination.
The ".hpp" just contains one sole function declaration.
The ".cpp" makes use of the function "std::strlen" and the type
"std::size_t".
I'm wondering what header file should I include to use "std::strlen" and
which header file should I include to use "std::size_t" ?
-JKop
Jul 22 '05 #1
3 14200

"JKop" <NU**@NULL.NULL> wrote in message
news:d7*******************@news.indigo.ie...

I'm writing a ".cpp" and ".hpp" combination.
The ".hpp" just contains one sole function declaration.
The ".cpp" makes use of the function "std::strlen" and the type
"std::size_t".
I'm wondering what header file should I include to use "std::strlen" and
which header file should I include to use "std::size_t" ?


<cstddef> for std::size_t and <cstring> for std::strlen.

john
Jul 22 '05 #2
John Harrison wrote:

"JKop" <NU**@NULL.NULL> wrote in message

I'm wondering what header file should I include to use "std::strlen" and
which header file should I include to use "std::size_t" ?


<cstddef> for std::size_t and <cstring> for std::strlen.


See, I told you so. There is a problem with using #includes to simulate
what are called packages in UML terms. I actually presented size_t as an
example.
--
"If our hypothesis is about anything and not about some one or more
particular things, then our deductions constitute mathematics. Thus
mathematics may be defined as the subject in which we never know what we
are talking about, nor whether what we are saying is true." - Bertrand
Russell

Jul 22 '05 #3
JKop <NU**@NULL.NULL> wrote in message news:<d7*******************@news.indigo.ie>...
I'm writing a ".cpp" and ".hpp" combination.
The ".hpp" just contains one sole function declaration.
The ".cpp" makes use of the function "std::strlen" and the type
"std::size_t".
I'm wondering what header file should I include to use "std::strlen" and
which header file should I include to use "std::size_t" ?


<cstring> handles both.

--
Later,
Jerry.

The universe is a figment of its own imagination.
Jul 22 '05 #4

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

Similar topics

5
by: Christopher | last post by:
can someone refresh my meory on what std::size_t is used for? I am wondering if my template container class should have it's capacity as a size_t or an int? , Christopher
12
by: Steven T. Hatton | last post by:
I recently came across the suggestion that it might be beneficial to create a header file containing all the Standard Headers, and include that in all the places where declarations from the...
2
by: earthwormgaz | last post by:
I am trying to add the headers for a library I am using to a namespace to avert issues with name clashes. namespace Lib { #include <Lib/SomeFile.h> }; I am finding though that statements to...
5
by: greg.ruthenbeck | last post by:
Hi, I'm using Boost::uBLAS::mapped_matrix for working with sparse matrices. At the moment, the maximum dimension of mapped_matrix is 65535x65535 since std::size_t compiles as unsigned int...
7
Axon
by: Axon | last post by:
Is there a way to force std::size_t to be compiled as __uint64 (before STL etc are compiled). Where is size_t defined?
27
by: mike3 | last post by:
Hi. I can't believe I may have to use an array here. I've got this bignum package I was making in C++ for a fractal generator, and tried an approach that was suggested to me here a while...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
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: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
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...

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.