Call a C function from C++ code
Linux |
https://codedump.io/share/izKrSN2vpP8T
|
I have a C function that I would like to call from C++. I couldn't use "extern "C" void foo()" kind of approach because the C function failed to be co...
4 years ago
Mixing Objective-C and C++ code
I have an Objective-C/C++ application which uses functionality that is provided by a C++ library.
One of the C++ classes includes an enum like this:
...
4 years ago
Eclipse CDT C++11/C++0x support
C++ |
https://codedump.io/share/ScaNiq7rOkop
|
Eclipse 3.7.1
CDT 1.4.1
GCC 4.6.2
This is an example of a piece of C++11 code:
auto text = std::unique_ptr<char[]>(new char[len]);
The Eclip...
4 years ago
C++ printing extremely faster than C
C |
https://codedump.io/share/W7MgLpjQifsr
|
I am taking part in a small programming competition online. Basically what I do is solve a task, write an algorithm and send my code to be automatical...
4 years ago
Purpose of Unions in C and C++
C |
https://codedump.io/share/7inFShpLs7vm
|
I have used unions earlier comfortably; today I was alarmed when I read this post and came to know that this code
union ARGB
{
uint32_t colour;
...
4 years ago
Porting from C++ to C++/CLI
C++ |
https://codedump.io/share/groCNTeFedG5
|
I do not really believe that this question was never asked before, but i really tried to search without success, if you got a link to an already answe...
4 years ago
Connect to wifi via c/c++ program
C |
https://codedump.io/share/PmpTYcFvPQu4
|
I'm searching on internet but I can't find anything about it.
Is there a way to do a scan for a wifi connection and to connect to one with a C/C++ pr...
4 years ago
How different is Objective-C from C++?
C++ |
https://codedump.io/share/cfnQKgkLPsJH
|
What are the main differences between Objective-C and C++ in terms of the syntax, features, paradigms, frameworks and libraries?
*Important: My goal ...
4 years ago
Conditional operator differences between C and C++
C |
https://codedump.io/share/FAhqTihim3wf
|
I read somewhere that the ?: operator in C is slightly different in C++, that there's some source code that works differently in both languages. Unfor...
4 years ago
Casting int to bool in C/C++
C |
https://codedump.io/share/kZR7snwk8bR8
|
I know that in C and C++, when casting bools to ints, (int)true == 1 and (int)false == 0. I'm wondering about casting in the reverse direction...
In ...
4 years ago
Efficiency of C-String vs C++Strings
C++ |
https://codedump.io/share/YwIzbs4CPRdP
|
C++ Primer says
For most applications, in addition to being safer, it is also more
efficient to use library strings rather then C-style strings
...
4 years ago
calling opencv c++ code in C# application
C# |
https://codedump.io/share/nM0trjswuS1p
|
I have developed a c++ program which uses OpenCV. Now i want to develop a windows form based application in C#.
As C# can only handle managed code it ...
4 years ago
Equivalent of C++ typedef struct to C#
C# |
https://codedump.io/share/DZDzsdhSQIj7
|
I'm working on a project that need to communicate to a DLL. The SDK provided have a demo project in C++ and it retreive the data from the DLL using th...
4 years ago
How to Convert C++ code to C#
C# |
https://codedump.io/share/5R5YaZE36Wnp
|
I want to convert following C++ code to C#, but I do not understand what the sscanf_s function does in this example.
int i, Len, iHex;
...
4 years ago
Access c++ static methods from c#
C++ |
https://codedump.io/share/AT9UAZ6Mbwur
|
say you have following c++ code:
extern "C" {
void testA(int a, float b) {
}
static void testB(int a, float b){
}
}
I want to acce...
4 years ago
Passing vector struct between C++ and C#
C# |
https://codedump.io/share/UE8fOxJu7bnt
|
I have c++ unmanaged code that i want to access from c#. So i followed some tutorials and i build a dll for my project (only one class btw). Now i wan...
4 years ago
Map C++ member function to C callback
C |
https://codedump.io/share/WTxO6miUmZRm
|
In a C++ project I am using a C library to access some hardware. The C-Bindings include callbacks to notify about changes on some input pins.
The func...
4 years ago
C char array v C char* initialization
C |
https://codedump.io/share/6uICaJt4KmW1
|
The following is accepted as valid c code by gcc version 6.3:
char white[] = { 'a', 'b', 'c' };
char blue[] = "abc";
char *red = "abc";
However...
4 years ago
CUDA-GDB view variables in C/C++
C++ |
https://codedump.io/share/bpNgF3tFIoSn
|
I have installed the latest version of the CUDA drivers available from NVIDIA
mmiller@host:~/NVIDIA_CUDA-7.5_Samples$ nvcc --version
nvcc: NVIDIA (R)...
3 years ago