Questions tagged [name-conflict]

A situation in which two or more identifiers within a given scope cannot be unambiguously resolved.

Programmers are expected to ensure that the identifiers of entities are unique in a given scope and not open to multiple interpretations. When this is not ensured, a name-conflict (or a name-collision) occurs.

Different compilers have different rules for resolving name conflict, which is captured by name-mangling (also known as name decoration).

47 questions
2
votes
1 answer

JqGrid column chooser with column header

I have two questions about column chooser. firs one is that I'm using header grouping for my grid, for example I have a Display header group with two columns of Type and Size, and also another header Group which name is Storage with two sub columns…
Soheil
  • 113
  • 3
  • 12
1
vote
2 answers

Strange global variable behaviour, once variable name is changed issue disappears

During my university exercise I have come across strange behaviour of a variable. /* Main parameters */ double sizeX, sizeY; /* Size of the global domain */ int…
alien01
  • 1,334
  • 2
  • 14
  • 31
1
vote
2 answers

Is it potentially problematic to #include files after user-defined tokens?

Due to the way a the preprocessor works, an included header file can be affected by the file including the header. For example, you can may break C just by using: #define printf #include /* extern int printf(const char *const restrict…
user16217248
  • 3,119
  • 19
  • 19
  • 37
1
vote
2 answers

extern char* array in header throws error: expected identifier or ‘(’ before ‘[’ token

I have this header that contains an array that I need in multiple places in my code: protected_dirs.h #ifndef PROTECTED_DIRS #define PROTECTED_DIRS extern int PROTECTED_DIRS_COUNT; extern char* PROTECTED_DIRS[]; extern char*…
monamona
  • 1,195
  • 2
  • 17
  • 43
1
vote
1 answer

How should I avoid name collisions between temporary tables in BigQuery sprocs?

Sometimes it's useful to create a temporary table within a BigQuery stored procedure, in order to store an intermediate result. However, I've run into an error due to a name collision between a temporary table in a sproc and one in the session…
1
vote
1 answer

C++: How to call a function (lets say funA()) from a header file inside my own function whose name is also funA()?

I want to call a function reverse(BidirectionalIterator first, BidirectionalIterator last) from header file inside my function, whose name is also reverse(int). code: #include #include using namespace std; class…
Vold
  • 29
  • 9
1
vote
1 answer

Importing `Cubical.Data.Nat` breaks `isOfHLevel→isOfHLevelDep`

The following small Agda program typechecks: {-# OPTIONS --cubical #-} module _ where open import Cubical.Core.Everything open import Cubical.Foundations.Everything module _ (A : Type) (P : A → Type) (PIsProp : ∀ x → isProp (P x)) where r :…
Cactus
  • 27,075
  • 9
  • 69
  • 149
1
vote
2 answers

identically-named classes in app and lib cause issues *after* converting from Makefile to cmake

I'm trying to convert a program and its plugin from custom Makefiles to CMake, with minimal changes to the code. Both the plugin and the app share some code; #ifdef ... #else ... #endif blocks are used where there are differences, and I'm certain…
Mark
  • 1,035
  • 2
  • 11
  • 24
1
vote
2 answers

C++/ name conflict: how to exclude a previously defined function

I want to write log2() function for a new datatype that I defined myself Array. So it will look like this #include #include Array log2(Array& A) { Array C=A; for (int i=0; i
user5709504
1
vote
1 answer

How to name instance variables in Python?

I try to stick to the PEP8 coding conventions. I have a package called main. Inside the package there is a module called time, which has a class called Time inside. Now I have a bit of trouble finding a suitable name for my actual instance because…
freeDom-
  • 362
  • 4
  • 20
1
vote
1 answer

Same class name and assembly name in .net

I have a class MyComponent in my project which is being contained in another assembly(MyAssembly). This class is being used at many places in my project as parameter of various functions or variable type e.g. private void MyMethod(MyComponent…
Vikram
  • 1,617
  • 5
  • 17
  • 37
1
vote
1 answer

Why can't java use thread context classloader when a method is literally called?

I've written a custom classloader 'JarClassLoader', which itself works ok, since the following test case is green: public void testJarClassLoader() throws Exception { JarClassLoader cl = new JarClassLoader(); …
Utensil
  • 17,204
  • 1
  • 17
  • 10
1
vote
2 answers

Third Party library requires different version of the same DLL my application does

I'm writing an application that uses both Intel's TBB library, and an API from a company called Maplink, which also uses TBB. The problem is that both my application and the Maplink API want to load TBB.dll from the directory containing my…
NobodyNothing
  • 155
  • 3
  • 13
1
vote
1 answer

ASP.NET MVC WebAPI Hosted in the Same Project as Classic Controllers

I want to use classic MVC controllers alongside WebAPI controllers in the same project. The classic MVC controllers will return static content, like the HTML for pages. All data will be passed around with the WebAPI. The problem is that the…
1
vote
3 answers

Not able to add VideoLAN VLC component in VB6

I want to create a simple VB project which would play live feed from a CCTV webcam on the form. For this, I am planning to embed VLC in my VB form. I have installed VLC on my PC already. In the components list I get entry for VLC activeX component…
Jay
  • 1,210
  • 9
  • 28
  • 48