Opened 21 years ago

Closed 21 years ago

#38 closed Bugs (Fixed)

"Property" identifier name collision

Reported by: jongoldman Owned by: jsiek
Milestone: Component: graph
Version: None Severity:
Keywords: Cc:

Description

Hi,

I am experimenting with the boost graph library. I 
like it so far but had a problem with a name collision.

The identifier, "Property"  in 
boost\pending\property.hpp and 
boost\pending\detail\property.hpp 

was colliding with a class/struct in my code, 
called "Property."

Two things I can do to fix it:
1. Rename my class
or
2. Rename "Property" in those boost header files to 
something else, e.g. "BoostProperty."

Anyway, I think that y'all should consider renaming 
the identifier in the official boost header file(s). 
There's gotta be other folks out there, like me, 
declaring classes with the same name.

Thanks for your consideration.

-Jon


Change History (3)

comment:1 by jsiek, 21 years ago

Logged In: YES 
user_id=32836

I'd like to understand why the name collision is occuring.
The BGL
is inside a namespace, so normally that would protect
against name
collisions, so something weird must be occuring. Could you
post
a small example program demonstrating the name collision.

comment:2 by jsiek, 21 years ago

Logged In: YES 
user_id=32836

Also, please state which compiler you are using.

comment:3 by jsiek, 21 years ago

Status: assignedclosed
Logged In: YES 
user_id=32836

Hmm, Parameter is only used in template parameter names. I
don't think parameter names are ever suppose to conflict
with class names. So it is probably a bug in the compiler Oh
well, I've checked in a change to the names anyways as a
workaround.
Note: See TracTickets for help on using tickets.